CRAN check failure after adding lifecycle
jpritikin opened this issue Β· 21 comments
CRAN check of OpenMx started failing with,
Package has help file(s) containing install/render-stage \Sexpr{} expressions but no prebuilt PDF manual.
This problem disappeared after I revert the addition of lifecycle.
Any idea about the root cause? I'd like to use lifecycle, but I can't.
Removing --no-manual
from your CMD check flags should fix it.
You can also ignore the NOTE in your CI system, CRAN will build the manual to check it in any case.
Eh, but this resulted in a rejected CRAN submission,
Thanks, we see:
Package has help file(s) containing install/render-stage \Sexpr{}
expressions but no prebuilt PDF manual.
Please fix and resubmit.
Best,
Uwe Ligges
I haven't encountered this case yet, not sure what's going on.
Maybe you have to build without --no-manual
before sending for release? I'm generally using devtools::release()
which might do it automatically.
I've never used --no-manual
when I build a tarball. I just do R CMD build .
Maybe @gaborcsardi knows more about this sort of issues with Sexpr.
At a minimum, the error message could be made more specific and understandable.
@jpritikin where is your tarball?
Sry, I mean, a full check on a CI or by CRAN.
Sry, I mean, a full check on a CI or by CRAN.
Can you explain more fully? The version with lifecycle never got onto CRAN (see rejection above). What do you mean by "CI"? If you mean continuous integration then I never did a R CMD check --as-cran
on Travis with this version. However, I did this on my local machine and obtained the same vague complaint,
Package has help file(s) containing install/render-stage \Sexpr{}
expressions but no prebuilt PDF manual.
There are no further details about the context. I can run it again and post a tarball of the full check results, if that would help. Let me know what you need.
Thanks.
Failed CRAN submissions should be here: https://win-builder.r-project.org/incoming_pretest/ and there is a bunch for OpenMx, although I don't know which one failed for lifecycle.
The current OpenMx repo also does not use lifecycle AFAICT. Is there a branch or ref that does?
Yeah, so the problem is that you .Rbuildignore
the build
directory. R CMD build
puts the PDF manual there, but then the whole directory is ignored so it'll not be in the built package.
Whoa! OpenMx uses the build directory as a temporary place to stash random build artifacts. I didn't realize that it would clash with R's package workflow. How about if I use a directory called staging
instead of build
? Will that solve it?
I guess so.
I'll try it. Thanks for your help!
Thanks @gaborcsardi I would never have figured this out!
@jpritikin I'm having a similar issue. Hoping you or another expert on the thread might be able to provide some additional insight since there isn't much addressing the issue on StackOverflow or elsewhere. Thanks so much for your time and ideas!
My CRAN submission passed somehow π€·ββοΈ even though all of my GitHub Action (GHA) workflows show that same message since adding the lifecycle badges to my package
Package has help file(s) containing install/render-stage \Sexpr{} expressions but no prebuilt PDF manual.
Attempted fixes
I've tried the following to no avail:
- Remove
--no-manual
fromrcmdcheck(args = c(...))
in my GHA workflows - Add
- uses: r-lib/actions/setup-tinytex@v1
so TinyTex in available to create the PDF manual - Add a folder titled
build/
in the top-level of the package directory and put a locally generated manual PDF with titled"thispackagename.pdf"
- Use the documentation style that {dplyr} is using currently on Github instead of the lifecycle Rd macro
\Sexpr[results=rd, stage=render]{lifecycle::badge("superseded")}
but the check still prints out the same message very early on in the process. I'm not sure how to silence the message or really what I could do to ensure that future CRAN submissions pass.
Start of GitHub Action Log that runs R CMD check
Run rcmdcheck::rcmdcheck(args = c("--as-cran"), error_on = "warning", check_dir = "check")
ββ R CMD build βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
* checking for file β.../DESCRIPTIONβ ... OK
* preparing βsalesforcerβ:
* checking DESCRIPTION meta-information ... OK
* installing the package to process help pages
* creating vignettes ... OK
* checking for LF line-endings in source and make files and shell scripts
* checking for empty or unneeded directories
* building βsalesforcer_0.2.0.tar.gzβ
ββ R CMD check βββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββββ
* using log directory β/Users/runner/work/salesforcer/salesforcer/check/salesforcer.Rcheckβ
* using R version 4.0.2 (2020-06-22)
* using platform: x86_64-apple-darwin17.0 (64-bit)
* using session charset: UTF-8
* using option β--as-cranβ
* checking for file βsalesforcer/DESCRIPTIONβ ... OK
* this is package βsalesforcerβ version β0.2.0.9000β
* package encoding: UTF-8
* checking CRAN incoming feasibility ... NOTE
Maintainer: βSteven M. Mortimer <***>β
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
... (log continues)
Try using inline markdown to create the badges:
#' `r lifecycle::badge("deprecated")`
This requires a recent roxygen. This is now the recommended way to insert a badge, though the documentation hasn't followed up yet.
@lionel- Thanks for the quick reply! That works!
It also fixes the error messages from {spelling} as noted in #19 and ropensci/spelling#42
Thanks again!