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.
Created on 2014年06月14日 19:58 by eric.snow, last changed 2022年04月11日 14:58 by admin.
| Pull Requests | |||
|---|---|---|---|
| URL | Status | Linked | Edit |
| PR 19097 | merged | furkanonder, 2020年03月21日 01:17 | |
| Messages (5) | |||
|---|---|---|---|
| msg220576 - (view) | Author: Eric Snow (eric.snow) * (Python committer) | Date: 2014年06月14日 19:58 | |
In the documentation for the inspect module, the module type is described with just 2 of its potential 7 attributes. The language reference[2] and importlib docs[3] both provide an accurate list of module attributes. Furthermore, the description for __file__ should be fixed. It should be clear that __file__ reflects the location from which the module was loaded, that location is not necessarily a filename, and the attribute may not exist if the module was not loaded from a specific location (e.g. builtin and frozen modules). The same goes for __cached__ [1] https://docs.python.org/dev/library/inspect.html#types-and-members [2] https://docs.python.org/3/reference/import.html#import-related-module-attributes [3] https://docs.python.org/3/library/importlib.html#importlib.machinery.ModuleSpec |
|||
| msg364831 - (view) | Author: Furkan Onder (furkanonder) * | Date: 2020年03月22日 23:29 | |
I sent a PR to fix a __file__ description. https://github.com/python/cpython/pull/19097 |
|||
| msg366210 - (view) | Author: Furkan Onder (furkanonder) * | Date: 2020年04月11日 13:31 | |
PR has been sent. |
|||
| msg395472 - (view) | Author: miss-islington (miss-islington) | Date: 2021年06月09日 21:10 | |
New changeset 878d7e4ee464913438fd59582bbb795e7e0fa387 by Furkan Onder in branch 'main': bpo-21760: fix __file__ description (GH-19097) https://github.com/python/cpython/commit/878d7e4ee464913438fd59582bbb795e7e0fa387 |
|||
| msg395475 - (view) | Author: Eric Snow (eric.snow) * (Python committer) | Date: 2021年06月09日 21:15 | |
I've merged the changes for __file__. Thanks, furkanonder! The fixes in the types module remain to be done, though now I see 4 of the relevant attributes instead of 2. (missing: __path__, __file__, __cached__) |
|||
| History | |||
|---|---|---|---|
| Date | User | Action | Args |
| 2022年04月11日 14:58:04 | admin | set | github: 65959 |
| 2021年06月21日 15:17:15 | iritkatriel | set | keywords:
+ easy, - patch versions: + Python 3.9, Python 3.10, Python 3.11, - Python 3.4, Python 3.5 |
| 2021年06月09日 21:15:49 | eric.snow | set | messages: + msg395475 |
| 2021年06月09日 21:10:36 | miss-islington | set | nosy:
+ miss-islington messages: + msg395472 |
| 2020年04月11日 13:31:40 | furkanonder | set | messages: + msg366210 |
| 2020年03月22日 23:29:08 | furkanonder | set | messages: + msg364831 |
| 2020年03月21日 01:17:40 | furkanonder | set | keywords:
+ patch nosy: + furkanonder pull_requests: + pull_request18457 stage: needs patch -> patch review |
| 2020年03月18日 18:05:30 | brett.cannon | set | nosy:
- brett.cannon |
| 2014年06月14日 20:16:28 | eric.snow | set | nosy:
+ brett.cannon, ncoghlan |
| 2014年06月14日 19:58:13 | eric.snow | create | |