多分それは些細なことで、同じコードを探しすぎていたのかもしれません... getFLOSSmoleDataXML.R
RStudio経由でRモジュールを調達すると、コードはディレクトリ内の.Rdataファイルを正しく検出し、cache
ダウンロードと解析のフェーズをスキップします。一方、同じモジュールが GNU make
( sudo -u ruser make
) 経由で R によって処理される場合、結果は、まあ、奇妙なものになります。
Rscript --no-save --no-restore --verbose getFLOSSmoleDataXML.R
running
'/usr/lib/R/bin/R --slave --no-restore --no-save --no-restore --file=getFLOSSmoleDataXML.R'
Loading required package: RCurl
Loading required package: methods
Loading required package: bitops
Loading required package: XML
Loading required package: digest
Verifying repository: FreeCode
Checking file "http://flossdata.syr.edu/data/fc/2013/2013-Dec/fcProjectAuthors2013-Dec.txt.bz2"...
rdataFile = "./cache/5802dbd08ebefadf70fbb826776f9f0f.Rdata"...
trying URL 'http://flossdata.syr.edu/data/fc/2013/2013-Dec/fcProjectAuthors2013-Dec.txt.bz2'
Content type 'application/x-bzip2' length 514960 bytes (502 Kb)
opened URL
==================================================
downloaded 502 Kb
Error in gzfile(file, "wb") : cannot open the connection
Calls: print ... FUN -> importRepoFiles -> lapply -> FUN -> save -> gzfile
In addition: Warning message:
In gzfile(file, "wb") :
cannot open compressed file './cache/5802dbd08ebefadf70fbb826776f9f0f.Rdata', probable reason 'No such file or directory'
Timing stopped at: 0.74 0.068 1.134
Execution halted
make[1]: *** [importFLOSSmole] Error 1
make[1]: Leaving directory `/home/ruser/diss-floss/import'
make: *** [collection] Error 2
ubuntu@ip-10-164-108-61:/home/ruser/diss-floss$ ls -l cache/5802*
-rw-r--r-- 1 ruser ruser 1968939 Feb 19 05:47 cache/5802dbd08ebefadf70fbb826776f9f0f.Rdata
最後の 2 行からわかるように、ファイルが実際に存在することを確認しました。ここで何が起こっているのですか?アイデアやアドバイスはありますか?ありがとうございました!