Export expr in merge_srv#84
Conversation
| variables_selected <- shiny::eventReactive( | ||
| selectors_unwrapped(), | ||
| { | ||
| shiny::req(selectors_unwrapped()) | ||
| lapply( | ||
| .merge_summary_list(selectors_unwrapped(), join_keys = teal.data::join_keys(data()))$mapping, | ||
| function(selector) unname(selector$variables) | ||
| ) | ||
| } | ||
| ) |
There was a problem hiding this comment.
This variables_selected is a part of this PR #83
Code Coverage SummaryDiff against mainResults for commit: 4193fb6 Minimum allowed coverage is ♻️ This comment has been updated with latest results |
Unit Tests Summary 1 files 11 suites 18s ⏱️ Results for commit 4193fb6. ♻️ This comment has been updated with latest results. |
Unit Test Performance DifferenceAdditional test case details
Results for commit aa92170 ♻️ This comment has been updated with latest results. |
|
Here there is an example from Hey, I am observing an issue which potentially is present in all modules, related with If I run the app in But if I run in branch The col relabel is missing |
|
@osenan it seems that this is something being done in
I don't understand why we need to return the edit: See code below, as the code is already executed. If we need to add report, then we can do that earlier on execution inside the module shiny::reactiveConsole(TRUE)
on.exit(reactiveConsole(FALSE))
data <- teal.data::teal_data()
data <- within(data, {
adsl <- data.frame(studyid = "A", usubjid = c("1", "2"), age = c(30, 40))
})
teal.data::join_keys(data) <- teal.data::join_keys(
teal.data::join_key("adsl", "adsl", c("studyid", "usubjid"))
)
selectors <- list(a = shiny::reactive(picks(datasets("adsl", "adsl"), variables("age", "age"))))
out <- shiny::withReactiveDomain(
domain = shiny::MockShinySession$new(),
expr = merge_srv(id = "test", data = shiny::reactive(data), selectors = selectors, output_name = "anl")
)
out$data() |> teal.code::get_code() |> cat()
#> adsl <- data.frame(studyid = "A", usubjid = c("1", "2"), age = c(30, 40))
#> anl <- dplyr::select(adsl, studyid, usubjid, age)
out$expr() |> deparse1() |> cat()
#> [1] "anl <- dplyr::select(adsl, studyid, usubjid, age)" |

so that we can support old code reproduction like