Re: [Rd] robustness of install.packages/update.packages (was Re: bug in L-BFGS-B? (PR#8099))

From: Berwin A Turlach <berwin_at_maths.uwa.edu.au>
Date: Mon 29 Aug 2005 - 10:55:04 GMT

G'day Brian,

>>>>> "BDR" == Prof Brian Ripley <ripley@stats.ox.ac.uk> writes:

    >>> However, update.packages() wanted to update quite a few
    >>> packages besides MASS (the other packages in the VR bundle,
    >>> nlme, lattice &c).  Once it failed on MASS, it terminated with
    >>> an error and did not update any of the other packages.  Would
    >>> it be possible to robustify update.packages behaviour such
    >>> that it would continue in such situations with updating the
    >>> remaining packages?
    >>  Not a good idea. Better to follow the FAQ.  At that point the
    >> dependencies have been worked out and will not be re-computed
    >> if a package installation fails.

    BDR> I checked, and I am unable to reproduce this. I get O.k., I tried to reproduce the behaviour. So I installed the binary distribution of R 2.1.1 in another directory on my laptop once more (and then deleted the copy that I actually wanted to keep; shouldn't do such things at this time of the day).

So below I attach what is, I believe a faithful reproduction of what I tried to do yesterday. Except that I did not run the file that installs all the contributed packages that I like to have installed.

But it seems that now VR_7.2-17.zip has vanished from mirror.aarnet.edu.au and you can see how on the first occassion the download stops with an error. I believe that in this case it could have continued to download the other files.

Once I changed the mirror, the other behaviour that I mentioned becomes apparent. But I take your point that because of package dependencies it might actually be not wise to continue with updating further packages once the update of a package has failed. But then, shouldn't in that case (by the same argument) all the updates that have been done already be undone again?

Cheers,

        Berwin

++++++++++++++++++ Transcript of R session ++++++++++++++++++++++++++++

R : Copyright 2005, The R Foundation for Statistical Computing Version 2.1.1 (2005-06-20), ISBN 3-900051-07-0

R is free software and comes with ABSOLUTELY NO WARRANTY. You are welcome to redistribute it under certain conditions. Type 'license()' or 'licence()' for distribution details.

  Natural language support but running in an English locale

R is a collaborative project with many contributors. Type 'contributors()' for more information and 'citation()' on how to cite R or R packages in publications.

Type 'demo()' for some demos, 'help()' for on-line help, or 'help.start()' for a HTML browser interface to help. Type 'q()' to quit R.

> library(MASS)
> update.packages()

boot :
 Version 1.2-22 installed in C:/PROGRA~1/R/rw2011/library  Version 1.2-23 available at http://mirror.aarnet.edu.au/pub/CRAN Update (y/N/c)? y
VR :
 Version 7.2-16 installed in C:/PROGRA~1/R/rw2011/library  Version 7.2-17 available at http://mirror.aarnet.edu.au/pub/CRAN Update (y/N/c)? y
cluster :
 Version 1.10.0 installed in C:/PROGRA~1/R/rw2011/library  Version 1.10.1 available at http://mirror.aarnet.edu.au/pub/CRAN Update (y/N/c)? y
foreign :
 Version 0.8-8 installed in C:/PROGRA~1/R/rw2011/library  Version 0.8-9 available at http://mirror.aarnet.edu.au/pub/CRAN Update (y/N/c)? y
lattice :
 Version 0.11-8 installed in C:/PROGRA~1/R/rw2011/library  Version 0.12-3 available at http://mirror.aarnet.edu.au/pub/CRAN Update (y/N/c)? y
mgcv :
 Version 1.3-1 installed in C:/PROGRA~1/R/rw2011/library  Version 1.3-4 available at http://mirror.aarnet.edu.au/pub/CRAN Update (y/N/c)? y
nlme :
 Version 3.1-60 installed in C:/PROGRA~1/R/rw2011/library  Version 3.1-62 available at http://mirror.aarnet.edu.au/pub/CRAN Update (y/N/c)? y
trying URL 'http://mirror.aarnet.edu.au/pub/CRAN/bin/windows/contrib/2.1/boot_1.2-23.zip' Content type 'application/zip' length 767814 bytes opened URL
downloaded 749Kb

trying URL 'http://mirror.aarnet.edu.au/pub/CRAN/bin/windows/contrib/2.1/VR_7.2-17.zip' Error in download.file(url, destfile, method, mode = "wb") :

        cannot open URL 'http://mirror.aarnet.edu.au/pub/CRAN/bin/windows/contrib/2.1/VR_7.2-17.zip' In addition: Warning message:
cannot open: HTTP status was '404 Not Found'
> options(repos=c(CRAN="http://cran.au.r-project.org/"))
> options()$repos

                           CRAN 

"http://cran.au.r-project.org/"
> update.packages()

boot :
 Version 1.2-22 installed in C:/PROGRA~1/R/rw2011/library  Version 1.2-23 available at http://cran.au.r-project.org Update (y/N/c)? y
VR :
 Version 7.2-16 installed in C:/PROGRA~1/R/rw2011/library  Version 7.2-19 available at http://cran.au.r-project.org Update (y/N/c)? y
cluster :
 Version 1.10.0 installed in C:/PROGRA~1/R/rw2011/library  Version 1.10.1 available at http://cran.au.r-project.org Update (y/N/c)? y
foreign :
 Version 0.8-8 installed in C:/PROGRA~1/R/rw2011/library  Version 0.8-10 available at http://cran.au.r-project.org Update (y/N/c)? y
lattice :
 Version 0.11-8 installed in C:/PROGRA~1/R/rw2011/library  Version 0.12-5 available at http://cran.au.r-project.org Update (y/N/c)? y
mgcv :
 Version 1.3-1 installed in C:/PROGRA~1/R/rw2011/library  Version 1.3-6 available at http://cran.au.r-project.org Update (y/N/c)? y
nlme :
 Version 3.1-60 installed in C:/PROGRA~1/R/rw2011/library  Version 3.1-64 available at http://cran.au.r-project.org Update (y/N/c)? y
trying URL 'http://cran.au.r-project.org/bin/windows/contrib/2.1/boot_1.2-23.zip' Content type 'application/zip' length 767814 bytes opened URL
downloaded 749Kb

trying URL 'http://cran.au.r-project.org/bin/windows/contrib/2.1/VR_7.2-19.zip' Content type 'application/zip' length 1575000 bytes opened URL
downloaded 1538Kb

trying URL 'http://cran.au.r-project.org/bin/windows/contrib/2.1/cluster_1.10.1.zip' Content type 'application/zip' length 480389 bytes opened URL
downloaded 469Kb

trying URL 'http://cran.au.r-project.org/bin/windows/contrib/2.1/foreign_0.8-10.zip' Content type 'application/zip' length 176663 bytes opened URL
downloaded 172Kb

trying URL 'http://cran.au.r-project.org/bin/windows/contrib/2.1/lattice_0.12-5.zip' Content type 'application/zip' length 713040 bytes opened URL
downloaded 696Kb

trying URL 'http://cran.au.r-project.org/bin/windows/contrib/2.1/mgcv_1.3-6.zip' Content type 'application/zip' length 795159 bytes opened URL
downloaded 776Kb

trying URL 'http://cran.au.r-project.org/bin/windows/contrib/2.1/nlme_3.1-64.zip' Content type 'application/zip' length 2142405 bytes opened URL
downloaded 2092Kb

package 'boot' successfully unpacked and MD5 sums checked bundle 'VR' successfully unpacked and MD5 sums checked Error: cannot remove prior installation of package 'MASS'
> search()

 [1] ".GlobalEnv"        "package:MASS"      "package:methods"  
 [4] "package:stats"     "package:graphics"  "package:grDevices"
 [7] "package:utils"     "package:datasets"  "Autoloads"        
[10] "package:base"     

> detach(2)
> update.packages()

VR :
 Version 7.2-16 installed in C:/PROGRA~1/R/rw2011/library  Version 7.2-19 available at http://cran.au.r-project.org Update (y/N/c)? y
cluster :
 Version 1.10.0 installed in C:/PROGRA~1/R/rw2011/library  Version 1.10.1 available at http://cran.au.r-project.org Update (y/N/c)? y
foreign :
 Version 0.8-8 installed in C:/PROGRA~1/R/rw2011/library  Version 0.8-10 available at http://cran.au.r-project.org Update (y/N/c)? y
lattice :
 Version 0.11-8 installed in C:/PROGRA~1/R/rw2011/library  Version 0.12-5 available at http://cran.au.r-project.org Update (y/N/c)? y
mgcv :
 Version 1.3-1 installed in C:/PROGRA~1/R/rw2011/library  Version 1.3-6 available at http://cran.au.r-project.org Update (y/N/c)? y
nlme :
 Version 3.1-60 installed in C:/PROGRA~1/R/rw2011/library  Version 3.1-64 available at http://cran.au.r-project.org Update (y/N/c)? y
trying URL 'http://cran.au.r-project.org/bin/windows/contrib/2.1/VR_7.2-19.zip' Content type 'application/zip' length 1575000 bytes opened URL
downloaded 1538Kb

trying URL 'http://cran.au.r-project.org/bin/windows/contrib/2.1/cluster_1.10.1.zip' Content type 'application/zip' length 480389 bytes opened URL
downloaded 469Kb

trying URL 'http://cran.au.r-project.org/bin/windows/contrib/2.1/foreign_0.8-10.zip' Content type 'application/zip' length 176663 bytes opened URL
downloaded 172Kb

trying URL 'http://cran.au.r-project.org/bin/windows/contrib/2.1/lattice_0.12-5.zip' Content type 'application/zip' length 713040 bytes opened URL
downloaded 696Kb

trying URL 'http://cran.au.r-project.org/bin/windows/contrib/2.1/mgcv_1.3-6.zip' Content type 'application/zip' length 795159 bytes opened URL
downloaded 776Kb

trying URL 'http://cran.au.r-project.org/bin/windows/contrib/2.1/nlme_3.1-64.zip' Content type 'application/zip' length 2142405 bytes opened URL
downloaded 2092Kb

bundle 'VR' successfully unpacked and MD5 sums checked Error: cannot remove prior installation of package 'MASS'
> search()

[1] ".GlobalEnv"        "package:methods"   "package:stats"    
[4] "package:graphics"  "package:grDevices" "package:utils"    
[7] "package:datasets"  "Autoloads"         "package:base"     
>

R-devel@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-devel Received on Mon Aug 29 20:59:28 2005

This archive was generated by hypermail 2.1.8 : Mon 24 Oct 2005 - 22:27:45 GMT