Re: [R-pkg-devel] How to resolve help files with \Sexpr{} warning?

2025-04-14 Thread adinno



Dear Iris and Ivan, 


Together both your comments were very helpful, and both pointed me at a 
solution to resolve my issue and to explain why this change in behavior 
emerged, and how my package was triggering the behavior.

Solution that worked:

 Editing the DESCRIPTION file to add the line BuildManual: TRUE

Solution that did *not* work (along with variations):
 
 R CMD build --manual  ←Resulted in: Warning: unknown option ‘--manual’
 R CMD --manual build
 R --manual CMD build
 R CMD check --manual

Note: I am using R version 4.4.3 (2025-02-28) -- "Trophy Case" on Ubuntu 
24.04


Thank you both very much for this help!

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


Re: [R-pkg-devel] How to resolve help files with \Sexpr{} warning?

2025-04-14 Thread Ivan Krylov via R-package-devel
В Sun, 13 Apr 2025 21:54:03 -0700 (PDT)
adi...@pdx.edu пишет:

> Package has help file(s) containing install/render-stage \Sexpr{} 
> expressions but no prebuilt PDF manual.

This is a relatively recent change (r85348, October 2023). Previously,
R CMD build detected non-build-time dynamic content in the package
documentation and built the manual automatically. Nowadays I think you
have to set BuildManual: yes in your DESCRIPTION before building the
package. (There's R CMD build --no-manual, but I'm not seeing a command
line option to override it from "no" to "yes".)

> (Aside: I am using mathjaxr... not sure if that is the issue.)

Correct, that must be what's producing the render-stage dynamic content:

https://github.com/wviechtb/mathjaxr/blob/8900cbbb2eda4dc45b776cc203c2942b6289fac3/man/macros/mathjax.Rd#L4

-- 
Best regards,
Ivan

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


Re: [R-pkg-devel] How to resolve help files with \Sexpr{} warning?

2025-04-14 Thread Iris Simmons
I believe R CMD build changed the default from --manual to --no-manual, I'm
not sure why. You could add --manual when you build the tarball or you
could add

BuildManual: TRUE

to your DESCRIPTION.

On Mon, Apr 14, 2025, 09:41  wrote:

>
>
> Dear R Devs,
>
>
> I am unsure how to resolve this NOTE in my package build (I am
> comfortable with the possibly misspelled words part):
>
>  Package has help file(s) containing install/render-stage \Sexpr{}
>  expressions but no prebuilt PDF manual.
>
>
> I've dozens of files and no idea which one(s) offend, or if I am missing
> some other detail. (Aside: I am using mathjaxr... not sure if that is
> the issue.)
>
>
> Links for winbuilder logs are here for the time being:
>
>  https://win-builder.r-project.org/qG7LHs2Yf18p
>  https://win-builder.r-project.org/BBXdLV7kDOuI
>  https://win-builder.r-project.org/63RmX21pnrAw ←This check passes
>
>
> Thank you very much,
>
> Alexis Dinno
>
>
> PS Am including the log from the R-release winbuilder check in case my
> links expire:
>
>
> * using log directory
> 'd:/RCompile/CRANguest/R-oldrelease/tost.suite.Rcheck'
> * using R version 4.4.3 (2025-02-28 ucrt)
> * using platform: x86_64-w64-mingw32
> * R was compiled by
> gcc.exe (GCC) 13.3.0
> GNU Fortran (GCC) 13.3.0
> * running under: Windows Server 2022 x64 (build 20348)
> * using session charset: UTF-8
> * checking for file 'tost.suite/DESCRIPTION' ... OK
> * this is package 'tost.suite' version '3.15'
> * package encoding: UTF-8
> * checking CRAN incoming feasibility ... [8s] NOTE
> Maintainer: 'Alexis Dinno '
>
> New submission
>
> Possibly misspelled words in DESCRIPTION:
>   Kolmogorov (9:402)
>   McNemar's (9:198)
>   OLS (9:289)
>   Smirnov (9:413)
>   Stata (9:47)
>   Wilcoxon (9:312, 9:340)
>   nonparametric (9:546)
>   rrp (9:842)
>   rrpi (9:855)
>   tost (9:18, 9:65, 9:837, 9:850)
>
> Package has help file(s) containing install/render-stage \Sexpr{}
> expressions but no prebuilt PDF manual.
> * 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 hidden files and directories ... OK
> * checking for portable file names ... OK
> * checking whether package 'tost.suite' can be installed ... OK
> * checking installed package size ... OK
> * checking package directory ... OK
> * checking for future file timestamps ... 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 ... [1s] OK
> * checking whether the package can be loaded with stated dependencies
> ... [1s] OK
> * checking whether the package can be unloaded cleanly ... [1s] OK
> * checking whether the namespace can be loaded with stated dependencies
> ... [1s] OK
> * checking whether the namespace can be unloaded cleanly ... [1s] OK
> * checking loading without being on the library search path ... [1s] OK
> * checking use of S3 registration ... 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 ... [16s] OK
> * checking Rd files ... [1s] OK
> * checking Rd metadata ... OK
> * checking Rd line widths ... 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 contents of 'data' directory ... OK
> * checking data for non-ASCII characters ... [0s] OK
> * checking data for ASCII and uncompressed saves ... OK
> * checking examples ... [7s] OK
> * checking PDF version of manual ... [12s] OK
> * checking HTML version of manual ... [5s] OK
> * checking for detritus in the temp directory ... OK
> * DONE
> Status: 1 NOTE
> __
> 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


Re: [R-pkg-devel] broken or outdaeted URLs

2025-04-14 Thread Emanuele Cordano
No,  R CMD check --as-cran on my machine did not help.

  `urlchecker::url_check()`  was very useful. It found most of broken URLs
and they were fixed.

Thank you for your feedback.

Best
Emanuele Cordano

Il giorno gio 10 apr 2025 alle ore 12:52 Ivan Krylov 
ha scritto:

> В Thu, 10 Apr 2025 11:24:31 +0200
> Emanuele Cordano  пишет:
>
> > Is there an option in R CMD check that I can use on
> > my server to directly verify all URLs
>
> Does R CMD check --as-cran help?
>
> --
> Best regards,
> Ivan
>


-- 
Emanuele Cordano, PhD
Environmental Engineer / Ingegnere per l' Ambiente e il territorio nr.
3587 (Albo A - Provincia di Trento)
cell: +39 3282818564
email: emanuele.cord...@gmail.com,emanuele.cord...@rendena100.eu,
emanuele.cord...@eurac.edu
PEC: emanuele.cord...@ingpec.eu
URL: www.rendena100.eu
LinkedIn: https://www.linkedin.com/in/emanuele-cordano-31995333
GitHub: https://github.com/ecor

[[alternative HTML version deleted]]

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


[R-pkg-devel] How to resolve help files with \Sexpr{} warning?

2025-04-14 Thread adinno



Dear R Devs,


I am unsure how to resolve this NOTE in my package build (I am 
comfortable with the possibly misspelled words part):

 Package has help file(s) containing install/render-stage \Sexpr{} 
 expressions but no prebuilt PDF manual.


I've dozens of files and no idea which one(s) offend, or if I am missing 
some other detail. (Aside: I am using mathjaxr... not sure if that is 
the issue.)


Links for winbuilder logs are here for the time being:

 https://win-builder.r-project.org/qG7LHs2Yf18p
 https://win-builder.r-project.org/BBXdLV7kDOuI
 https://win-builder.r-project.org/63RmX21pnrAw ←This check passes


Thank you very much,

Alexis Dinno


PS Am including the log from the R-release winbuilder check in case my 
links expire:


* using log directory 
'd:/RCompile/CRANguest/R-oldrelease/tost.suite.Rcheck'
* using R version 4.4.3 (2025-02-28 ucrt)
* using platform: x86_64-w64-mingw32
* R was compiled by
gcc.exe (GCC) 13.3.0
GNU Fortran (GCC) 13.3.0
* running under: Windows Server 2022 x64 (build 20348)
* using session charset: UTF-8
* checking for file 'tost.suite/DESCRIPTION' ... OK
* this is package 'tost.suite' version '3.15'
* package encoding: UTF-8
* checking CRAN incoming feasibility ... [8s] NOTE
Maintainer: 'Alexis Dinno '

New submission

Possibly misspelled words in DESCRIPTION:
  Kolmogorov (9:402)
  McNemar's (9:198)
  OLS (9:289)
  Smirnov (9:413)
  Stata (9:47)
  Wilcoxon (9:312, 9:340)
  nonparametric (9:546)
  rrp (9:842)
  rrpi (9:855)
  tost (9:18, 9:65, 9:837, 9:850)

Package has help file(s) containing install/render-stage \Sexpr{} 
expressions but no prebuilt PDF manual.
* 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 hidden files and directories ... OK
* checking for portable file names ... OK
* checking whether package 'tost.suite' can be installed ... OK
* checking installed package size ... OK
* checking package directory ... OK
* checking for future file timestamps ... 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 ... [1s] OK
* checking whether the package can be loaded with stated dependencies 
... [1s] OK
* checking whether the package can be unloaded cleanly ... [1s] OK
* checking whether the namespace can be loaded with stated dependencies 
... [1s] OK
* checking whether the namespace can be unloaded cleanly ... [1s] OK
* checking loading without being on the library search path ... [1s] OK
* checking use of S3 registration ... 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 ... [16s] OK
* checking Rd files ... [1s] OK
* checking Rd metadata ... OK
* checking Rd line widths ... 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 contents of 'data' directory ... OK
* checking data for non-ASCII characters ... [0s] OK
* checking data for ASCII and uncompressed saves ... OK
* checking examples ... [7s] OK
* checking PDF version of manual ... [12s] OK
* checking HTML version of manual ... [5s] OK
* checking for detritus in the temp directory ... OK
* DONE
Status: 1 NOTE
__
R-package-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-package-devel


Re: [R-pkg-devel] broken or outdaeted URLs

2025-04-14 Thread Ivan Krylov via R-package-devel
В Mon, 14 Apr 2025 08:57:49 +0200
Emanuele Cordano  пишет:

> R CMD check --as-cran on my machine did not help.

Strange, it should be doing the same thing as 'urlchecker'. I've tried
it with an old version of 'RMAWGEN' and saw the messages:

>> * checking CRAN incoming feasibility ... [6s/526s] WARNING
>> <...>
>> Found the following (possibly) invalid URLs:

Some of the URL checks in R CMD check do not work if 'xml2' is not
installed, but 'urlchecker' depends on it as well. Still, glad that
'urlchecker' helped you locate and fix the problematic URLs.

-- 
Best regards,
Ivan

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


Re: [R-pkg-devel] cran check about examples time

2025-04-14 Thread Ivan Krylov via R-package-devel
В Mon, 14 Apr 2025 08:53:38 +0200
Emanuele Cordano  пишет:

> CRAN check were OK (frorr Windows) whereas in Debian a function
> example elapses   5.326 seconds.  I need to fix this. Most lines in
> the examples are within \donttest{} brackets, so they should not be
> executed by CRAN checks.

Nowadays, R CMD check --as-cran does run \donttest{} examples. (But not
without --as-cran or --run-donttest, and no automatic checks enable
--run-dontrun.)

>   Examples with CPU (user + system) or elapsed time > 5s
>   user system elapsed
>   get.geotop.inpts.keyword.value 1.406  0.027   5.326

It looks like most of the time was spent waiting to establish a new
connection (closer to 8 seconds on my computer). What does
system.time(example(get.geotop.inpts.keyword.value)) return for you? Is
it an option to download less files in the example?

Having examples that download data from the internet is somewhat
precarious for a CRAN package. One way to prevent intermittent
connectivity problems from failing your package checks is to make sure
that any time your package fails to download something from the Web, it
calls stop() with a classed error object (e.g. simpleError(...) with an
additional class "geotop_internet_error" attached). This makes it
possible to wrap your examples in tryCatch(..., geotop_internet_error =
function(e) { ... }), so that any connection errors do not cause your
examples to fail, but other errors are not swallowed.

-- 
Best regards,
Ivan

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