-
-
Notifications
You must be signed in to change notification settings - Fork 33.9k
bpo-32642: adding compatibility for pathlike objects in sys.path #5691
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
|
I'm having issues with my local changes for this PR, I'm unsure why my local machine takes a seemingly infinite amount of time on test_poplib, so again I think something to do with my local environment is causing issues again, any help would be appreciated... |
|
the trace for the test_poplib |
|
@jayyyin Please resolve the file conflict. |
brettcannon
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the PR but this needs tests.
| # the list of paths that will become its __path__ | ||
| namespace_path = [] | ||
| for entry in path: | ||
| if hasattr(entry, '__fspath__'): |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is unnecessary as os.fspath() passes strings through without issue.
| @@ -0,0 +1 @@ | |||
| adding compatibility for pathlike objects in sys.path | |||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| adding compatibility for pathlike objects in sys.path | |
| Add compatibility for path-like objects on sys.path. | |
| Patch by jayyin. |
|
A Python core developer has requested some changes be made to your pull request before we can consider merging it. If you could please address their requests along with any other requests in other reviews from core developers that would be appreciated. Once you have made the requested changes, please leave a comment on this pull request containing the phrase |
|
The original author of the pull request hasn't been active on this issue for a long time, so I'm going to close it. This can be reopened or a new pull request can be created for work to continue on the issue. Thanks! |
I'm uncertain if that's all that needs to be done for the code to do what is intended since I'm kind of new to the whole path-like object concept, I've noticed that there's still self.path in the class and recall reading something about removing path attributes from classes, but I've been unable to find documentation on how to add compatibility to something for path-like objects.
https://bugs.python.org/issue32642