This function will trigger the app to execute a dry run of loading the session data to the database. If you assign the output to a variable then it will invisibly return the html output from the dry run and split any errors or warnings into separate list elements. output list has $output $errors and $warnings. If you don't assign the output to a variable then errors and warnings will only be printed to stderr.
After the dry run is successful you can run load_session()
in order
to trigger a task on the app which loads the data from the session and
into the app database.
Usage
dry_run_session(
session_id,
run_type = c("full", "quick"),
user_cookie = login_and_get_user_cookie(),
server_url = Sys.getenv("GXPA_SERVER", "https://geneatlas.redda.bms.com/")
)
Arguments
- session_id
the id of session
- run_type
Default 'full' another choice is 'quick' which takes longer since it checks all the lines of the expression matrix (this option is only supported and functional in GXPA version with py3 - otherwise it will just do a full dry run)
the cookie string. Can use
login_and_get_user_cookie()
to get it. If you don't provide the cookie string, then the function will run login_and_get_user_cookie(). So, if you provide the cookie then it saves one interaction with the server.- server_url
GXPA server (default GXPA_SERVER environment variable or https://geneatlas.redda.bms.com/ if missing)
Value
Invisibly returns a list with 3 elements: $output has the full html output of the dry run. $errors has any errors, and $warnings has any warnings
Examples
if (FALSE) { # \dontrun{
user_cookie <- login_and_get_user_cookie()
tmp <- dry_run_session("VLZHJS", user_cookie = user_cookie)
tmp <- dry_run_session("8T3X5G", user_cookie = user_cookie)
tmp <- dry_run_session("8P9JD3", user_cookie = user_cookie)
tmp <- dry_run_session("X1NBJK", user_cookie = user_cookie)
} # }