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.

Title: Importlib.metadata docs claim PackagePath is a Path subclass
Type: behavior Stage: resolved
Components: Documentation Versions: Python 3.10
Status: closed Resolution: fixed
Dependencies: Superseder:
Assigned To: docs@python Nosy List: docs@python, jaraco, miss-islington, paul.moore
Priority: normal Keywords: patch

Created on 2021-04-27 19:25 by paul.moore, last changed 2022-04-11 14:59 by admin. This issue is now closed.

Pull Requests
URL Status Linked Edit
PR 25669 merged paul.moore, 2021-04-27 19:26
PR 27221 merged miss-islington, 2021-07-18 02:30
Messages (3)
msg392123 - (view) Author: Paul Moore (paul.moore) * (Python committer) Date: 2021-04-27 19:25
The importlib.metadata documentation states that the PackagePath class is "a pathlib.Path derived object". This isn't true - it's a PurePath subclass, and in particular it does not have a resolve() method. In fact, it has an undocumented custom locate() method that converts it into a Path object.

I propose changing the documentation to make it clear that it is a PurePath subclass, and explicitly documenting the locate() method.
msg392269 - (view) Author: Jason R. Coombs (jaraco) * (Python committer) Date: 2021-04-29 00:09
Thanks Paul!
msg397737 - (view) Author: miss-islington (miss-islington) Date: 2021-07-18 02:53
New changeset 049e98b2b74cdcd462f31720c24ab6ebff599d9f by Miss Islington (bot) in branch '3.9':
[3.9] bpo-43958: Document importlib.metadata.PackagePath.locate method (GH-25669) (GH-27221)
Date User Action Args
2022-04-11 14:59:44adminsetgithub: 88124
2021-07-18 02:53:22miss-islingtonsetmessages: + msg397737
2021-07-18 02:30:10miss-islingtonsetnosy: + miss-islington

pull_requests: + pull_request25762
2021-04-29 00:09:28jaracosetstatus: open -> closed

nosy: + jaraco
messages: + msg392269

resolution: fixed
stage: patch review -> resolved
2021-04-27 19:26:19paul.mooresetkeywords: + patch
stage: patch review
pull_requests: + pull_request24358
2021-04-27 19:25:40paul.moorecreate