Skip to content

v0.2.3 - #70

Open
ginberg wants to merge 78 commits into
mainfrom
develop
Open

v0.2.3#70
ginberg wants to merge 78 commits into
mainfrom
develop

Conversation

@ginberg

@ginberg ginberg commented Jun 24, 2026

Copy link
Copy Markdown
Collaborator

see milestone

@cebarboza cebarboza added the enhancement New feature or request label Jun 29, 2026
@cebarboza cebarboza added this to the v0.0.2 milestone Jun 29, 2026
@cebarboza
cebarboza marked this pull request as ready for review July 22, 2026 16:21
@cebarboza

Copy link
Copy Markdown
Collaborator

Hi @ginberg I will review and send it by Monday.

@cebarboza
cebarboza requested a review from Copilot July 22, 2026 16:23
@cebarboza cebarboza changed the title v0.2.0 v0.2.3 Jul 22, 2026

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR updates PatientGenerator for the 0.2.x release line by expanding supported CDM tables and enhancing the Shiny designer (including timeline rendering), while adding new tests and refreshing fixtures/lockfiles.

Changes:

  • Expanded supported CDM tables (adds observation and death) and updated JSON loading/exporting behavior.
  • Enhanced patientDesigner() UX (publishable app export, optional chat tab, xlsx upload/download hooks, improved timeline formatting/rendering).
  • Added/updated test coverage and updated test fixtures + renv.lock for the new behaviors.

Reviewed changes

Copilot reviewed 31 out of 112 changed files in this pull request and generated 6 comments.

Show a summary per file
File Description
tests/testthat/testCases/test_diabetes_patients.json Updates diabetes fixture data (people, observation periods, events, drug exposures, procedures, measurements).
tests/testthat/testCases/patient_chat_ovarian_stages.json Normalizes fixture values (e.g., gender labels, dates, observation period type).
tests/testthat/test-xlsx-upload.R Adds tests for xlsx import/export round-tripping.
tests/testthat/test-timelineHelpers.R Adds unit tests for timeline date formatting and end-date normalization helpers.
tests/testthat/test-prompts.R Updates diabetes workflow prompt expectation.
tests/testthat/test-patientDesigner.R Adds tests for publishable designer directory creation.
tests/testthat/test-patientChat.R Adjusts model initialization test to avoid unsupported model id.
tests/testthat/test-conceptSearchModule.R Adds tests for concept-id-to-label helper behavior.
tests/testthat/test-cdmTableModules.R Adds tests for label display logic and server behaviors (dates, concepts, death handling).
tests/testthat/test-cdmTableClass.R Adds coverage for cdmTable$add() accepting explicit date values.
tests/testthat/test-cdmConstructor.R Expands constructor tests to include observation/death and end-date backfilling.
tests/testthat/helper-internals.R Exposes additional internal helpers for testing.
renv.lock Updates R version and dependency lock entries for the new release state.
R/updateFunctions.R Adds inputDisplayLabel() and improves module input rendering + selector/date update behavior.
R/timelineHelpers.R Introduces normalizeBarEndUpdate() and date formatting helpers for timeline/table display.
R/patientsDesigner.R Expands patientDesigner() options (publishable export, chat tab, xlsx hooks) and adds observation/death plumbing.
R/patientChat.R Improves system prompt and adds CLI progress/success messaging.
R/conceptSearchModule.R Adds hecateConceptLabel() helper to resolve concept ids to display labels.
R/cdmTableModules.R Enhances CDM table module behavior (concept label UI, add/update handling, date sync).
R/cdmTableClass.R Adjusts table id/concept/date column resolution for death/observation.
R/cdmConstructor.R Adds observation/death, xlsx import/export, more robust JSON loading, and timeline shaping.
R/cdm54data.R Introduces supportedCdmTables() and switches table-spec reading from parquet to rds.
NEWS.md Adds release notes for 0.2.0–0.2.3.
NAMESPACE Adds cli imports for new console messaging.
man/patientDesigner.Rd Documents new patientDesigner() parameters.
man/patientChat.Rd Reflows/updates generated Rd content for patientChat.
inst/shiny/app.R Adds minimal packaged Shiny template entrypoint.
inst/d3/cdm_timeline.js Improves timeline rendering (tooltips, labels, measurement markers, observation support).
gui-crash.md Adds a proposal document describing the GUI crash/end-date behavior and suggested approach.
DESCRIPTION Updates package version and dependencies for the new release line.
Comments suppressed due to low confidence (1)

R/cdmTableModules.R:241

  • The field-update observer currently excludes all inputs whose name contains "date". That prevents non-start/end date fields (e.g., verbatim_end_date in drug_exposure) from ever being persisted via cdm[[id]]$update(), because only the start/end date inputs are handled by updateDates().
        no_date_inputs <- table_inputs[grep(
          "date",
          names(table_inputs),
          invert = TRUE
        )]

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread R/patientsDesigner.R
Comment on lines +139 to +144
tabPanel(
"Observation",
cdmTableUI(id = "observation"),
value = "observation_module"
)
),
Comment thread R/patientsDesigner.R
Comment on lines +155 to +165
tabPanel(
"Test Data",
tableOutput("cdmData"),
tableOutput("personDataTable"),
tableOutput("observationPeriodTable"),
tableOutput("drugExposureTable"),
tableOutput("conditionOccurrenceTable"),
tableOutput("measurementTable"),
tableOutput("procedureOccurrenceTable"),
tableOutput("observationTable")
)
Comment thread NEWS.md

# PatientGenerator 0.2.2

* Fix for concept ids not being maintained when we try to create patients/conditions/prcoedures.
Comment thread DESCRIPTION
Type: Package
Title: Generator of Synthetic Patient Data for the OMOP Common Data Model
Version: 0.1.4
Version: 0.2.3
Comment thread man/patientChat.Rd
Comment on lines +85 to +87
\subsection{Returns}{
A new \code{Person} object.
}
Comment thread gui-crash.md
Comment on lines +5 to +8
This is a proposal only. It does not change package code.

The focus is the test-data case in [mod_test_file_updated.json](/Users/cbarboza/Documents/mi-erasmusmc/PatientGenerator/tests/testthat/testCases/mod_test_file_updated.json), where many `condition_occurrence` rows have:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants