make()
.R/progress.R
Together, functions failed
and
diagnose()
should eliminate the strict need
for ordinary error messages printed to the console.
failed(path = getwd(), search = TRUE, cache = drake::get_cache(path = path, search = search, verbose = verbose), verbose = drake::default_verbose())
path | Root directory of the drake project,
or if |
---|---|
search | logical. If |
cache | drake cache. See |
verbose | logical or numeric, control printing to the console.
Use
|
A character vector of target names.
diagnose()
, session()
,
built()
, imported()
,
readd()
, drake_plan()
, make()
# NOT RUN { test_with_dir("Quarantine side effects.", { load_basic_example() # Get the code with drake_example("basic"). make(my_plan) # Run the project, build the targets. failed() # Should show that no targets failed. # Build a workflow plan doomed to fail: bad_plan <- drake_plan(x = function_doesnt_exist()) try(make(bad_plan), silent = TRUE) # error failed() # "x" diagnose(x) # Retrieve the cached error log of x. }) # }