: Kristján Valur Jónsson
Cc: Amaury Forgeot d'Arc; Python-Dev
Subject: Re: [Python-Dev] try/except in io.py
Generally speaking, close() and __delete__() methods that can be invoked
during interpreter shutdown should avoid referencing module globals at
all. Necessary globals (including members of
Kristján Valur Jónsson wrote:
> Ah, but that is not what the intent is to guard agains, according the
> comments. During exit, modules have been deleted and all sorts of
> things have gone away. It is therefore likely that code that executes
> during exit will encounter NameErrors (when a module is
> > try:
> > self.close()
> > except:
> > try:
> >if not sys.exiting(): raise
> > except:
> >pass
> >
> >
> > Or better yet, do as we have done often here, just catch the particular
> >
Hello,
Kristján Valur Jónsson wrote:
> Greetings!
>
> Yesterday, I committed revision r67843 to py3k.
>
> Re-enablign the windows CRT runtime checks showed me that close() was beeing
> called with an invalid file descriptor.
>
> Now, the problem was was in tokenizer.c, but the reason this wasn't ca
Greetings!
Yesterday, I committed revision r67843 to py3k.
Re-enablign the windows CRT runtime checks showed me that close() was beeing
called with an invalid file descriptor.
Now, the problem was was in tokenizer.c, but the reason this wasn't caught
earlier was,
1) Incorrect error checkin