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

fix CRAN note for userspace files in tests #364

Open
maxheld83 opened this issue Feb 13, 2020 · 2 comments
Open

fix CRAN note for userspace files in tests #364

maxheld83 opened this issue Feb 13, 2020 · 2 comments
Assignees

Comments

@maxheld83
Copy link
Collaborator

maxheld83 commented Feb 13, 2020

Just to keep a record of this here, the issue is:

  * checking for non-standard things in the check directory ... NOTE
 Found the following files/directories:
     �QCards.tex� �mystudy.dat� �mystudy.sta�

CRAN has confirmed:

Please do not write files in the user filespace in examples or tests, rather use tempdir().

The same problem appears to be documented here.

@maxheld83
Copy link
Collaborator Author

maxheld83 commented Feb 13, 2020

I cannot reproduce the NOTE with devtools::check(document = FALSE, args = c('--as-cran')), but it makes sense that some example code produced these files, so I should be able to get rid of them.

maxheld83 added a commit that referenced this issue Feb 13, 2020
the `make.cards()` default out put `QCards.tex` would leave files in user space by default after running the example code, which is now against CRAN policies.
`make.cards(file.name)` now (somewhat counterintuitively) accepts paths as inputs, so the examples can use `tempfile()`.
The argument name is now a bit misleading though just providing a name, as previously, still works with the same effects, so should be fine.
Changing the argument name to path or something would have broken the package for some people perhaps.
So I think it's better to live with the inconsistency.
@maxheld83
Copy link
Collaborator Author

this should be fixed right on master on my side for the offending detritus from make.cards() and its examples now.

mystudy.* seem to stem from export.pqmethod(), which @aiorazabala wrote.
I couldn't find an easy way to add a tempfile() here, because that'd be a really weird study.name, and I'm not sure what else happens with study.name, that this could break.

So I'll leave that to you @aiorazabala.

@aiorazabala aiorazabala self-assigned this Feb 23, 2021
@aiorazabala aiorazabala added this to the 1.6.0 (Centroid) milestone Feb 23, 2021
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