Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Forbid new check warnings #2404

Merged
merged 32 commits into from
Sep 19, 2019
Merged
Show file tree
Hide file tree
Changes from 29 commits
Commits
Show all changes
32 commits
Select commit Hold shift + click to select a range
d868410
compare check results against previously cached version, error if any…
infotroph Sep 2, 2019
5598fca
cleanup
infotroph Sep 3, 2019
d7b0e71
first versions of all reference check logs
infotroph Sep 3, 2019
447a83e
remove file write, cleanup
infotroph Sep 3, 2019
b34048a
show new errors rather than make user guess
infotroph Sep 3, 2019
6bdb9b5
use base funs
infotroph Sep 3, 2019
03a9960
wording
infotroph Sep 3, 2019
0e66a61
Merge branch 'develop' into forbid-new-check-warnings
infotroph Sep 4, 2019
f064d12
Merge branch 'develop' into forbid-new-check-warnings
infotroph Sep 14, 2019
69c515a
Merge branch 'develop' into forbid-new-check-warnings
infotroph Sep 17, 2019
4e70c01
Merge branch 'develop' into forbid-new-check-warnings
infotroph Sep 17, 2019
49ca6a1
Merge branch 'develop' into forbid-new-check-warnings
infotroph Sep 17, 2019
9dd9085
remove dead code
infotroph Sep 17, 2019
af82226
avoid direct DBI dependency in workflow
infotroph Sep 17, 2019
74c6388
remove outdated workaround
infotroph Sep 17, 2019
168787b
fix warnings added since I saved the reference file
infotroph Sep 18, 2019
a7f4121
typo
infotroph Sep 18, 2019
2efcb70
always report package name
infotroph Sep 18, 2019
61b3c4b
functionalize 2-item pipes for easier reading and to avoid undeclared…
infotroph Sep 18, 2019
dfea8a8
enquote stray apostrophe
infotroph Sep 18, 2019
5a8d76b
ignore small differences in potential recompression savings
infotroph Sep 18, 2019
5accc92
ignore warning from existing dataset
infotroph Sep 18, 2019
a36d80a
defancify quotes
infotroph Sep 18, 2019
4cde04d
ok, defancify AND strip commas
infotroph Sep 18, 2019
ac58098
fix markup error rather than fight path differences
infotroph Sep 18, 2019
005173f
replace hand-written Rd stub with Roxygen
infotroph Sep 18, 2019
5beba86
remove stray trailing lines
infotroph Sep 18, 2019
dd5875a
missing quote
infotroph Sep 19, 2019
cb16f9c
document Travis checks
infotroph Sep 19, 2019
edb46d5
Update book_source/02_demos_tutorials_workflows/05_developer_workflow…
infotroph Sep 19, 2019
96b8965
Update book_source/02_demos_tutorials_workflows/05_developer_workflow…
infotroph Sep 19, 2019
2eac81f
remove dummy functions
infotroph Sep 19, 2019
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ For more information about this file see also [Keep a Changelog](http://keepacha
- The `parse` option to `PEcAn.utils::read_web_config` had no effect when `expand` was TRUE (#2421).

### Changed
- Stricter package checking (#2404): `make check` and CI builds will now fail if `R CMD check` returns any ERRORs or any "newly-added" WARNINGs or NOTEs. "Newly-added" is determined by strict string comparison against a check result saved 2019-09-03; messages that exist in the reference result do not break the build but will be fixed as time allows in future refactorings.
- Updated modules/rtm PROSPECT docs
- Updated models/sipnet/R/model2netcdf.SIPNET.R to address issues in PR #2254
- Improved testing (#2281). Automatic Travis CI builds of PEcAn on are now run using three versions of R in parallel. This should mean fewer issues with new releases and better backwards compatibility, but note that we still only guarantee full compatibility with the current release version of R. The tested versions are:
Expand Down
4 changes: 1 addition & 3 deletions base/all/data/pecan.packages.csv
Original file line number Diff line number Diff line change
@@ -1,4 +1,2 @@
1;2;3;4;5;6;7;8;9;10;11;12;13;14;15;16;17;18
"utils";"common";"db";"modules/meta.analysis";"modules/uncertainty";"modules/emulator";"modules/assim.batch";"modules/assim.sequential";"modules/data.land";"modules/photosythesis";"modules/priors";"modules/rtm";"modules/benchmark";models/c4photo";"models/ed";"models/sipnet";"models/maat";"all"


"utils";"common";"db";"modules/meta.analysis";"modules/uncertainty";"modules/emulator";"modules/assim.batch";"modules/assim.sequential";"modules/data.land";"modules/photosythesis";"modules/priors";"modules/rtm";"modules/benchmark";"models/c4photo";"models/ed";"models/sipnet";"models/maat";"all"
58 changes: 58 additions & 0 deletions base/all/tests/Rcheck_reference.log
Original file line number Diff line number Diff line change
@@ -0,0 +1,58 @@
* using log directory ‘/tmp/Rtmp3UHCCJ/PEcAn.all.Rcheck’
* using R version 3.5.2 (2018-12-20)
* using platform: x86_64-pc-linux-gnu (64-bit)
* using session charset: UTF-8
* using options ‘--no-tests --no-manual --as-cran’
* checking for file ‘PEcAn.all/DESCRIPTION’ ... OK
* checking extension type ... Package
* this is package ‘PEcAn.all’ version ‘1.7.0’
* package encoding: UTF-8
* checking package namespace information ... OK
* checking package dependencies ... NOTE
Depends: includes the non-default packages:
‘PEcAn.DB’ ‘PEcAn.settings’ ‘PEcAn.MA’ ‘PEcAn.logger’ ‘PEcAn.utils’
‘PEcAn.uncertainty’ ‘PEcAn.data.atmosphere’ ‘PEcAn.data.land’
‘PEcAn.data.remote’ ‘PEcAn.assim.batch’ ‘PEcAn.emulator’
‘PEcAn.priors’ ‘PEcAn.benchmark’ ‘PEcAn.remote’ ‘PEcAn.workflow’
Adding so many packages to the search path is excessive and importing
selectively is preferable.
* checking if this is a source package ... OK
* checking if there is a namespace ... OK
* checking for executable files ... OK
* checking for hidden files and directories ... OK
* checking for portable file names ... OK
* checking for sufficient/correct file permissions ... OK
* checking serialization versions ... OK
* checking whether package ‘PEcAn.all’ can be installed ... OK
* checking installed package size ... OK
* checking package directory ... OK
* checking DESCRIPTION meta-information ... NOTE
License components with restrictions not permitted:
FreeBSD + file LICENSE
Authors@R field gives no person with name and roles.
Authors@R field gives no person with maintainer role, valid email
address and non-empty name.
* checking top-level files ... OK
* checking for left-over files ... OK
* checking index information ... OK
* checking package subdirectories ... OK
* checking whether the package can be loaded ... OK
* checking whether the package can be loaded with stated dependencies ... OK
* checking whether the package can be unloaded cleanly ... OK
* checking whether the namespace can be loaded with stated dependencies ... OK
* checking whether the namespace can be unloaded cleanly ... OK
* checking loading without being on the library search path ... OK
* checking for missing documentation entries ... WARNING
Undocumented data sets:
‘pecan.packages’
All user-level objects in a package should have documentation entries.
See chapter ‘Writing R documentation files’ in the ‘Writing R
Extensions’ manual.
* checking contents of ‘data’ directory ... OK
* checking data for non-ASCII characters ... OK
* checking data for ASCII and uncompressed saves ... OK
* checking examples ... NONE
* checking for unstated dependencies in ‘tests’ ... OK
* checking tests ... SKIPPED
* DONE
Status: 1 WARNING, 2 NOTEs
199 changes: 199 additions & 0 deletions base/db/tests/Rcheck_reference.log
Original file line number Diff line number Diff line change
@@ -0,0 +1,199 @@
* using log directory ‘/tmp/RtmpzhxcCR/PEcAn.DB.Rcheck’
* using R version 3.5.2 (2018-12-20)
* using platform: x86_64-pc-linux-gnu (64-bit)
* using session charset: UTF-8
* using options ‘--no-tests --no-manual --as-cran’
* checking for file ‘PEcAn.DB/DESCRIPTION’ ... OK
* checking extension type ... Package
* this is package ‘PEcAn.DB’ version ‘1.7.0’
* package encoding: UTF-8
* checking package namespace information ... OK
* checking package dependencies ... OK
* checking if this is a source package ... OK
* checking if there is a namespace ... OK
* checking for executable files ... OK
* checking for hidden files and directories ... OK
* checking for portable file names ... OK
* checking for sufficient/correct file permissions ... OK
* checking serialization versions ... OK
* checking whether package ‘PEcAn.DB’ can be installed ... OK
* checking installed package size ... OK
* checking package directory ... OK
* checking DESCRIPTION meta-information ... NOTE
License components with restrictions not permitted:
FreeBSD + file LICENSE
* checking top-level files ... OK
* checking for left-over files ... OK
* checking index information ... OK
* checking package subdirectories ... OK
* checking R files for non-ASCII characters ... OK
* checking R files for syntax errors ... OK
* checking whether the package can be loaded ... OK
* checking whether the package can be loaded with stated dependencies ... OK
* checking whether the package can be unloaded cleanly ... OK
* checking whether the namespace can be loaded with stated dependencies ... OK
* checking whether the namespace can be unloaded cleanly ... OK
* checking loading without being on the library search path ... OK
* checking dependencies in R code ... WARNING
'::' or ':::' import not declared from: ‘bit64’
'loadNamespace' or 'requireNamespace' call not declared from: ‘bit64’
* checking S3 generic/method consistency ... OK
* checking replacement functions ... OK
* checking foreign function calls ... OK
* checking R code for possible problems ... NOTE
clone_pft: no visible binding for global variable ‘name’
clone_pft: no visible binding for global variable ‘id’
clone_pft: no visible binding for global variable ‘created_at’
clone_pft: no visible binding for global variable ‘updated_at’
clone_pft: no visible binding for global variable ‘pft_id’
db.exists: no visible binding for '<<-' assignment to ‘user.permission’
db.exists: no visible binding for global variable ‘user.permission’
dbfile.check: no visible binding for global variable ‘container_type’
dbfile.check: no visible binding for global variable ‘container_id’
dbfile.check: no visible binding for global variable ‘machine_id’
dbfile.check: no visible binding for global variable ‘updated_at’
dbHostInfo: no visible binding for global variable ‘sync_host_id’
dbHostInfo: no visible binding for global variable ‘sync_start’
dbHostInfo: no visible binding for global variable ‘sync_end’
get_run_ids: no visible binding for global variable ‘run_id’
get_users: no visible binding for global variable ‘id’
get_workflow_ids: no visible binding for global variable ‘workflow_id’
get.trait.data.pft: no visible binding for global variable ‘pft_id’
get.trait.data.pft: no visible binding for global variable ‘created_at’
get.trait.data.pft: no visible global function definition for ‘head’
get.trait.data.pft: no visible binding for global variable ‘stat’
get.trait.data.pft: no visible binding for global variable ‘trait’
insert.format.vars: no visible binding for global variable ‘id’
insert.format.vars: no visible binding for global variable ‘name’
insert.format.vars: no visible global function definition for ‘collect’
load_data_single_run: no visible global function definition for
‘read.output’
load_data_single_run: no visible binding for global variable ‘var_name’
load_data_single_run: no visible binding for global variable ‘vals’
load_data_single_run: no visible binding for global variable ‘posix’
match_dbcols: no visible global function definition for ‘head’
match_dbcols: no visible binding for global variable ‘.’
match_dbcols: no visible binding for global variable ‘as’
query_pfts: no visible binding for global variable ‘name’
query.data: no visible binding for global variable ‘settings’
query.format.vars: no visible binding for global variable ‘variable_id’
query.format.vars: no visible binding for global variable
‘storage_type’
query.pft_cultivars: no visible binding for global variable ‘name’
query.pft_cultivars: no visible binding for global variable ‘pft_type’
query.pft_cultivars: no visible binding for global variable ‘name.mt’
query.pft_cultivars: no visible binding for global variable
‘cultivar_id’
query.pft_cultivars: no visible binding for global variable ‘specie_id’
query.pft_cultivars: no visible binding for global variable ‘genus’
query.pft_cultivars: no visible binding for global variable ‘species’
query.pft_cultivars: no visible binding for global variable
‘scientificname’
query.pft_cultivars: no visible binding for global variable ‘name.cv’
query.priors: no visible binding for global variable ‘settings’
query.traits: no visible binding for global variable ‘settings’
query.traits: no visible binding for global variable ‘name’
rename_jags_columns: no visible binding for global variable ‘stat’
rename_jags_columns: no visible binding for global variable ‘n’
rename_jags_columns: no visible binding for global variable ‘trt_id’
rename_jags_columns: no visible binding for global variable ‘site_id’
rename_jags_columns: no visible binding for global variable
‘citation_id’
rename_jags_columns: no visible binding for global variable
‘greenhouse’
runs: no visible binding for global variable ‘folder’
runs: no visible binding for global variable ‘id’
runs: no visible binding for global variable ‘ensemble_id’
search_reference_single: no visible binding for global variable ‘score’
search_reference_single: no visible binding for global variable
‘author’
search_reference_single: no visible binding for global variable
‘author_family’
search_reference_single: no visible binding for global variable
‘author_given’
search_reference_single: no visible binding for global variable
‘issued’
symmetric_setdiff: no visible global function definition for ‘:=’
workflows: no visible binding for global variable ‘workflow_id’
Undefined global functions or variables:
:= . as author author_family author_given citation_id collect
container_id container_type created_at cultivar_id ensemble_id folder
genus greenhouse head id issued machine_id n name name.cv name.mt
pft_id pft_type posix read.output run_id scientificname score
settings site_id specie_id species stat storage_type sync_end
sync_host_id sync_start trait trt_id updated_at user.permission vals
var_name variable_id workflow_id
Consider adding
importFrom("methods", "as")
importFrom("utils", "head")
to your NAMESPACE file (and ensure that your DESCRIPTION Imports field
contains 'methods').
* checking Rd files ... OK
* checking Rd metadata ... OK
* checking Rd line widths ... NOTE
Rd file 'dbfile.input.insert.Rd':
\examples lines wider than 100 characters:
dbfile.input.insert('trait.data.Rdata', siteid, startdate, enddate, 'application/x-RData', 'traits', dbcon)

Rd file 'insert.format.vars.Rd':
\examples lines wider than 100 characters:
insert.format.vars(con = bety$con, format_name = "LTER-HFR-103", mimetype_id = 1090, notes = "NPP from Harvard Forest.", header = FAL ... [TRUNCATED]

Rd file 'query.data.Rd':
\usage lines wider than 90 characters:
extra.columns = "ST_X(ST_CENTROID(sites.geometry)) AS lon, ST_Y(ST_CENTROID(sites.geometry)) AS lat, ",

These lines will be truncated in the PDF manual.
* checking Rd cross-references ... OK
* checking for missing documentation entries ... OK
* checking for code/documentation mismatches ... OK
* checking Rd \usage sections ... WARNING
Undocumented arguments in documentation object 'get_workflow_ids'
‘all.ids’

Undocumented arguments in documentation object 'ncdays2date'
‘time’ ‘unit’

Undocumented arguments in documentation object 'query.data'
‘store.unconverted’

Undocumented arguments in documentation object 'query.file.path'
‘input.id’
Documented arguments not in \usage in documentation object 'query.file.path':
‘input_id’

Undocumented arguments in documentation object 'query.format.vars'
‘input.id’
Documented arguments not in \usage in documentation object 'query.format.vars':
‘input_id’

Undocumented arguments in documentation object 'query.site'
‘site.id’
Documented arguments not in \usage in documentation object 'query.site':
‘site_id’

Undocumented arguments in documentation object 'query.trait.data'
‘con’ ‘update.check.only’ ‘...’

Undocumented arguments in documentation object 'query_pfts'
‘strict’

Functions with \usage entries need to have the appropriate \alias
entries, and all their arguments documented.
The \usage entries must correspond to syntactically valid R code.
See chapter ‘Writing R documentation files’ in the ‘Writing R
Extensions’ manual.
* checking Rd contents ... WARNING
Argument items with no description in Rd object 'query_pfts':
‘modeltype’

* checking for unstated dependencies in examples ... OK
* checking files in ‘vignettes’ ... WARNING
Files in the 'vignettes' directory but no files in 'inst/doc':
‘betydb_access.Rmd’, ‘create_sites.geometry.Rmd’
Package has no Sweave vignette sources and no VignetteBuilder field.
* checking examples ... OK
* checking for unstated dependencies in ‘tests’ ... OK
* checking tests ... SKIPPED
* DONE
Status: 4 WARNINGs, 3 NOTEs
89 changes: 89 additions & 0 deletions base/logger/tests/Rcheck_reference.log
Original file line number Diff line number Diff line change
@@ -0,0 +1,89 @@
* using log directory ‘/tmp/Rtmp1Q6pph/PEcAn.logger.Rcheck’
* using R version 3.5.2 (2018-12-20)
* using platform: x86_64-pc-linux-gnu (64-bit)
* using session charset: UTF-8
* using options ‘--no-manual --as-cran’
* checking for file ‘PEcAn.logger/DESCRIPTION’ ... OK
* this is package ‘PEcAn.logger’ version ‘1.7.0’
* package encoding: UTF-8
* checking package namespace information ... OK
* checking package dependencies ... OK
* checking if this is a source package ... OK
* checking if there is a namespace ... OK
* checking for executable files ... OK
* checking for hidden files and directories ... OK
* checking for portable file names ... OK
* checking for sufficient/correct file permissions ... OK
* checking serialization versions ... OK
* checking whether package ‘PEcAn.logger’ can be installed ... OK
* checking installed package size ... OK
* checking package directory ... OK
* checking DESCRIPTION meta-information ... NOTE
License components with restrictions not permitted:
FreeBSD + file LICENSE
Authors@R field gives no person with name and roles.
Authors@R field gives no person with maintainer role, valid email
address and non-empty name.
* checking top-level files ... OK
* checking for left-over files ... OK
* checking index information ... OK
* checking package subdirectories ... OK
* checking R files for non-ASCII characters ... OK
* checking R files for syntax errors ... OK
* checking whether the package can be loaded ... OK
* checking whether the package can be loaded with stated dependencies ... OK
* checking whether the package can be unloaded cleanly ... OK
* checking whether the namespace can be loaded with stated dependencies ... OK
* checking whether the namespace can be unloaded cleanly ... OK
* checking loading without being on the library search path ... OK
* checking dependencies in R code ... OK
* checking S3 generic/method consistency ... OK
* checking replacement functions ... OK
* checking foreign function calls ... OK
* checking R code for possible problems ... NOTE
logger.message: no visible global function definition for ‘dump.frames’
logger.message: no visible binding for global variable ‘dump.log’
logger.message: no visible global function definition for ‘tail’
print2string: no visible global function definition for
‘capture.output’
Undefined global functions or variables:
capture.output dump.frames dump.log tail
Consider adding
importFrom("utils", "capture.output", "dump.frames", "tail")
to your NAMESPACE file.
* checking Rd files ... OK
* checking Rd metadata ... OK
* checking Rd line widths ... NOTE
Rd file 'severeifnot.Rd':
\examples lines wider than 100 characters:
severeifnot("I absolutely cannot deal with the fact that something is not a list.", is.list(a), is.list(b))

These lines will be truncated in the PDF manual.
* checking Rd cross-references ... WARNING
Missing link or links in documentation object 'logger.severe.Rd':
‘logger.setQuitOnSevere(FALSE)’

See section 'Cross-references' in the 'Writing R Extensions' manual.

* checking for missing documentation entries ... OK
* checking for code/documentation mismatches ... OK
* checking Rd \usage sections ... WARNING
Undocumented arguments in documentation object 'check_conditions'
‘...’

Undocumented arguments in documentation object 'is_definitely_true'
‘x’

Undocumented arguments in documentation object 'logger.getLevelNumber'
‘level’

Functions with \usage entries need to have the appropriate \alias
entries, and all their arguments documented.
The \usage entries must correspond to syntactically valid R code.
See chapter ‘Writing R documentation files’ in the ‘Writing R
Extensions’ manual.
* checking Rd contents ... OK
* checking for unstated dependencies in examples ... OK
* checking examples ... OK
* DONE
Status: 2 WARNINGs, 3 NOTEs