[S] bug question: Error: element XX of "Session_DB" has no name

Mark Bravington FSMG CEFAS (M.V.BRAVINGTON@cefas.co.uk)
Tue, 17 Nov 1998 15:08:00 +0000

Dear s-news,

I wonder if anyone can shed light on the following error message:

Error: element XX of "Session_DB" has no name

where XX is a number (typically 13-15 in Splus 4.0 for Windows).

I have been getting the above error occasionally for years, under S-PLUS 3.3 and 4.0 for Windows (and quite possibly earlier PC versions too, or even when I used UNIX; I can't remember). It is printed out just before S-PLUS returns to the command prompt, but after all the computations have been carried out successfully. Occurrence is completely unpredictable, but I seem to _notice_ the error more often when (like today) it crops up after a long calculation has finished. The effect of the error is that the results of the calculation are lost. Schematically, things work like this:

> results_ long.calculation()
doing 100000000000 sums; please make a cup of tea...
All done successfully!
Error: element 14 of "Session_DB" has no name
> results
Error: object "results" not found
> # damn damn damn

Normally I just grin and bear it, but I have lost a couple of long bootstraps recently. Thank goodness I haven't tried any MCMC calculations.

I have described this problem to MathSoft, who asked if I could send the code that caused the problem. I can't do so, because the problem is not repeatable (issuing the above command a second time would very likely work) and the problem isn't linked to any one bit of code. I haven't heard any more yet. So the purposes of this email are (1) to air the problem on the list, in the hope of spurring some action; and (2) to see if anyone knows of a short-term fix. It has occurred to me that something like

> assign( 'results', long.calculation(), immediate=T)

may avoid losing the results if the error happens. Obviously I don't want to type this for every calculation I do, but I wouldn't mind doing it occasionally for a long calculation if I thought it would work.

Some clues:
(1) In the course of my Splus sessions, I use a homemade debugger to set up copies of functions in frame 0 (which I presume is "Session_DB"). These copies are invariably deleted before I try long calculations. However, I do have occasional problems when the frame 0 copies come back from the dead without being invited, as functions that return NULL. Having said that, these zombie functions cause different error messages to the "...has no name", and also there is no evidence of zombie involvement in my most recent "...has no name" crash. But there are obviously some problems with frame 0.
(2) My code (e.g. "long.calculation") doesn't explicitly create, delete, or modify variables in frame 0.
(3) After the last crash, there were 16 objects in frame 0, all with OK names, and the number reported in the error was 15.

Any ideas?

Mark Bravington
m.v.bravington@cefas.co.uk <mailto:m.v.bravington@cefas.co.uk>

This message was distributed by s-news@wubios.wustl.edu. To unsubscribe
send e-mail to s-news-request@wubios.wustl.edu with the BODY of the
message: unsubscribe s-news