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

Warnings during installation are not shown #167

Open
gaborcsardi opened this issue Sep 29, 2021 · 2 comments
Open

Warnings during installation are not shown #167

gaborcsardi opened this issue Sep 29, 2021 · 2 comments
Labels
bug an unexpected problem or unintended behavior tidy-dev-day 🤓 Tidyverse Developer Day rstd.io/tidy-dev-day

Comments

@gaborcsardi
Copy link
Member

gaborcsardi commented Sep 29, 2021

E.g. https://github.com/r-lib/sessioninfo/runs/3748776702?check_suite_focus=true

One way to trigger this is to unset DISPLAY and then check some package imports tcltk on macOS:

~/works/sessioninfo d611a4f...
❯ R CMD INSTALL .
* installing to library ‘/Users/gaborcsardi/Library/R/x86_64/4.1/library’
* installing *source* package ‘sessioninfo’ ...
** using staged installation
** R
** byte-compile and prepare package for lazy loading
Warning in fun(libname, pkgname) :
  no display name and no $DISPLAY environment variable
** help
*** installing help indices
** building package indices
** testing if installed package can be loaded from temporary location
Warning in fun(libname, pkgname) :
  no display name and no $DISPLAY environment variable
** testing if installed package can be loaded from final location
Warning in fun(libname, pkgname) :
  no display name and no $DISPLAY environment variable
** testing if installed package keeps a record of temporary installation path
* DONE (sessioninfo)
@gaborcsardi gaborcsardi added the bug an unexpected problem or unintended behavior label Sep 29, 2021
@gaborcsardi gaborcsardi added the tidy-dev-day 🤓 Tidyverse Developer Day rstd.io/tidy-dev-day label Jul 17, 2024
@kevinushey
Copy link
Contributor

Maybe I'm misunderstanding something, but rcmdcheck doesn't invoke R CMD INSTALL -- it just uses R CMD build and R CMD check, so these installation errors are normally never seen.

For example, with a dummy package:

==> R CMD INSTALL --preclean --no-multiarch --with-keep.source where.errors

* installing to library ‘/Users/kevin/Library/R/arm64/4.4/library’
* installing *source* package ‘where.errors’ ...
** using staged installation
** R
** byte-compile and prepare package for lazy loading
** help
*** installing help indices
** building package indices
** testing if installed package can be loaded from temporary location
Warning in fun(libname, pkgname) :
  no display name and no $DISPLAY environment variable
** testing if installed package can be loaded from final location
Warning in fun(libname, pkgname) :
  no display name and no $DISPLAY environment variable
** testing if installed package keeps a record of temporary installation path
* DONE (where.errors)

But, with build + check:

kevin@MBP-P2MQ:~/projects
$ R CMD build where.errors
* checking for file ‘where.errors/DESCRIPTION’ ... OK
* preparing ‘where.errors’:
* checking DESCRIPTION meta-information ... OK
* checking for LF line-endings in source and make files and shell scripts
* checking for empty or unneeded directories
Omitted ‘LazyData’ from DESCRIPTION
* building ‘where.errors_0.1.0.tar.gz’

kevin@MBP-P2MQ:~/projects
$ R CMD check where.errors_0.1.0.tar.gz
* using log directory ‘/Users/kevin/projects/where.errors.Rcheck’
* using R version 4.4.1 (2024-06-14)
* using platform: aarch64-apple-darwin20
* R was compiled by
    Apple clang version 14.0.0 (clang-1400.0.29.202)
    GNU Fortran (GCC) 12.2.0
* running under: macOS Sonoma 14.5
* using session charset: UTF-8
* checking for file ‘where.errors/DESCRIPTION’ ... OK
* checking extension type ... Package
* this is package ‘where.errors’ version ‘0.1.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 whether package ‘where.errors’ can be installed ... OK
* checking installed package size ... OK
* checking package directory ... OK
* checking DESCRIPTION meta-information ... OK
* checking top-level files ... OK
* checking for left-over files ... OK
* checking index information ... OK
* checking package subdirectories ... OK
* checking code 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 whether startup messages can be suppressed ... 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 ... OK
* checking Rd files ... OK
* checking Rd metadata ... OK
* checking Rd cross-references ... OK
* checking for missing documentation entries ... OK
* checking for code/documentation mismatches ... OK
* checking Rd \usage sections ... OK
* checking Rd contents ... OK
* checking for unstated dependencies in examples ... OK
* checking examples ... OK
* checking PDF version of manual ... OK
* DONE

Status: OK

So even R never reports these warnings. Or am I missing something?

@gaborcsardi
Copy link
Member Author

So maybe there is nothing to do here. Or maybe we could show the installation output from 00install.out, still? Although it would be potentially difficult to decide when to do that.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug an unexpected problem or unintended behavior tidy-dev-day 🤓 Tidyverse Developer Day rstd.io/tidy-dev-day
Projects
None yet
Development

No branches or pull requests

2 participants