Navigation Menu

Skip to content
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

bpo-44412: add os.path.fileuri() function. #26708

Closed
wants to merge 1 commit into from

Conversation

barneygale
Copy link
Contributor

@barneygale barneygale commented Jun 13, 2021

One of only three pieces of functionality that's available in the
object-oriented pathlib library, but not the traditional os/os.path
modules.

By moving this functionality to low-level modules, we make progress towards
being able to remove pathlib._Flavour in bpo-44136 and ultimately unlock
pathlib's OOPy potential in bpo-24132.

This commit also adjusts urllib.request.pathname2url() to use the new
implementation on Windows. On other platforms, the existing implementation
is retained due to its simplicity and its highly questionable support for
relative file URIs (like 'file:photos/foo.txt')

https://bugs.python.org/issue44412

One of only three pieces of functionality that's available in the
object-oriented pathlib library, but not the traditional os/os.path
modules.

By moving this functionality to low-level modules, we make progress towards
being able to remove `pathlib._Flavour` in bpo-44136 and ultimately unlock
pathlib's OOPy potential in bpo-24132.

This commit also adjusts `urllib.request.pathname2url()` to use the new
implementation on Windows. On other platforms, the existing implementation
is retained due to its simplicity and its highly questionable support for
relative file URIs (like `'file:photos/foo.txt'`)
@github-actions
Copy link

This PR is stale because it has been open for 30 days with no activity.

@github-actions github-actions bot added the stale Stale PR or inactive for long period of time. label Jul 14, 2021
@barneygale barneygale closed this Jan 1, 2022
@barneygale barneygale mannequin mentioned this pull request Jun 21, 2022
@projetmbc projetmbc mannequin mentioned this pull request Jun 21, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
awaiting review stale Stale PR or inactive for long period of time.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants