Skip to content

resolve_delayed + data_extract_srv - #76

Merged
mhallal1 merged 47 commits into
mainfrom
654_pass_reactive_data@main
Jun 29, 2022
Merged

mhallal1 merged 47 commits into
mainfrom
654_pass_reactive_data@main

Conversation

@mhallal1

@mhallal1 mhallal1 commented Jun 24, 2022 •

Copy link
Copy Markdown
Contributor

closes #67
replaces #74 to have the same branch name as pharmaverse/teal#674

  • Create a new module resolve which is the alternative of resolve_delayed that accepts a list of data.frame and a list of join.keys as input. The common functions have been moved into resolve.R as resolve_delayed.R will be removed in the future. resolve_delayed is updated to use resolve internally.
  • Update the tests to satisfy the new resolve function and add a section at the end of every test file for the tests of resolve_delayed preceded with the title # with resolve_delayed. This would not decrease the coverage throughout the coming sprint and would facilitate the removal of resolve_delayed and its tests in the future.
  • Clean resolve tests to not use FilteredData where not needed.
  • S3 methods for data_extract_srv and data_extract_multiple_srv for FilteredData and list of reactive data.frames.
  • split the tests of data_extract_srv and data_extract_multiple_srv

STILL TO DO:

@nikolas-burkoff nikolas-burkoff left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

A few comments from me here but it's making good progress

Comment thread R/resolve.R Resolved
Comment thread R/resolve.R Resolved
Comment thread R/resolve_delayed.R Resolved
Comment thread R/resolve.R Resolved
Comment thread R/data_extract_module.R Resolved
Comment thread R/data_extract_module.R Resolved
Comment thread R/data_extract_module.R Resolved
@mhallal1
mhallal1 marked this pull request as ready for review June 27, 2022 07:57
@github-actions

github-actions Bot commented Jun 27, 2022 •

Copy link
Copy Markdown
Contributor

Code Coverage Summary

Filename                          Stmts    Miss  Cover    Missing
------------------------------  -------  ------  -------  ---------------------------------------------------------------------
R/all_choices.R                       1       0  100.00%
R/call_utils.R                      156     124  20.51%   14-23, 64, 66, 68, 107-431
R/check_selector.R                   31       0  100.00%
R/choices_labeled.R                 202      61  69.80%   60, 71, 76, 87, 103, 221-225, 229-234, 264-277, 390-391, 393, 425-473
R/choices_selected.R                 81      11  86.42%   201-229, 260
R/column_functions.R                  3       3  0.00%    13-16
R/data_extract_datanames.R           32       8  75.00%   9-13, 64-66
R/data_extract_filter_module.R       92      11  88.04%   75-82, 84, 87-88, 141
R/data_extract_module.R             254      60  76.38%   3, 121, 126, 143, 146-151, 153, 172-175, 203-249, 443, 448, 478
R/data_extract_read_module.R        122      13  89.34%   28, 32-35, 102-107, 116, 133
R/data_extract_select_module.R       32      18  43.75%   31-48
R/data_extract_single_module.R       53       2  96.23%   29, 42
R/data_extract_spec.R                32       0  100.00%
R/data_merge_module.R                44      19  56.82%   101-122
R/filter_spec.R                     186       1  99.46%   373
R/format_data_extract.R              16       1  93.75%   49
R/get_dplyr_call.R                  298       0  100.00%
R/get_merge_call.R                  283      32  88.69%   29-36, 47, 210-219, 362, 369, 385-397, 460
R/include_css_js.R                    5       0  100.00%
R/input_checks.R                     11       2  81.82%   18-19
R/merge_data_utils.R                  2       0  100.00%
R/merge_datasets.R                  154       7  95.45%   71, 123, 251-255
R/resolve_delayed.R                  16       0  100.00%
R/resolve.R                         114      44  61.40%   229-312
R/select_spec.R                      49       8  83.67%   149, 213-220
R/utils.R                            15      11  26.67%   26-39
R/zzz.R                               2       2  0.00%    2-3
TOTAL                              2286     438  80.84%

Results for commit: d01985a

Minimum allowed coverage is 80%

♻️ This comment has been updated with latest results

@pawelru

pawelru commented Jun 27, 2022

Copy link
Copy Markdown
Contributor

Please add NEWS entry

Comment thread R/data_extract_module.R Resolved
mhallal1 and others added 2 commits June 27, 2022 15:43
Comment thread R/resolve.R Resolved
Comment thread NEWS.md Resolved
Comment thread R/data_extract_module.R Resolved
Comment thread R/data_extract_module.R Resolved
Comment thread R/resolve.R Resolved

@gogonzo gogonzo left a comment •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

data_extract and resolve works as expected together with list of reactive datasets. See pharmaverse/teal#674 to automatically call module with data argument.

See also the app which tests multiple data_extract scenarios
https://gist.github.com/gogonzo/ae4cdc57254866924ece3c7e1b3ed3e5

@mhallal1
mhallal1 merged commit 5df18ff into main Jun 29, 2022
@mhallal1
mhallal1 deleted the 654_pass_reactive_data@main branch June 29, 2022 07:22
@mhallal1 mhallal1 mentioned this pull request Jul 1, 2022
3 tasks done
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

data_extract - remove dependency on datasets

6 participants