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

Use pandoc conditionally #290

Closed
cboettig opened this issue Dec 3, 2019 · 4 comments
Closed

Use pandoc conditionally #290

cboettig opened this issue Dec 3, 2019 · 4 comments

Comments

@cboettig
Copy link
Member

cboettig commented Dec 3, 2019

As per email from CRAN:

As 'Writing R Extensions' says

' A package with a hard-to-satisfy system requirement is by definition
not portable, annoyingly so if this is not declared in the
‘SystemRequirements’ field. The most common example is the use of
pandoc, which is only available for a very limited range of platforms
(and has onerous requirements to install from source) and has
capabilities that vary by build but are not documented.

Usage of external commands should always be conditional on a test for
existence (perhaps using Sys.which), as well as declared in the
‘SystemRequirements’ field.'

Do ensure that your package is compliant before Dec 17 to safely retain
it on CRAN.

@cboettig
Copy link
Member Author

cboettig commented Dec 3, 2019

I'll just note that I don't really understand the issue. We only use pandoc through a dependency on rmarkdown (which we already use conditionally). pandoc is a listed dependency of rmarkdown, and is listed in the systemRequirements of the rmarkdown package.

I would not think that a package would need to list the systemRequirements of its dependencies, any more than it needs list the dependencies of it's dependencies. rmarkdown is a CRAN package and appears not to be included on the list of packages receiving this email.

Anyway, I think we can easily add a condition that checks rmarkdown::pandoc_available() here)...

@amoeba
Copy link
Collaborator

amoeba commented Dec 3, 2019

Odd. The language isn't really clear, do they mean EML depends on pandoc or are they merely giving it as an example? Is it possible that xml2 is another example because it requires libxml-dev? jq is another one. Really, EML depends on librdf0-dev, libv8-dev, libjq-dev, and libudunits2-dev which (maybe?) they're saying reduces portability.

@cboettig
Copy link
Member Author

cboettig commented Dec 4, 2019

Operationally, I believe they are referring to https://cran.r-project.org/web/checks/check_results_EML.html, where CRAN has several platforms they test on which lack pandoc (Solaris, though apparently all of the CRAN MacOS test servers also lack pandoc).

Note the rmarkdown package itself uses skip_on_cran() ....

cboettig added a commit that referenced this issue Dec 9, 2019
@cboettig
Copy link
Member Author

cboettig commented Dec 9, 2019

hopefully fixed in 9bb6e0c.

Submitted patch to CRAN as v2.0.1 (bumped the NEWS file as well with the recent PRs since 2.0.0 release). 🤞🤞

@cboettig cboettig closed this as completed Dec 9, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants