[New-bugs-announce] [issue21736] Add __file__ attribute to frozen modules

Marc-Andre Lemburg report at bugs.python.org
Thu Jun 12 18:14:49 CEST 2014


New submission from Marc-Andre Lemburg:

The missing __file__ attribute on frozen modules causes lots of issues with the stdlib (see e.g. Issue21709 and the stdlib test suite) and other tools that expect this attribute to always be present.

The attached patch for 3.4.1 adds this attribute to all frozen modules and resolves most issues. It cannot resolve the problem of not necessarily finding the directories/files listed in those attributes, but at least makes it possible to continue using code that only uses the attribute for error reporting.

----------
components: Interpreter Core, Library (Lib)
messages: 220362
nosy: lemburg
priority: normal
severity: normal
status: open
title: Add __file__ attribute to frozen modules
versions: Python 3.4, Python 3.5

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue21736>
_______________________________________


More information about the New-bugs-announce mailing list