This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author gz
Recipients flox, gz, vinay.sajip
Date 2010-08-03.22:39:40
SpamBayes Score 2.1683766e-12
Marked as misclassified No
Message-id <1280875181.95.0.557870097374.issue9501@psf.upfronthosting.co.za>
In-reply-to
Content
With the logging change to using weakrefs for handler cleanup done by the follow-on patch in issue 6615 exceptions may now be thrown during module teardown.

There are two distinct problem cases:
1) The new `_removeHandlerRef` function may run during teardown (when module globals are being set to None) but uses the module globals `_acquireLock`, `_releaseLock`, and `_handlerList`.
2) The `Handler.close` method no longer removes the instance from the module global list, this means if the caller then closes the underlying file but keeps a reference to the handler, the `shutdown` function will attempt to flush the already-closed file.

It may be that this new way of doing things is preferred and the response to closing underlying files or holding on to handler references is Don't Do That Then, but this seems like an accidental regression.
History
Date User Action Args
2010-08-03 22:39:42gzsetrecipients: + gz, vinay.sajip, flox
2010-08-03 22:39:41gzsetmessageid: <1280875181.95.0.557870097374.issue9501@psf.upfronthosting.co.za>
2010-08-03 22:39:40gzlinkissue9501 messages
2010-08-03 22:39:40gzcreate