Re: [R-pkg-devel] The Help (e.g. links) is not working for my packages

2017-08-10 Thread David.Kaethner
sorry, I got sloppy - I had played around before with the DESCRIPTION file, 
that does not seem to be the culprit. But you are right of course, it should 
run without warnings in any case.



* using log directory 
�/Users/spaceicons/code/R_package_dev/helpers2/helpers2.Rcheck�
* using R version 3.4.1 (2017-06-30)
* using platform: x86_64-apple-darwin15.6.0 (64-bit)
* using session charset: UTF-8
* checking for file �helpers2/DESCRIPTION� ... OK
* this is package �helpers2� version �0.1�
* 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 �helpers2� 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 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 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




Von: Dason Kurkiewicz [das...@gmail.com]
Gesendet: Donnerstag, 10. August 2017 18:42
An: K�thner, David
Cc: Duncan Murdoch; R package devel; e...@debian.org; li...@dewey.myzen.co.uk
Betreff: Re: [R-pkg-devel] The Help (e.g. links) is not working for my packages

It tells you what the warning is. You need to specify a license in your 
DESCRIPTION file. You should really fill the entire thing out properly anyways.

On Aug 10, 2017 12:39 PM, mailto:david.kaeth...@dlr.de>> 
wrote:
Thank you for pointing that out, this solved the ERROR in the R CMD check. I've 
updated the repo.

Unfortunately, it did not solve the problem. So when you clone/pull the repo 
now, the error should persist.


* using log directory 
�/Users/spaceicons/code/R_package_dev/helpers2/helpers2.Rcheck�
* using R version 3.4.1 (2017-06-30)
* using platform: x86_64-apple-darwin15.6.0 (64-bit)
* using session charset: UTF-8
* checking for file �helpers2/DESCRIPTION� ... OK
* checking extension type ... Package
* this is package �helpers2� 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 �helpers2� can be installed ... OK
* checking installed package size ... OK
* checking package directory ... OK
* checking DESCRIPTION meta-information ... WARNING
Non-standard license specification:
  What license is it under?
Standardizable: FALSE
* 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 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 ..

Re: [R-pkg-devel] The Help (e.g. links) is not working for my packages

2017-08-10 Thread Dason Kurkiewicz
It tells you what the warning is. You need to specify a license in your
DESCRIPTION file. You should really fill the entire thing out properly
anyways.

On Aug 10, 2017 12:39 PM,  wrote:

> Thank you for pointing that out, this solved the ERROR in the R CMD check.
> I've updated the repo.
>
> Unfortunately, it did not solve the problem. So when you clone/pull the
> repo now, the error should persist.
>
>
> * using log directory ‘/Users/spaceicons/code/R_
> package_dev/helpers2/helpers2.Rcheck’
> * using R version 3.4.1 (2017-06-30)
> * using platform: x86_64-apple-darwin15.6.0 (64-bit)
> * using session charset: UTF-8
> * checking for file ‘helpers2/DESCRIPTION’ ... OK
> * checking extension type ... Package
> * this is package ‘helpers2’ 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 ‘helpers2’ can be installed ... OK
> * checking installed package size ... OK
> * checking package directory ... OK
> * checking DESCRIPTION meta-information ... WARNING
> Non-standard license specification:
>   What license is it under?
> Standardizable: FALSE
> * 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 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: 1 WARNING
>
>
>
> 
> Von: Michael Dewey [li...@dewey.myzen.co.uk]
> Gesendet: Donnerstag, 10. August 2017 17:38
> An: Käthner, David; e...@debian.org; murdoch.dun...@gmail.com
> Cc: r-package-devel@r-project.org
> Betreff: Re: [R-pkg-devel] The Help (e.g. links) is not working for my
> packages
>
> Your log says you have no examples but you do in your Rd file.
> Your examples look the wrong way round x(function) rather than function(x)
>
> Not sure whether those are relevant issues but perhaps they help.
>
> On 10/08/2017 15:47, david.kaeth...@dlr.de wrote:
> > Thank you for the replies!
> >
> > First of all, here is the test package:
> > https://github.com/c06n/helpers2
> >
> > Session info and the log of R CMD check at the end. There is an error:
> "LaTeX errors when creating PDF version." However, it says "checking Rd
> files ... OK".
> >
> > I have tried the install now on 4 different computers (via
> devtools::install_github), they all did not work.
> >
> > Further points:
> > - Unfortunately, installation from a tarball did not work either. I
> build the tarball from the command line (Cygwin), then used R CMD, but
> tried it also from within RStudio ("Build Source Package", then
> "install.packages")
> > - I have managed to create another package WHICH WORKS. I have not been
> able to do it again though, I just don't know what I did differently.
> > - I played around with the documentation lines in the test package, to
> no avail.
> >
> > I am sure that it is something very minor where I went wrong, and in all
> likelihood the problem is on my side. I just cannot figure out what it
> might be.
> >
> > David
> >
> > -
> >> sessionInfo()
> > R version 3.4.1 (2017-06-30)
> > Platform: x86_64-w64-mingw32/x64 (64-bit)
> > Running under: Windows 7 x64 (build 7601) Service Pack 1
> >
> > Matrix products: default
> >
> > locale:
> > [1] LC_COLLATE=German_Germany.1252  LC_CTYPE=German_Germany.1252
> > [3] LC_MONETARY=German_Germany.1252 LC_NUMERIC=C
> > [5] LC_TIME=German_Germany.1252
> >
> > attached base packages:
> > [1] stats graphics  grDevices utils datasets  methods   base
> >
> > other attached packages:
> > [1] _0.1.0
> >
> > loaded via a namespace (and not attached):
> > [1

Re: [R-pkg-devel] The Help (e.g. links) is not working for my packages

2017-08-10 Thread David.Kaethner
Thank you for pointing that out, this solved the ERROR in the R CMD check. I've 
updated the repo.

Unfortunately, it did not solve the problem. So when you clone/pull the repo 
now, the error should persist.


* using log directory 
‘/Users/spaceicons/code/R_package_dev/helpers2/helpers2.Rcheck’
* using R version 3.4.1 (2017-06-30)
* using platform: x86_64-apple-darwin15.6.0 (64-bit)
* using session charset: UTF-8
* checking for file ‘helpers2/DESCRIPTION’ ... OK
* checking extension type ... Package
* this is package ‘helpers2’ 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 ‘helpers2’ can be installed ... OK
* checking installed package size ... OK
* checking package directory ... OK
* checking DESCRIPTION meta-information ... WARNING
Non-standard license specification:
  What license is it under?
Standardizable: FALSE
* 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 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: 1 WARNING




Von: Michael Dewey [li...@dewey.myzen.co.uk]
Gesendet: Donnerstag, 10. August 2017 17:38
An: Käthner, David; e...@debian.org; murdoch.dun...@gmail.com
Cc: r-package-devel@r-project.org
Betreff: Re: [R-pkg-devel] The Help (e.g. links) is not working for my packages

Your log says you have no examples but you do in your Rd file.
Your examples look the wrong way round x(function) rather than function(x)

Not sure whether those are relevant issues but perhaps they help.

On 10/08/2017 15:47, david.kaeth...@dlr.de wrote:
> Thank you for the replies!
>
> First of all, here is the test package:
> https://github.com/c06n/helpers2
>
> Session info and the log of R CMD check at the end. There is an error: "LaTeX 
> errors when creating PDF version." However, it says "checking Rd files ... 
> OK".
>
> I have tried the install now on 4 different computers (via 
> devtools::install_github), they all did not work.
>
> Further points:
> - Unfortunately, installation from a tarball did not work either. I build the 
> tarball from the command line (Cygwin), then used R CMD, but tried it also 
> from within RStudio ("Build Source Package", then "install.packages")
> - I have managed to create another package WHICH WORKS. I have not been able 
> to do it again though, I just don't know what I did differently.
> - I played around with the documentation lines in the test package, to no 
> avail.
>
> I am sure that it is something very minor where I went wrong, and in all 
> likelihood the problem is on my side. I just cannot figure out what it might 
> be.
>
> David
>
> -
>> sessionInfo()
> R version 3.4.1 (2017-06-30)
> Platform: x86_64-w64-mingw32/x64 (64-bit)
> Running under: Windows 7 x64 (build 7601) Service Pack 1
>
> Matrix products: default
>
> locale:
> [1] LC_COLLATE=German_Germany.1252  LC_CTYPE=German_Germany.1252
> [3] LC_MONETARY=German_Germany.1252 LC_NUMERIC=C
> [5] LC_TIME=German_Germany.1252
>
> attached base packages:
> [1] stats graphics  grDevices utils datasets  methods   base
>
> other attached packages:
> [1] _0.1.0
>
> loaded via a namespace (and not attached):
> [1] compiler_3.4.1 tools_3.4.1
>
> 
> * using log directory 
> '/cygdrive/d/Home/projects/R_package_dev/helpers2.Rcheck'
> * using R version 3.4.0 (2017-04-21)
> * using platform: x86_64-unknown-cygwin (64-bit)
> * using session charset: ISO8859-1
> * checking for file 'helpers2/DESCRIPTION' ... OK
> * checking extension type ... Package
> * this is package 'helpers2' version '0.1.0'
> * package

Re: [R-pkg-devel] The Help (e.g. links) is not working for my packages

2017-08-10 Thread Michael Dewey

Your log says you have no examples but you do in your Rd file.
Your examples look the wrong way round x(function) rather than function(x)

Not sure whether those are relevant issues but perhaps they help.

On 10/08/2017 15:47, david.kaeth...@dlr.de wrote:

Thank you for the replies!

First of all, here is the test package:
https://github.com/c06n/helpers2

Session info and the log of R CMD check at the end. There is an error: "LaTeX errors when 
creating PDF version." However, it says "checking Rd files ... OK".

I have tried the install now on 4 different computers (via 
devtools::install_github), they all did not work.

Further points:
- Unfortunately, installation from a tarball did not work either. I build the tarball from the 
command line (Cygwin), then used R CMD, but tried it also from within RStudio ("Build Source 
Package", then "install.packages")
- I have managed to create another package WHICH WORKS. I have not been able to 
do it again though, I just don't know what I did differently.
- I played around with the documentation lines in the test package, to no avail.

I am sure that it is something very minor where I went wrong, and in all 
likelihood the problem is on my side. I just cannot figure out what it might be.

David

-

sessionInfo()

R version 3.4.1 (2017-06-30)
Platform: x86_64-w64-mingw32/x64 (64-bit)
Running under: Windows 7 x64 (build 7601) Service Pack 1

Matrix products: default

locale:
[1] LC_COLLATE=German_Germany.1252  LC_CTYPE=German_Germany.1252
[3] LC_MONETARY=German_Germany.1252 LC_NUMERIC=C
[5] LC_TIME=German_Germany.1252

attached base packages:
[1] stats graphics  grDevices utils datasets  methods   base

other attached packages:
[1] _0.1.0

loaded via a namespace (and not attached):
[1] compiler_3.4.1 tools_3.4.1


* using log directory '/cygdrive/d/Home/projects/R_package_dev/helpers2.Rcheck'
* using R version 3.4.0 (2017-04-21)
* using platform: x86_64-unknown-cygwin (64-bit)
* using session charset: ISO8859-1
* checking for file 'helpers2/DESCRIPTION' ... OK
* checking extension type ... Package
* this is package 'helpers2' 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 'helpers2' can be installed ... OK
* checking installed package size ... OK
* checking package directory ... OK
* checking DESCRIPTION meta-information ... WARNING
Non-standard license specification:
  testlicense
Standardizable: FALSE
* 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 ... 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 ... NONE
* checking PDF version of manual ... WARNING
LaTeX errors when creating PDF version.
This typically indicates Rd problems.
* checking PDF version of manual without hyperrefs or index ... ERROR
* DONE
Status: 1 ERROR, 2 WARNINGs












-Ursprüngliche Nachricht-
Von: Dirk Eddelbuettel [mailto:dirk.eddelbuet...@gmail.com] Im Auftrag von Dirk 
Eddelbuettel
Gesendet: Donnerstag, 10. August 2017 14:32
An: Duncan Murdoch
Cc: Käthner, David; r-package-devel@r-project.org
Betreff: Re: [R-pkg-devel] The Help (e.g. links) is not working for my packages


On 9 August 2017 at 08:38, Duncan Murdoch wrote:
| Nothing that you've written is reproducible by others.  See if you can
| put together a short self-contained series of instructions that
| display the problems (or just one of them).  It might involve
| installing from Github, or making a package tarball available somewhere.

I am fairly certain I have observed this myself, and I *think* it simply stems 
from running R C

Re: [R-pkg-devel] The Help (e.g. links) is not working for my packages

2017-08-10 Thread David.Kaethner
Thank you for the replies!

First of all, here is the test package: 
https://github.com/c06n/helpers2

Session info and the log of R CMD check at the end. There is an error: "LaTeX 
errors when creating PDF version." However, it says "checking Rd files ... OK".

I have tried the install now on 4 different computers (via 
devtools::install_github), they all did not work. 

Further points:
- Unfortunately, installation from a tarball did not work either. I build the 
tarball from the command line (Cygwin), then used R CMD, but tried it also from 
within RStudio ("Build Source Package", then "install.packages")
- I have managed to create another package WHICH WORKS. I have not been able to 
do it again though, I just don't know what I did differently.
- I played around with the documentation lines in the test package, to no avail.

I am sure that it is something very minor where I went wrong, and in all 
likelihood the problem is on my side. I just cannot figure out what it might be.

David

-
> sessionInfo()
R version 3.4.1 (2017-06-30)
Platform: x86_64-w64-mingw32/x64 (64-bit)
Running under: Windows 7 x64 (build 7601) Service Pack 1

Matrix products: default

locale:
[1] LC_COLLATE=German_Germany.1252  LC_CTYPE=German_Germany.1252   
[3] LC_MONETARY=German_Germany.1252 LC_NUMERIC=C   
[5] LC_TIME=German_Germany.1252

attached base packages:
[1] stats graphics  grDevices utils datasets  methods   base 

other attached packages:
[1] _0.1.0 

loaded via a namespace (and not attached):
[1] compiler_3.4.1 tools_3.4.1  


* using log directory '/cygdrive/d/Home/projects/R_package_dev/helpers2.Rcheck'
* using R version 3.4.0 (2017-04-21)
* using platform: x86_64-unknown-cygwin (64-bit)
* using session charset: ISO8859-1
* checking for file 'helpers2/DESCRIPTION' ... OK
* checking extension type ... Package
* this is package 'helpers2' 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 'helpers2' can be installed ... OK
* checking installed package size ... OK
* checking package directory ... OK
* checking DESCRIPTION meta-information ... WARNING
Non-standard license specification:
  testlicense
Standardizable: FALSE
* 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 ... 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 ... NONE
* checking PDF version of manual ... WARNING
LaTeX errors when creating PDF version.
This typically indicates Rd problems.
* checking PDF version of manual without hyperrefs or index ... ERROR
* DONE
Status: 1 ERROR, 2 WARNINGs












-Ursprüngliche Nachricht-
Von: Dirk Eddelbuettel [mailto:dirk.eddelbuet...@gmail.com] Im Auftrag von Dirk 
Eddelbuettel
Gesendet: Donnerstag, 10. August 2017 14:32
An: Duncan Murdoch
Cc: Käthner, David; r-package-devel@r-project.org
Betreff: Re: [R-pkg-devel] The Help (e.g. links) is not working for my packages


On 9 August 2017 at 08:38, Duncan Murdoch wrote:
| Nothing that you've written is reproducible by others.  See if you can 
| put together a short self-contained series of instructions that 
| display the problems (or just one of them).  It might involve 
| installing from Github, or making a package tarball available somewhere.

I am fairly certain I have observed this myself, and I *think* it simply stems 
from running R CMD INSTALL (and alike) from a source directory, as opposed to a 
tarball.  I filed it under minor nuisance and didn't care too much either as 
the official two-step of 'R CMD build ...; R CMD INSTALL ...'
is just that: 

[R-pkg-devel] Error on rhub/fedora not appearing on CRAN

2017-08-10 Thread Mark van der Loo
Dear list,


I'm getting some false 'R CMD check' positives on rhub / Fedora: errors
appearing on rhub that are not reproduced by CRAN. I have reported the
matter here:

https://github.com/r-hub/rhub/issues/92

It happens reproducibly for at least two of my packages: validate and
lumberjack (I haven't tested any other yet).

In short, knitr tries to open a png device while compiling a vignette and
fails as follows.

W checking re-building of vignette outputs
  Error in re-building vignettes: ...
Warning in (function (filename = "Rplot%03d.png", width = 480, height =
480, :
  unable to open connection to X11 display ''

It runs fine on R-devel, R-oldrel, R on windoze, solaris, centos, my own
machines,..., and also on CRAN so it seems tied to rhub/Fedora.

I have tried the following things already

- Check whether R is called with xvfb-run (to simulate the X11 environment)
in rhub's log. That's the case
- Set up a minimal package with several vignettes and knitr settings, but I
could not reproduce it minimally.

If anyone has similar experiences it'd be nice to hear about it. Either for
a workaround, or to gather some evidence that we can pass to Gabor, if it
indeed is an rhub issue.

Cheers,
Mark

[[alternative HTML version deleted]]

__
R-package-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-package-devel


Re: [R-pkg-devel] The Help (e.g. links) is not working for my packages

2017-08-10 Thread Dirk Eddelbuettel

On 9 August 2017 at 08:38, Duncan Murdoch wrote:
| Nothing that you've written is reproducible by others.  See if you can 
| put together a short self-contained series of instructions that display 
| the problems (or just one of them).  It might involve installing from 
| Github, or making a package tarball available somewhere.

I am fairly certain I have observed this myself, and I *think* it simply
stems from running R CMD INSTALL (and alike) from a source directory, as
opposed to a tarball.  I filed it under minor nuisance and didn't care too
much either as the official two-step of 'R CMD build ...; R CMD INSTALL ...'
is just that: the official and recommended way. With which things work.

Dirk

-- 
http://dirk.eddelbuettel.com | @eddelbuettel | e...@debian.org

__
R-package-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-package-devel


Re: [R-pkg-devel] DBI connection at package load

2017-08-10 Thread frédéric Clement
hi duncan,
Thank you, it refreshed my memories on "local", cool.

About the dummy function to load packages, it lets Rstudio bring them in
the Namespace, kind of a tradeoff because of the warning I get in NAMESPACE
after building the documentation:
>>> # Generated by roxygen2: do not edit by hand

regards
frederic


On Fri, Aug 4, 2017 at 4:19 PM Duncan Murdoch 
wrote:

> On 04/08/2017 5:51 AM, frédéric Clement wrote:
> > Hello,
> >
> > I want to use a package to load and set up a working environment (Only
> > intern used). It has function, but also create a connection object
> > (RPostgreSQL) to make dplyr::tbl implicitely use this connection.
> >
> > After trying to save the connection object in "Data\"... and failed. I
> made
> > the following work around.
> >
> > Is it the right way to do it, or should it be solved in other ways.
> >
> > PS: This is my first attent at package development experience, I mainly
> > follow http://r-pkgs.had.co.nz/
> >
> > regards
> >
> > frederic Clement
> >
> > - the script
> >
> > .onAttach <- function(libname = find.package("dbName"), pkgname =
> "dbName")
> > {
> >   packageStartupMessage("Intranet Company required")
> >
> >   dbNameConPool = dbName_create_pool()
> >   assign("dbNameConPool", dbNameConPool, envir =
> > as.environment("package:dbName"))
> > }
>
> Usually you should use .onLoad, not .onAttach.  If someone who hasn't
> attached your package calls one of the functions using dbName::fn(...),
> your package will be loaded but not attached.  Similarly if another
> package imports one of your functions.
>
>
> >
> >
> > ## This is a function so that I can call it in .onAttach
> > ##
> > dbName_create_pool = function(){
> >
> > DBI::dbConnect(drv = RPostgreSQL::PostgreSQL(),
> >  user = "dbName",
> >  password = .rs.askForPassword("Enter password:"),
> >  port = ,
> >  host = "dbName-int.company.com")
> > }
>
> However, for this particular use, it might be bad to put the code even
> in .onLoad.  A better way to go would be to have a function in your
> package that calls dbName_create_pool the first time you call it, and
> just returns the same value on subsequent calls.  For example,
>
> getcon <- local({
>con <- NULL
>function() {
>  if (is.null(con))
>con <<- dbName_create_pool()
>  con
>}})
>
>
> This way nobody is prompted for a password unless they actually need to
> access the database.
>
> >
> > #' Dummy function
> > #'
> > #' Only used for package build purpose
> > #' to import the usefull function.
> > #' @return NULL
> > #' @export
> > #' @import dplyr dbplyr DBI magrittr RPostgreSQL tidyr
> > #'
> > #' @examples
> > #' fun_import()
> > fun_import <- function(){
> >   NULL
> > }
>
> Not sure why you'd want these 13 lines instead of editing your NAMESPACE
> file, but that's your choice...
>
> Duncan Murdoch
>
> >
> > --- session
> >
> > R version 3.4.1 (2017-06-30)
> > Platform: i386-w64-mingw32/i386 (32-bit)
> > Running under: Windows >= 8 x64 (build 9200)
> >
> > Matrix products: default
> >
> > locale:
> > [1] LC_COLLATE=German_Germany.1252  LC_CTYPE=German_Germany.1252
> > LC_MONETARY=German_Germany.1252 LC_NUMERIC=C
> > LC_TIME=German_Germany.1252
> >
> > attached base packages:
> > [1] stats graphics  grDevices utils datasets  methods   base
> >
> > loaded via a namespace (and not attached):
> > [1] compiler_3.4.1 tools_3.4.1
> >
> >   [[alternative HTML version deleted]]
> >
> > __
> > R-package-devel@r-project.org mailing list
> > https://stat.ethz.ch/mailman/listinfo/r-package-devel
> >
>
>

[[alternative HTML version deleted]]

__
R-package-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-package-devel

[R-pkg-devel] Generic method redefinition and dispatch

2017-08-10 Thread Pedro J. Aphalo
Hello,

Package 'ggplot2' defines `ggplot()` as an S3 generic.

My package 'ggspectra' defines some specializations of ggplot() for 
additional classes, which work as expected together with all packages 
extending 'ggplot2' that I have tested, except for 'ggtern'.

Package 'ggtern' imports 'ggplot2' and then redefines the ggplot() 
generic with exactly the same code as in 'ggplot2' itself.

If one attempts to use my package and 'ggtern' in the same session, 
dispatch fails for the ggplot() specializations defined in my package, 
unless an explicit call to ggplot2::ggpplot() is used.

I do not understand why the generic needs to be redefined in 'ggtern', 
and although I have raised an issue for 'ggtern' last November, the just 
released version of 'ggtern' retains the redefinition of the generic.

So, I have some questions:

1) Can I do anything in my own package to ensure that method dispatch 
works correctly even after 'ggtern' is attached?

2) Is it good practice for a package to redefine a generic from an 
imported package?

3) Is it possible to redefine a generic, without disturbing the dispatch 
of specializations already known to R?

Thanks in advance for any insights,

Pedro.

-- 

Pedro J. Aphalo
University Lecturer, Principal Investigator
(Office 4417, Biocenter 3, Viikinkaari 1)

Department of Biosciences
Plant Biology
P.O. Box 65
00014 University of Helsinki
Finland

e-mail: pedro.aph...@helsinki.fi 
Tel. (mobile) +358 50 4150623
Tel. (office) +358 2941 57897


*Web sites and blogs*
Web site (research group): http://blogs.helsinki.fi/senpep-blog/
Web site (own teaching): http://www.helsinki.fi/people/pedro.aphalo/
Web site (using R in photobiology): http://www.r4photobiology.info/

*Societies*
UV4Plants  (communications officer), ESP 
 (member) SEB  
(member), BES  (member), SPPS 
 (member), SMS 
 (member), TUG 
 (member), FOAS  (member).


[[alternative HTML version deleted]]

__
R-package-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-package-devel