On 06/11/10 09:28 PM, Ben Goodrich wrote:
On Jun 11, 3:56 pm, Ben Goodrich<goodrich....@gmail.com>  wrote:
I know nothing about Solaris or what might be causing this problem,
but if you put these two lines into a script called TestPackages.R

packages<- rownames(installed.packages())
for(i in seq_along(packages)) stopifnot(require(packages[i],
character.only = TRUE))

and then put something like

R --vanilla<  TestPackages.R>  TestOutput.txt

at the end of the shell script that installs R, it will fail if any
installed R package fails to load properly and something informative
will be written to TestOutput.txt .

Ben

Upon reading the ticket more closely, it seems that maybe the problem
is that some packages are not even installed correctly, in which case
the above would be insufficient because it only tests correctly
installed packages. So, if you know that the Recommended R packages
(and perhaps some others) are supposed to be installed with Sage, then
you could hardcode those in the TestPackages.R script.

packages<- c("Matrix", "grid") # add more packages as necessary
for(i in seq_along(packages)) stopifnot(require(packages[i],
character.only = TRUE)

Ben


Given actually reading in these 6 libraries takes very little time, it would not seem unreasonable to me to make a test that they actually import properly part of the normal doctests that people run each time people test Sage. Any reoccurring problem is far more likely to be found there, than by setting SAGE_CHECK=yes, where its simply not practical to run that on the SPARC hardware we have available. Building on 't2' already takes over 24 hours, though that should be reduced dramatically soon.

If reading such a library took a long time, I could see a more reasoned argument for not doing so. But even on my 10 year old workstation, it does not take long to load an R library.

Dave

--
To post to this group, send an email to sage-devel@googlegroups.com
To unsubscribe from this group, send an email to 
sage-devel+unsubscr...@googlegroups.com
For more options, visit this group at http://groups.google.com/group/sage-devel
URL: http://www.sagemath.org

Reply via email to