DOI-USGS / mda.streams

backend tools for powstreams
Creative Commons Zero v1.0 Universal
3 stars 8 forks source link

fix stuff alison broke #219

Closed aappling-usgs closed 8 years ago

aappling-usgs commented 8 years ago

this applies to alison's current develop branch.

empty_config <- stage_metab_config(tag='0.0.0', strategy='updating SB metab model', site=NA, filename=NULL)
Error in `[.data.frame`(config, row, paste0(var_needs, ".src")) : 
  undefined columns selected

(fixed by dealing with var_src_codes for previous checkbox)

modernize_metab_model : <anonymous>: no visible global function
  definition for 'get_args'
stage_indy_site: possible error in calc_solar_insolation(solar.time =
  v(suntime), latitude = lat, max.insolation = convert_PAR_to_SW(2326),
  attach.units = TRUE): unused argument (solar.time = v(suntime))
stage_nwis_ts: no visible binding for global variable 'sample_dt'
stage_nwis_ts: no visible binding for global variable 'sample_tm'
stage_nwis_ts: no visible binding for global variable 'SuspSed'
stage_nwis_ts: no visible binding for global variable '.'
stage_nwis_ts: no visible binding for global variable 'sed'
stage_nwis_ts: no visible global function definition for 'readNWISuv'
stage_nwis_ts: no visible binding for global variable 'dateTime'
* checking examples ... ERROR
Running examples in 'mda.streams-Ex.R' failed
The error most likely occurred in:

> base::assign(".ptime", proc.time(), pos = "CheckExEnv")
> ### Name: verify_config
> ### Title: Verify that a config file row has the requisite info
> ### Aliases: verify_config
> 
> ### ** Examples
> 
> egconfig <- suppressWarnings(
+   stage_metab_config(tag="0.0.1", strategy="try stage_metab_config", 
+     site="nwis_04087142", filename=NULL))
Error in `[.data.frame`(config, row, paste0(var_needs, ".src")) : 
  undefined columns selected
Execution halted
* checking tests ...
  Running 'testthat.R' ERROR
Running the tests in 'tests/testthat.R' failed.
Last 13 lines of output:
  6: lapply(X = X, FUN = FUN, ...)
  7: FUN(X[[i]], ...)
  8: config[row, paste0(var_needs, ".src")]
  9: `[.data.frame`(config, row, paste0(var_needs, ".src"))
  10: stop("undefined columns selected")

  testthat results ================================================================
  OK: 111 SKIPPED: 0 FAILED: 2
  1. Error: config files can be staged 
  2. Error: config files can be verified 

  Error: testthat unit tests failed
  Execution halted