Closed nip5 closed 5 years ago
This was partially caused by the DayMet tests not properly dealing with the weather data being unavailable, this issue is fixed in branch Bugfix#357_DayMet_Validation
. However, test_projects.R
is still failing due to missing P_ids
causing information to not be written to the dbOutput
database.
The specific error contained within runDataSC
post test is: Error in rSOILWAT2::sw_exec(inputData = swRunScenariosData[[sc]], weatherList = i_sw_weatherList[[scw]], : \n REAL() can only be applied to a 'numeric', not a 'integer'\n" attr(,"class")
But simply converting these inputs into integers causes more issues down the road as well as some values are expected to be integers per their class definitions. @dschlaep
The issue now seems to be fixed on Caitlin's local (unix) and AppVeyor (windows) but fails on both my local and Travis CI, both Linux. Thus it seems like a weird Linux thing.
This is fixed on my local as well now but still fails on Travis
, I'm thinking this has to do with the package circular
not properly being loaded in. This would cause both overall_mean
and overall_sd
databases to not populate correctly and thus it would fail the test_projects
tests.
The issue seems to be somewhat of a repeat of issue #82. The tests are passing locally on multiple OSs, and even on the CI, but the tests fail when R CMD check is invoked.
# - Rscript -e 'Sys.setenv(NOT_CRAN = "false"); devtools::test()'
Sys.setenv("R_TESTS" = "")
to testthat.R, as suggested here, but this did not help.`checking tests ... Running ‘testthat.R’ [544s/545s] ERROR Running the tests in ‘tests/testthat.R’ failed. Last 13 lines of output: [1] "'dbConnect2': 2019-02-19 21:59:47 attempt to connect after 0 s" [1] "'dbWork_update_status': 2019-02-19 21:59:47 (FALSE) attempt to update after 0 s" [1] "'dbWork_update_status': 2019-02-19 21:59:47 (FALSE) transaction confirmed after 0 s" [1] "No missing Pids found: dbOutCurrent database is complete." [1] "rSFSW2's 'check_outputDB_completeness': ended after 0.22 s"
###########################################################################
###########################################################################
Error: Test failures Tracing test_files(paths, reporter = reporter, env = env, stop_on_failure = stop_on_failure, .... on exit Untracing function "test_files" in package "namespace:testthat" Execution halted
At least on my machine, the unit tests were failing because TestPrj4
produced an empty output database -- because every simulation run failed due to "Simulation run fails if transpiration regions defined as type integer
" (https://github.com/DrylandEcology/rSOILWAT2/issues/136). With rSOILWAT2
v2.3.5 this is fixed and all package checks for rSFSW2
pass on my local machine.
The same thing happened on mine so I ended up creating another branch that fixes that as well but if it was already fixed in v2.3.5 then I'll go with that.
rSFSW2
master
branch is failing on Travis whereas the branch was passing when ran three months ago. I think the reason is that three months ago the CI was running it usingR version 3.5.1
and now is running it onR version 3.5.2
and dependencies that are grabbed online may have also been updated. The build says to see/home/travis/build/DrylandEcology/rSFSW2/rSFSW2.Rcheck/00check.log
for details, but I'm not sure where to find this. Sources online seem to think it needs to becat
ed to the screen in the.yml
file. @dschlaep should we pursue this?