Under R2.10.0 beta (2009-10-14 r50082) my .First does not run reliably. I reported this last week, but not reproducibly, and it seemed to go away, so I thought it might be installation-related. But it has now recurred reproducibly, at least on my machine. The website ftp://ftp.csiro.au/MarkBravington contains two .RData files each containing (only) a .First. One of them does what it should, and one of them doesn't. Confusingly, the OK one will actually trigger an error message for you, because it tries to do things that are specific to my machines. The not-OK one says "skipping .First", as below, and you'll see why it shouldn't be doing that. Obvioulsy, the files need renaming before you can test them. I haven't been able to condense the .First to something more succinct that shows the same fault; saving a modified .First frequently makes the problem go away, seemingly regardless of what the change is. The transcript from the not-OK version is given below Mark -- Mark Bravington CSIRO Mathematical & Information Sciences Marine Laboratory Castray Esplanade Hobart 7001 TAS ph (+61) 3 6232 5118 fax (+61) 3 6232 5012 mob (+61) 438 315 623 R version 2.10.0 beta (2009-10-14 r50082) Copyright (C) 2009 The R Foundation for Statistical Computing 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. 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 an HTML browser interface to help. Type 'q()' to quit R. [Previously saved workspace restored] NOFIRST "" Skipping .First> head( .First) # what was it trying to do?1 function (skip.First = Sys.getenv("NOFIRST") != "") 2 { 3 print(Sys.getenv("NOFIRST")) 4 if (skip.First) { 5 cat("Skipping .First\\n") 6 return(invisible(NULL))>--please do not edit the information below-- Version: platform = i386-pc-mingw32 arch = i386 os = mingw32 system = i386, mingw32 status = beta major = 2 minor = 10.0 year = 2009 month = 10 day = 14 svn rev = 50082 language = R version.string = R version 2.10.0 beta (2009-10-14 r50082) Windows XP Professional x64 (build 3790) Service Pack 2 Locale: LC_COLLATE=English_Australia.1252;LC_CTYPE=English_Australia.1252;LC_MONETARY=English_Australia.1252;LC_NUMERIC=C;LC_TIME=English_Australia.1252 Search Path: .GlobalEnv, package:stats, package:graphics, package:grDevices, package:utils, package:datasets, package:methods, Autoloads, package:base
On 18/10/2009 6:20 PM, Mark.Bravington at csiro.au wrote:> Under R2.10.0 beta (2009-10-14 r50082) my .First does not run reliably. I reported this last week, but not reproducibly, and it seemed to go away, so I thought it might be installation-related. But it has now recurred reproducibly, at least on my machine. > > The website ftp://ftp.csiro.au/MarkBravington contains two .RData files each containing (only) a .First. One of them does what it should, and one of them doesn't. Confusingly, the OK one will actually trigger an error message for you, because it tries to do things that are specific to my machines. The not-OK one says "skipping .First", as below, and you'll see why it shouldn't be doing that. Obvioulsy, the files need renaming before you can test them. > > I haven't been able to condense the .First to something more succinct that shows the same fault; saving a modified .First frequently makes the problem go away, seemingly regardless of what the change is. > > The transcript from the not-OK version is given belowI can reproduce the problem running the .First in the notOK.RData file. (I don't need to rename it; just loading that file and explicitly running .First() will do it.) However, if I dump the function and source it, the problem goes away. So I suspect there is something wrong in the notOK.RData file. How did you create it? Duncan Murdoch
On 10/18/2009 6:20 PM, Mark.Bravington at csiro.au wrote:> Under R2.10.0 beta (2009-10-14 r50082) my .First does not run reliably. I reported this last week, but not reproducibly, and it seemed to go away, so I thought it might be installation-related. But it has now recurred reproducibly, at least on my machine. > > The website ftp://ftp.csiro.au/MarkBravington contains two .RData files each containing (only) a .First. One of them does what it should, and one of them doesn't. Confusingly, the OK one will actually trigger an error message for you, because it tries to do things that are specific to my machines. The not-OK one says "skipping .First", as below, and you'll see why it shouldn't be doing that. Obvioulsy, the files need renaming before you can test them. > > I haven't been able to condense the .First to something more succinct that shows the same fault; saving a modified .First frequently makes the problem go away, seemingly regardless of what the change is. > > The transcript from the not-OK version is given belowLuke Tierney tracked this down and fixed it. It's actually a fairly old bug, but was being masked by another; when he fixed the other one in September, this one started to manifest itself. It should be okay in RC builds newer than r50178 (which should show up by tomorrow on most platforms). Thanks for making this reproducible! Duncan Murdoch