Repository navigation
gh-63293: Deprecate providing false values besides strings, bytes, or None to urllib.parse functions
#26687
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
Merged
Merged
gh-63293: Deprecate providing false values besides strings, bytes, or None to urllib.parse functions
#26687
Changes from all commits
Commits
Show all changes
14 commits
Select commit
Hold shift + click to select a range
c83d003
bpo-19094: Raise TypeError in urljoin(), urlparse(), and urlsplit() f…
jacobtylerwalls 3ec0a4b
fix missing elif
jacobtylerwalls 2bf57f3
fix condition
jacobtylerwalls bffbd32
Allow NoneType
jacobtylerwalls 01809a9
Relax assertion
jacobtylerwalls 6fc2901
fixups
jacobtylerwalls 4f2c686
fixups
jacobtylerwalls 9f028ea
Merge remote-tracking branch 'upstream' into urllib-typeerror
jacobtylerwalls 03d4f21
Bump docs
jacobtylerwalls a34c412
cosmetic
jacobtylerwalls f5bc232
Resolve BytesWarning
jacobtylerwalls ddc8adb
Merge branch 'main' into urllib-typeerror
orsenthil 78044de
fix lint error.
orsenthil 9f959ab
Moving the check for valid True values (and raise TypeError) and Warn on
orsenthil File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
6 changes: 6 additions & 0 deletions
6
Misc/NEWS.d/next/Library/2021-06-11-20-00-16.bpo-19094.rMRoIL.rst
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,6 @@ | ||
| The :mod:`urllib.parse` URL parsing functions now raise :exc:`TypeError` | ||
| instead of :exc:`AttributeError` when passed an object which is not a string, | ||
| bytes, or ``None``. Accepting objects with false values (like ``0`` and | ||
| ``[]``) except empty strings, byte-like objects and ``None`` is now | ||
| deprecated, extending the deprecation made in Python 3.14 for | ||
| :func:`~urllib.parse.parse_qsl` and :func:`~urllib.parse.parse_qs`. |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.