- using R version 4.3.3 (2024-02-29 ucrt)
- using platform: x86_64-w64-mingw32 (64-bit)
- R was compiled by
gcc.exe (GCC) 12.3.0
GNU Fortran (GCC) 12.3.0
- running under: Windows Server 2022 x64 (build 20348)
- using session charset: UTF-8
- checking for file 'CohortCharacteristics/DESCRIPTION' ... OK
- checking extension type ... Package
- this is package 'CohortCharacteristics' version '0.2.0'
- package encoding: UTF-8
- checking package namespace information ... OK
- checking package dependencies ... OK
- checking if this is a source package ... OK
- checking if there is a namespace ... OK
- checking for hidden files and directories ... OK
- checking for portable file names ... OK
- checking whether package 'CohortCharacteristics' can be installed ... OK
See the install log for details.
- checking installed package size ... NOTE
installed size is 6.2Mb
sub-directories of 1Mb or more:
doc 5.6Mb
- checking package directory ... OK
- checking 'build' directory ... OK
- checking DESCRIPTION meta-information ... OK
- checking top-level files ... OK
- checking for left-over files ... OK
- checking index information ... OK
- checking package subdirectories ... OK
- checking R files for non-ASCII characters ... OK
- checking R files for syntax errors ... OK
- checking whether the package can be loaded ... [1s] OK
- checking whether the package can be loaded with stated dependencies ... [1s] OK
- checking whether the package can be unloaded cleanly ... [1s] OK
- checking whether the namespace can be loaded with stated dependencies ... [1s] OK
- checking whether the namespace can be unloaded cleanly ... [1s] OK
- checking loading without being on the library search path ... [1s] OK
- checking use of S3 registration ... OK
- checking dependencies in R code ... OK
- checking S3 generic/method consistency ... OK
- checking replacement functions ... OK
- checking foreign function calls ... OK
- checking R code for possible problems ... [11s] OK
- checking Rd files ... [1s] OK
- checking Rd metadata ... OK
- checking Rd cross-references ... OK
- checking for missing documentation entries ... OK
- checking for code/documentation mismatches ... WARNING
Codoc mismatches from documentation object 'mockCohortCharacteristics':
mockCohortCharacteristics
Code: function(con = NULL, writeSchema = NULL, numberIndividuals =
10, ..., seed = NULL)
Docs: function(connectionDetails = list(con =
DBI::dbConnect(duckdb::duckdb(), ":memory:"),
write_schema = "main", mock_prefix = NULL),
drug_exposure = NULL, drug_strength = NULL,
observation_period = NULL, condition_occurrence =
NULL, visit_occurrence = NULL, concept_ancestor =
NULL, person = NULL, death = NULL, cohort1 = NULL,
cohort2 = NULL, drug_concept_id_size = 5,
ancestor_concept_id_size = 5,
condition_concept_id_size = 5, visit_concept_id_size =
5, visit_occurrence_id_size = 5,
ingredient_concept_id_size = 1, drug_exposure_size =
10, patient_size = 1, min_drug_exposure_start_date =
"2000-01-01", max_drug_exposure_start_date =
"2020-01-01", earliest_date_of_birth = NULL,
latest_date_of_birth = NULL,
earliest_observation_start_date = NULL,
latest_observation_start_date = NULL,
min_days_to_observation_end = NULL,
max_days_to_observation_end = NULL,
earliest_condition_start_date = NULL,
latest_condition_start_date = NULL,
min_days_to_condition_end = NULL,
max_days_to_condition_end = NULL,
earliest_visit_start_date = NULL,
latest_visit_start_date = NULL, min_days_to_visit_end
= NULL, max_days_to_visit_end = NULL, seed = 1, ...)
Argument names in code not in docs:
con writeSchema numberIndividuals
Argument names in docs not in code:
connectionDetails drug_exposure drug_strength observation_period
condition_occurrence visit_occurrence concept_ancestor person death
cohort1 cohort2 drug_concept_id_size ancestor_concept_id_size
condition_concept_id_size visit_concept_id_size
visit_occurrence_id_size ingredient_concept_id_size
drug_exposure_size patient_size min_drug_exposure_start_date
max_drug_exposure_start_date earliest_date_of_birth
latest_date_of_birth earliest_observation_start_date
latest_observation_start_date min_days_to_observation_end
max_days_to_observation_end earliest_condition_start_date
latest_condition_start_date min_days_to_condition_end
max_days_to_condition_end earliest_visit_start_date
latest_visit_start_date min_days_to_visit_end max_days_to_visit_end
Mismatches in argument names (first 3):
Position: 1 Code: con Docs: connectionDetails
Position: 2 Code: writeSchema Docs: drug_exposure
Position: 3 Code: numberIndividuals Docs: drug_strength
Mismatches in argument default values:
Name: 'seed' Code: NULL Docs: 1
- checking Rd \usage sections ... OK
- checking Rd contents ... OK
- checking for unstated dependencies in examples ... OK
- checking installed files from 'inst/doc' ... OK
- checking files in 'vignettes' ... OK
- checking examples ... [4s] OK
- checking for unstated dependencies in 'tests' ... OK
- checking tests ... [85s] ERROR
Running 'spelling.R' [0s]
Running 'testthat.R' [84s]
Running the tests in 'tests/testthat.R' failed.
Complete output:
> # This file is part of the standard setup for testthat.
> # It is recommended that you do not modify it.
> #
> # Where should you do additional test configuration?
> # Learn more about the roles of various files in:
> # * https://r-pkgs.org/tests.html
> # * https://testthat.r-lib.org/reference/test_package.html#special-files
>
> library(testthat)
> library(CohortCharacteristics)
>
> test_check("CohortCharacteristics")
Starting 2 test processes
[ FAIL 3 | WARN 0 | SKIP 11 | PASS 82 ]
══ Skipped tests (11) ══════════════════════════════════════════════════════════
• On CRAN (10): 'test-plotCharacteristics.R:2:3',
'test-plotLargeScaleCharacteristics.R:3:3', 'test-plotSummarised.R:2:3',
'test-plotSummarised.R:91:3', 'test-plotSummarised.R:197:3',
'test-plotSummarised.R:299:3',
'test-summariseLargeScaleCharacteristics.R:2:3',
'test-tableSummarised.R:2:3', 'test-tableSummarised.R:123:3',
'test-summariseCharacteristics.R:1122:3'
• empty test (1): 'test-tableSummarised.R:262:1'
══ Failed tests ════════════════════════════════════════════════════════════════
── Error ('test-summariseCharacteristics.R:53:3'): test summariseCharacteristics ──
Error in `mockCohortCharacteristics(connectionDetails, dus_cohort = dus_cohort,
person = person, comorbidities = comorbidities, medication = medication,
observation_period = observation_period, cohort1 = emptyCohort,
cohort2 = emptyCohort)`: ! `con` must be a DBI connection
Backtrace:
▆
1. └─PatientProfiles (local) mockCohortCharacteristics(...) at test-summariseCharacteristics.R:53:3
2. └─cli::cli_abort(c(`!` = "`con` must be a DBI connection"))
3. └─rlang::abort(...)
── Error ('test-summariseCharacteristics.R:378:3'): test empty cohort ──────────
Error in `mockCohortCharacteristics(connectionDetails = connectionDetails)`: tables must be a list; it can not contain NA; it can not be NULL; it has to be named; elements must have class: data.frame.
Backtrace:
▆
1. └─PatientProfiles (local) mockCohortCharacteristics(connectionDetails = connectionDetails) at test-summariseCharacteristics.R:378:3
2. └─PatientProfiles:::assertList(tables, named = TRUE, class = "data.frame")
3. └─cli::cli_abort(errorMessage, call = call)
4. └─rlang::abort(...)
── Error ('test-summariseCharacteristics.R:484:3'): test cohort id ─────────────
Error in `mockCohortCharacteristics(connectionDetails, dus_cohort = dus_cohort,
person = person, comorbidities = comorbidities, medication = medication,
observation_period = observation_period, cohort1 = emptyCohort,
cohort2 = emptyCohort)`: ! `con` must be a DBI connection
Backtrace:
▆
1. └─PatientProfiles (local) mockCohortCharacteristics(...) at test-summariseCharacteristics.R:484:3
2. └─cli::cli_abort(c(`!` = "`con` must be a DBI connection"))
3. └─rlang::abort(...)
[ FAIL 3 | WARN 0 | SKIP 11 | PASS 82 ]
Error: Test failures
Execution halted
- checking for unstated dependencies in vignettes ... OK
- checking package vignettes in 'inst/doc' ... OK
- checking re-building of vignette outputs ... [159s] ERROR
Error(s) in re-building vignettes:
--- re-building 'a05_summariseCohortEntries.Rmd' using rmarkdown
trying URL 'https://example-data.ohdsi.dev/GiBleed.zip'
Content type 'application/zip' length 6754786 bytes (6.4 MB)
==================================================
downloaded 6.4 MB
--- finished re-building 'a05_summariseCohortEntries.Rmd'
Warning: Connection is garbage-collected, use dbDisconnect() to avoid this.
--- re-building 'a06_summarisePatientCharacteristics.Rmd' using rmarkdown
trying URL 'https://example-data.ohdsi.dev/GiBleed.zip'
Content type 'application/zip' length 6754786 bytes (6.4 MB)
==================================================
downloaded 6.4 MB
Quitting from lines 78-86 [unnamed-chunk-5] (a06_summarisePatientCharacteristics.Rmd)
Error: processing vignette 'a06_summarisePatientCharacteristics.Rmd' failed with diagnostics:
the condition has length > 1
--- failed re-building 'a06_summarisePatientCharacteristics.Rmd'
Warning: Connection is garbage-collected, use dbDisconnect() to avoid this.
--- re-building 'a07_summariseLargeScaleCharacteristics.Rmd' using rmarkdown
trying URL 'https://example-data.ohdsi.dev/GiBleed.zip'
Content type 'application/zip' length 6754786 bytes (6.4 MB)
==================================================
downloaded 6.4 MB
--- finished re-building 'a07_summariseLargeScaleCharacteristics.Rmd'
Warning: Connection is garbage-collected, use dbDisconnect() to avoid this.
--- re-building 'a08_summariseCohortOverlap.Rmd' using rmarkdown
trying URL 'https://example-data.ohdsi.dev/GiBleed.zip'
Content type 'application/zip' length 6754786 bytes (6.4 MB)
==================================================
downloaded 6.4 MB
--- finished re-building 'a08_summariseCohortOverlap.Rmd'
Warning: Connection is garbage-collected, use dbDisconnect() to avoid this.
--- re-building 'a09_summariseCohortTiming.Rmd' using rmarkdown
trying URL 'https://example-data.ohdsi.dev/GiBleed.zip'
Content type 'application/zip' length 6754786 bytes (6.4 MB)
==================================================
downloaded 6.4 MB
--- finished re-building 'a09_summariseCohortTiming.Rmd'
Warning: Connection is garbage-collected, use dbDisconnect() to avoid this.
SUMMARY: processing the following file failed:
'a06_summarisePatientCharacteristics.Rmd'
Error: Vignette re-building failed.
Execution halted
- checking PDF version of manual ... [17s] OK
- checking HTML version of manual ... [5s] OK
- DONE
Status: 2 ERRORs, 1 WARNING, 1 NOTE