Skip to content

[R-pkg-devel] File name error

8 messages · Cathy Lee Gierke, Blume Christine, Dirk Eddelbuettel +2 more

#
I am getting the following error from the auto-checks when trying to submit
a package to CRAN:
r-devel-linux-x86_64-debian-gcc
<https://cran.r-project.org/web/checks/check_flavors.html#r-devel-linux-x86_64-debian-gcc>
3.0.0.2 3.63 56.71 60.34 ERROR
<https://www.r-project.org/nosvn/R.check/r-devel-linux-x86_64-debian-gcc/CATkit-00check.html>

Error in pdf(file = fileName4, width = 8, height = 10) :
  cannot open file
'/home/hornik/tmp/R.check/r-devel-gcc/Work/build/Packages/CATkit/extdata/activity-stress-c57-2-part.txt--20Dec2017--03-51-46CAToutput.pdf'

Since this works for ALL other flavors, I am assuming it may be some file
name restrictions unique to debian-gcc???  I can't think what else would
cause it to fail only in the OS.

debian doesn't like "--"?

Cathy Lee Gierke


*?Darkness cannot drive out darkness: only light can do that. Hate cannot
drive out hate: only love can do that.? *
*?The arc of the moral universe is long, but it bends towards justice.?*
*?Nothing in the world is more dangerous than sincere ignorance and
conscientious stupidity.? *
*?Never forget that everything Hitler did in Germany was legal.?   *
*?Forgiveness is not an occasional act, it is a constant attitude.? *
*?Injustice anywhere is a threat to justice everywhere.?  *

? Martin Luther King Jr.

<http://www.goodreads.com/author/show/23924.Martin_Luther_King_Jr_>
#
Hi Cathy,

I also had troubles with debian (Fedora only gave warnings) and no problems with other systems. Mine was related to me writing a file (or rather trying to write) in a working directory other than tempdir (can be retrieved by tempdir()). I now write it to tempdir and then set the old working directory again at the end of the example. Perhaps that is somehow helpful for your case too?

I can highly recommend to test your tar.gz file with the check() function of the rhub package. You can for example run check("pathtoyourpackage", platform = "debian-gcc-devel") or 
check_for_cran("pathtoyourpackage", platform = "debian-gcc-devel"), i.e. test your package on debian without troubles.

Best,
Christine


-----Urspr?ngliche Nachricht-----
Von: R-package-devel [mailto:r-package-devel-bounces at r-project.org] Im Auftrag von Cathy Lee Gierke
Gesendet: Donnerstag, 21. Dezember 2017 07:15
An: R Package Development
Betreff: [R-pkg-devel] File name error

I am getting the following error from the auto-checks when trying to submit a package to CRAN:
r-devel-linux-x86_64-debian-gcc
<https://cran.r-project.org/web/checks/check_flavors.html#r-devel-linux-x86_64-debian-gcc>
3.0.0.2 3.63 56.71 60.34 ERROR
<https://www.r-project.org/nosvn/R.check/r-devel-linux-x86_64-debian-gcc/CATkit-00check.html>

Error in pdf(file = fileName4, width = 8, height = 10) :
  cannot open file
'/home/hornik/tmp/R.check/r-devel-gcc/Work/build/Packages/CATkit/extdata/activity-stress-c57-2-part.txt--20Dec2017--03-51-46CAToutput.pdf'

Since this works for ALL other flavors, I am assuming it may be some file name restrictions unique to debian-gcc???  I can't think what else would cause it to fail only in the OS.

debian doesn't like "--"?

Cathy Lee Gierke


*?Darkness cannot drive out darkness: only light can do that. Hate cannot drive out hate: only love can do that.? * *?The arc of the moral universe is long, but it bends towards justice.?* *?Nothing in the world is more dangerous than sincere ignorance and conscientious stupidity.? *
*?Never forget that everything Hitler did in Germany was legal.?   *
*?Forgiveness is not an occasional act, it is a constant attitude.? * *?Injustice anywhere is a threat to justice everywhere.?  *

? Martin Luther King Jr.

<http://www.goodreads.com/author/show/23924.Martin_Luther_King_Jr_>


______________________________________________
R-package-devel at r-project.org mailing list https://stat.ethz.ch/mailman/listinfo/r-package-devel
#
This is a new check:

You must not write into the user's filespace without explicit agreement 
by the user (by specifying path/name).

Note that some users won't even have permissions to write into the 
package's installation directory if that is set up site wide by an 
admin, for example.

So please use tempdir() in the examples.

Best,
Uwe Ligges
On 21.12.2017 09:21, Blume Christine wrote:
#
Cristine,
On 21 December 2017 at 08:21, Blume Christine wrote:
| I also had troubles with debian (Fedora only gave warnings)

May I ask you to be a little more careful in your attribution?   Yes, it is
too that the instance labeleb 'r-devel-debian' gave you an error.  But that
was not because of Debian, but because _that r-devel instance_ carried a new
test.

So please don't leave sentences hanging (as you now have in several emails)
"failed on Debian" implying a particular flavour (as shipped by Debian)
failed.  It didn't. A [very recent] build of r-devel, instrumented with a new
test, failed for you. It happens to be running on a Debian platform. So
please refer to the failing test platform by its name. Preferably with the
compiler added because there are two each for Debian and Fedora. See eg
https://cloud.r-project.org/web/checks/check_results_digest.html

Thanks,  Dirk
#
Uwe/Kurt, is this controlled by R itself or by the host system?  I
suspect one of my R.filesets tests(*) fails (since a few days) because
of this, but it might actually be a false positive.  I fail to
reproduce it on Ubuntu 16.04 with:

* using R Under development (unstable) (2017-12-20 r73933)
* using platform: x86_64-pc-linux-gnu (64-bit)

My test tries to verify that it can write to tempdir() using its
*relative* path (if such is possible) - a test that effectively does:
[1] "/tmp/Rtmpa9riPQ"
[1] "../../tmp/Rtmpa9riPQ/file3251441e380d
and fails in that last write on 'r-devel-linux-x86_64-debian-gcc'.  It
could, of course, be a bug in my code that is now being revealed, but
these tests been in place for many years, possibly more than a decade.

(*) https://cran.r-project.org/web/checks/check_results_R.filesets.html

Thxs,

Henrik

On Thu, Dec 21, 2017 at 2:21 AM, Uwe Ligges
<ligges at statistik.tu-dortmund.de> wrote:
6 days later
#
My program puts the output into the folder where it found the input.

Must I move the input files to tmpdir() or are they already there?

Cathy Lee Gierke


*?Darkness cannot drive out darkness: only light can do that. Hate cannot
drive out hate: only love can do that.? *
*?The arc of the moral universe is long, but it bends towards justice.?*
*?Nothing in the world is more dangerous than sincere ignorance and
conscientious stupidity.? *
*?Never forget that everything Hitler did in Germany was legal.?   *
*?Forgiveness is not an occasional act, it is a constant attitude.? *
*?Injustice anywhere is a threat to justice everywhere.?  *

? Martin Luther King Jr.

<http://www.goodreads.com/author/show/23924.Martin_Luther_King_Jr_>

On Thu, Dec 21, 2017 at 4:21 AM, Uwe Ligges <ligges at statistik.tu-dortmund.de

  
  
1 day later
#
On 27.12.2017 18:55, Cathy Lee Gierke wrote:
Please let the user specify the output dir. Otherwise there is the risk 
to overwrite files that the user want to keep.
Why shoudl files be in tmpdir()? Only those you created there...

Best,
Uwe Ligges
#
On 21.12.2017 18:22, Henrik Bengtsson wrote:
You mean the new check? This is R.
file = rel, I guess.
Well, as this is also shown in R-release on Kurt's machines, I suspect 
this is either a problem where the directory you are working in is a 
link and the deriving the relative path fails or there is no space left 
in  tempdir() ...

In both cases, please ask Kurt who is on vacation, too.

Best,
Uwe