René's URL Explorer Experiment


Title: bpo-42060: Remove `assert` from http/client.py by fbidu · Pull Request #22737 · python/cpython · GitHub

Open Graph Title: bpo-42060: Remove `assert` from http/client.py by fbidu · Pull Request #22737 · python/cpython

X Title: bpo-42060: Remove `assert` from http/client.py by fbidu · Pull Request #22737 · python/cpython

Description: The Python programming language. Contribute to python/cpython development by creating an account on GitHub.

Open Graph Description: This PR removes assert statement from the stdlib's HTTP client.py and switches by an if...raise approach that won't be removed if optimization is requested https://bugs.python.org/issue42060

X Description: This PR removes assert statement from the stdlib's HTTP client.py and switches by an if...raise approach that won't be removed if optimization is requested https://bugs.python.org/issue42060

Opengraph URL: https://github.com/python/cpython/pull/22737

X: @github

direct link

Domain: github.com

route-pattern/_view_fragments/voltron/pull_requests/show/:user_id/:repository/:id/pull_request_layout(.:format)
route-controllervoltron_pull_requests_fragments
route-actionpull_request_layout
fetch-noncev2:683398eb-d8a5-8af1-d363-2898428897d4
current-catalog-service-hashae870bc5e265a340912cde392f23dad3671a0a881730ffdadd82f2f57d81641b
request-id9012:28D644:1ADFADA:23B265A:6A52C872
html-safe-nonce9a644adda9a21f6819188da561415d4929949c62cbabda727bb8f40bbcc83f0e
visitor-payloadeyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiI5MDEyOjI4RDY0NDoxQURGQURBOjIzQjI2NUE6NkE1MkM4NzIiLCJ2aXNpdG9yX2lkIjoiNzgxMTU5MDE5OTY4NjQ1MjM0IiwicmVnaW9uX2VkZ2UiOiJpYWQiLCJyZWdpb25fcmVuZGVyIjoiaWFkIn0=
visitor-hmac0e700860c8bf19b070a1464f7d90c88b4327d4d4c3f2b455fad5dd076ecead2d
hovercard-subject-tagpull_request:505277774
github-keyboard-shortcutsrepository,pull-request-list,pull-request-conversation,pull-request-files-changed,copilot
google-site-verificationApib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I
octolytics-urlhttps://collector.github.com/github/collect
analytics-location///voltron/pull_requests_fragments/pull_request_layout
fb:app_id1401488693436528
apple-itunes-appapp-id=1477376905, app-argument=https://github.com/_view_fragments/voltron/pull_requests/show/python/cpython/22737/pull_request_layout
twitter:imagehttps://opengraph.githubassets.com/192f7466155eec7db24aae672c994732b393d3ec3b801828bc6af1a1e9b52932/python/cpython/pull/22737
twitter:cardsummary_large_image
og:imagehttps://opengraph.githubassets.com/192f7466155eec7db24aae672c994732b393d3ec3b801828bc6af1a1e9b52932/python/cpython/pull/22737
og:image:altThis PR removes assert statement from the stdlib's HTTP client.py and switches by an if...raise approach that won't be removed if optimization is requested https://bugs.python.org/issue42060
og:image:width1200
og:image:height600
og:site_nameGitHub
og:typeobject
og:author:usernamefbidu
hostnamegithub.com
expected-hostnamegithub.com
Noneb9a586c06a05a7a86fc7e3f4dbd03e42f6869085879aa184aa6369456dbd50fb
turbo-cache-controlno-cache
go-importgithub.com/python/cpython git https://github.com/python/cpython.git
octolytics-dimension-user_id1525981
octolytics-dimension-user_loginpython
octolytics-dimension-repository_id81598961
octolytics-dimension-repository_nwopython/cpython
octolytics-dimension-repository_publictrue
octolytics-dimension-repository_is_forkfalse
octolytics-dimension-repository_network_root_id81598961
octolytics-dimension-repository_network_root_nwopython/cpython
turbo-body-classeslogged-out env-production page-responsive
disable-turbofalse
browser-stats-urlhttps://api.github.com/_private/browser/stats
browser-errors-urlhttps://api.github.com/_private/browser/errors
release07a982c1d40157c619b364352b704c3ce66bb332
ui-targetfull
theme-color#1e2327
color-schemelight dark

Links:

Skip to contenthttps://github.com/python/cpython/pull/22737#start-of-content
https://github.com/
Sign in https://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fpython%2Fcpython%2Fpull%2F22737
GitHub CopilotWrite better code with AIhttps://github.com/features/copilot
GitHub Copilot appDirect agents from issue to mergehttps://github.com/features/ai/github-app
MCP RegistryNewIntegrate external toolshttps://github.com/mcp
ActionsAutomate any workflowhttps://github.com/features/actions
CodespacesInstant dev environmentshttps://github.com/features/codespaces
IssuesPlan and track workhttps://github.com/features/issues
Code ReviewManage code changeshttps://github.com/features/code-review
GitHub Advanced SecurityFind and fix vulnerabilitieshttps://github.com/security/advanced-security
Code securitySecure your code as you buildhttps://github.com/security/advanced-security/code-security
Secret protectionStop leaks before they starthttps://github.com/security/advanced-security/secret-protection
Why GitHubhttps://github.com/why-github
Documentationhttps://docs.github.com
Bloghttps://github.blog
Changeloghttps://github.blog/changelog
Marketplacehttps://github.com/marketplace
View all featureshttps://github.com/features
Enterpriseshttps://github.com/enterprise
Small and medium teamshttps://github.com/team
Startupshttps://github.com/enterprise/startups
Nonprofitshttps://github.com/solutions/industry/nonprofits
App Modernizationhttps://github.com/solutions/use-case/app-modernization
DevSecOpshttps://github.com/solutions/use-case/devsecops
DevOpshttps://github.com/solutions/use-case/devops
CI/CDhttps://github.com/solutions/use-case/ci-cd
View all use caseshttps://github.com/solutions/use-case
Healthcarehttps://github.com/solutions/industry/healthcare
Financial serviceshttps://github.com/solutions/industry/financial-services
Manufacturinghttps://github.com/solutions/industry/manufacturing
Governmenthttps://github.com/solutions/industry/government
View all industrieshttps://github.com/solutions/industry
View all solutionshttps://github.com/solutions
AIhttps://github.com/resources/articles?topic=ai
Software Developmenthttps://github.com/resources/articles?topic=software-development
DevOpshttps://github.com/resources/articles?topic=devops
Securityhttps://github.com/resources/articles?topic=security
View all topicshttps://github.com/resources/articles
Customer storieshttps://github.com/customer-stories
Events & webinarshttps://github.com/resources/events
Ebooks & reportshttps://github.com/resources/whitepapers
Business insightshttps://github.com/solutions/executive-insights
GitHub Skillshttps://skills.github.com
Documentationhttps://docs.github.com
Customer supporthttps://support.github.com
Community forumhttps://github.com/orgs/community/discussions
Trust centerhttps://github.com/trust-center
Partnershttps://github.com/partners
View all resourceshttps://github.com/resources
GitHub SponsorsFund open source developershttps://github.com/open-source/sponsors
Security Labhttps://securitylab.github.com
Maintainer Communityhttps://maintainers.github.com
Acceleratorhttps://github.com/open-source/accelerator
GitHub Starshttps://stars.github.com
Archive Programhttps://archiveprogram.github.com
Topicshttps://github.com/topics
Trendinghttps://github.com/trending
Collectionshttps://github.com/collections
Enterprise platformAI-powered developer platformhttps://github.com/enterprise
GitHub Advanced SecurityEnterprise-grade security featureshttps://github.com/security/advanced-security
Copilot for BusinessEnterprise-grade AI featureshttps://github.com/features/copilot/copilot-business
Premium SupportEnterprise-grade 24/7 supporthttps://github.com/enterprise/premium-support
Pricinghttps://github.com/pricing
Search syntax tipshttps://docs.github.com/search-github/github-code-search/understanding-github-code-search-syntax
documentationhttps://docs.github.com/search-github/github-code-search/understanding-github-code-search-syntax
Sign in https://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fpython%2Fcpython%2Fpull%2F22737
Sign up https://github.com/signup?ref_cta=Sign+up&ref_loc=header+logged+out&ref_page=%2F%3Cuser-name%3E%2F%3Crepo-name%3E%2Fvoltron%2Fpull_requests_fragments%2Fpull_request_layout&source=header-repo&source_repo=python%2Fcpython
Reloadhttps://github.com/python/cpython/pull/22737
Reloadhttps://github.com/python/cpython/pull/22737
Reloadhttps://github.com/python/cpython/pull/22737
Please reload this pagehttps://github.com/python/cpython/pull/22737
python https://github.com/python
cpythonhttps://github.com/python/cpython
Please reload this pagehttps://github.com/python/cpython/pull/22737
Notifications https://github.com/login?return_to=%2Fpython%2Fcpython
Fork 35k https://github.com/login?return_to=%2Fpython%2Fcpython
Star 73.8k https://github.com/login?return_to=%2Fpython%2Fcpython
Code https://github.com/python/cpython
Issues 5k+ https://github.com/python/cpython/issues
Pull requests 2.3k https://github.com/python/cpython/pulls
Actions https://github.com/python/cpython/actions
Projects https://github.com/python/cpython/projects
Security and quality 0 https://github.com/python/cpython/security
Insights https://github.com/python/cpython/pulse
Code https://github.com/python/cpython
Issues https://github.com/python/cpython/issues
Pull requests https://github.com/python/cpython/pulls
Actions https://github.com/python/cpython/actions
Projects https://github.com/python/cpython/projects
Security and quality https://github.com/python/cpython/security
Insights https://github.com/python/cpython/pulse
fbiduhttps://github.com/fbidu
python:mainhttps://github.com/python/cpython/tree/main
fbidu:http-asserthttps://github.com/fbidu/cpython/tree/http-assert
Conversationhttps://github.com/python/cpython/pull/22737
Commits4 (4)https://github.com/python/cpython/pull/22737/commits
Checkshttps://github.com/python/cpython/pull/22737/checks
Files changedhttps://github.com/python/cpython/pull/22737/files
bpo-42060: Remove assert from http/client.pyhttps://github.com/python/cpython/pull/22737#top
fbiduhttps://github.com/fbidu
python:mainhttps://github.com/python/cpython/tree/main
fbidu:http-asserthttps://github.com/fbidu/cpython/tree/http-assert
https://github.com/fbidu
fbiduhttps://github.com/fbidu
Oct 17, 2020https://github.com/python/cpython/pull/22737#issue-723752595
Please reload this pagehttps://github.com/python/cpython/pull/22737
https://bugs.python.org/issue42060https://bugs.python.org/issue42060
Please reload this pagehttps://github.com/python/cpython/pull/22737
https://github.com/fbidu
Switch assert statements to if...raisehttps://github.com/python/cpython/pull/22737/commits/6e2f084150bce7e187387b242c0dc0cc7e7c5853
6e2f084https://github.com/python/cpython/pull/22737/commits/6e2f084150bce7e187387b242c0dc0cc7e7c5853
https://github.com/the-knights-who-say-ni
the-knights-who-say-nihttps://github.com/the-knights-who-say-ni
CLA signed https://github.com/python/cpython/issues?q=state%3Aopen%20label%3A%22CLA%20signed%22
Oct 17, 2020https://github.com/python/cpython/pull/22737#event-3889203942
https://github.com/bedevere-bot
bedevere-bothttps://github.com/bedevere-bot
awaiting review https://github.com/python/cpython/issues?q=state%3Aopen%20label%3A%22awaiting%20review%22
Oct 17, 2020https://github.com/python/cpython/pull/22737#event-3889203992
https://github.com/Fidget-Spinner
Fidget-Spinnerhttps://github.com/Fidget-Spinner
Oct 17, 2020 https://github.com/python/cpython/pull/22737#pullrequestreview-510985561
View reviewed changes https://github.com/python/cpython/pull/22737/files/6e2f084150bce7e187387b242c0dc0cc7e7c5853
Lib/http/client.pyhttps://github.com/python/cpython/pull/22737/files/6e2f084150bce7e187387b242c0dc0cc7e7c5853#diff-3cf29d90eb758d0fe5ec013bbfda9b0bb60be4f7d899583bd5f490a7a5a5dc5f
Fidget-Spinnerhttps://github.com/Fidget-Spinner
Oct 17, 2020https://github.com/python/cpython/pull/22737#discussion_r506942887
Please reload this pagehttps://github.com/python/cpython/pull/22737
Learn morehttps://docs.github.com/articles/managing-disruptive-comments/#hiding-a-comment
Please reload this pagehttps://github.com/python/cpython/pull/22737
fbiduhttps://github.com/fbidu
Oct 17, 2020https://github.com/python/cpython/pull/22737#discussion_r506945645
Learn morehttps://docs.github.com/articles/managing-disruptive-comments/#hiding-a-comment
Please reload this pagehttps://github.com/python/cpython/pull/22737
https://github.com/fbidu
Fix wrong exception checking & raisinghttps://github.com/python/cpython/pull/22737/commits/c228be3c985784d049e443e8d98f66fde7ac0f5f
c228be3https://github.com/python/cpython/pull/22737/commits/c228be3c985784d049e443e8d98f66fde7ac0f5f
https://github.com/Fidget-Spinner
Fidget-Spinnerhttps://github.com/Fidget-Spinner
Oct 17, 2020https://github.com/python/cpython/pull/22737#issuecomment-711016406
https://devguide.python.org/pullrequest/#patchcheckhttps://devguide.python.org/pullrequest/#patchcheck
https://devguide.python.org/committing/#what-s-new-and-news-entrieshttps://devguide.python.org/committing/#what-s-new-and-news-entries
Please reload this pagehttps://github.com/python/cpython/pull/22737
fbiduhttps://github.com/fbidu
October 17, 2020 11:42https://github.com/python/cpython/pull/22737#commits-pushed-a9bab0b
https://github.com/fbidu
Fix whitespacing issueshttps://github.com/python/cpython/pull/22737/commits/a9bab0bad3f9a8b83465b02203250fae4fb351e3
a9bab0bhttps://github.com/python/cpython/pull/22737/commits/a9bab0bad3f9a8b83465b02203250fae4fb351e3
https://github.com/apps/blurb-it
📜🤖 Added by blurb_it.https://github.com/python/cpython/pull/22737/commits/111f8ca3a3cde30df2bf7166b2c8fd2c32a1fdde
111f8cahttps://github.com/python/cpython/pull/22737/commits/111f8ca3a3cde30df2bf7166b2c8fd2c32a1fdde
https://github.com/fbidu
fbiduhttps://github.com/fbidu
Oct 17, 2020https://github.com/python/cpython/pull/22737#issuecomment-711023443
@Fidget-Spinnerhttps://github.com/Fidget-Spinner
Please reload this pagehttps://github.com/python/cpython/pull/22737
https://github.com/Fidget-Spinner
Fidget-Spinnerhttps://github.com/Fidget-Spinner
Oct 17, 2020https://github.com/python/cpython/pull/22737#issuecomment-711028885
Please reload this pagehttps://github.com/python/cpython/pull/22737
@fbiduhttps://github.com/fbidu
https://bugs.python.org/issue23819https://bugs.python.org/issue23819
https://devguide.python.org/runtests/https://devguide.python.org/runtests/
Please reload this pagehttps://github.com/python/cpython/pull/22737
https://github.com/Fidget-Spinner
Fidget-Spinnerhttps://github.com/Fidget-Spinner
Oct 17, 2020 https://github.com/python/cpython/pull/22737#pullrequestreview-510993929
View reviewed changes https://github.com/python/cpython/pull/22737/files/111f8ca3a3cde30df2bf7166b2c8fd2c32a1fdde
Misc/NEWS.d/next/Library/2020-10-17-14-46-16.bpo-42060.du-IYq.rsthttps://github.com/python/cpython/pull/22737/files/111f8ca3a3cde30df2bf7166b2c8fd2c32a1fdde#diff-4533a92a586614b13876c19186839e08c2982686fba2108d8007c5c6cbd5c9f3
Fidget-Spinnerhttps://github.com/Fidget-Spinner
Oct 17, 2020https://github.com/python/cpython/pull/22737#discussion_r506954594
Please reload this pagehttps://github.com/python/cpython/pull/22737
Learn morehttps://docs.github.com/articles/managing-disruptive-comments/#hiding-a-comment
Please reload this pagehttps://github.com/python/cpython/pull/22737
https://github.com/terryjreedy
terryjreedyhttps://github.com/terryjreedy
pitrouhttps://github.com/pitrou
serhiy-storchakahttps://github.com/serhiy-storchaka
vadmiumhttps://github.com/vadmium
October 23, 2020 19:05https://github.com/python/cpython/pull/22737#event-3915324072
https://github.com/terryjreedy
terryjreedyhttps://github.com/terryjreedy
Oct 23, 2020https://github.com/python/cpython/pull/22737#issuecomment-715530279
Please reload this pagehttps://github.com/python/cpython/pull/22737
@pitrouhttps://github.com/pitrou
@serhiy-storchakahttps://github.com/serhiy-storchaka
@vadmiumhttps://github.com/vadmium
bpo-13464https://bugs.python.org/issue13464
bpo-21032https://bugs.python.org/issue21032
Please reload this pagehttps://github.com/python/cpython/pull/22737
https://github.com/serhiy-storchaka
serhiy-storchakahttps://github.com/serhiy-storchaka
Oct 24, 2020 https://github.com/python/cpython/pull/22737#pullrequestreview-516264538
View reviewed changes https://github.com/python/cpython/pull/22737/files/111f8ca3a3cde30df2bf7166b2c8fd2c32a1fdde
serhiy-storchakahttps://github.com/serhiy-storchaka
https://github.com/python/cpython/pull/22737#pullrequestreview-516264538
Learn morehttps://docs.github.com/articles/managing-disruptive-comments/#hiding-a-comment
Please reload this pagehttps://github.com/python/cpython/pull/22737
https://github.com/bedevere-bot
bedevere-bothttps://github.com/bedevere-bot
awaiting changes https://github.com/python/cpython/issues?q=state%3Aopen%20label%3A%22awaiting%20changes%22
awaiting review https://github.com/python/cpython/issues?q=state%3Aopen%20label%3A%22awaiting%20review%22
Oct 24, 2020https://github.com/python/cpython/pull/22737#event-3916574146
https://github.com/bedevere-bot
bedevere-bothttps://github.com/bedevere-bot
Oct 24, 2020https://github.com/python/cpython/pull/22737#issuecomment-715888668
Please reload this pagehttps://github.com/python/cpython/pull/22737
https://github.com/apps/github-actions
github-actionshttps://github.com/apps/github-actions
Dec 16, 2020https://github.com/python/cpython/pull/22737#issuecomment-745681494
Please reload this pagehttps://github.com/python/cpython/pull/22737
https://github.com/apps/github-actions
github-actionshttps://github.com/apps/github-actions
stale https://github.com/python/cpython/issues?q=state%3Aopen%20label%3Astale
Dec 16, 2020https://github.com/python/cpython/pull/22737#event-4117259470
https://github.com/iritkatriel
iritkatrielhttps://github.com/iritkatriel
Jun 26, 2022https://github.com/python/cpython/pull/22737#issuecomment-1166385521
Please reload this pagehttps://github.com/python/cpython/pull/22737
https://github.com/iritkatriel
iritkatrielhttps://github.com/iritkatriel
Jun 26, 2022https://github.com/python/cpython/pull/22737#event-6879599473
https://github.com/python/cpython/pull/22737
fbiduhttps://github.com/python/cpython/pull/22737
Apr 10, 2022 https://github.com/python/cpython/pull/22737#ref-issue-1199045348
Usage of assert in http/client.py #86226 https://github.com/python/cpython/issues/86226
https://github.co/hiddenchars
https://github.com/python/cpython/pull/{{ revealButtonHref }}
Sign up for freehttps://github.com/join?source=comment-repo
Sign in to commenthttps://github.com/login?return_to=https%3A%2F%2Fgithub.com%2Fpython%2Fcpython%2Fpull%2F22737
https://github.com/Fidget-Spinner
Fidget-Spinner https://github.com/Fidget-Spinner
https://github.com/python/cpython/pull/22737/files/111f8ca3a3cde30df2bf7166b2c8fd2c32a1fdde
https://github.com/serhiy-storchaka
serhiy-storchaka https://github.com/serhiy-storchaka
https://github.com/python/cpython/pull/22737/files/111f8ca3a3cde30df2bf7166b2c8fd2c32a1fdde
https://github.com/vadmium
vadmium https://github.com/vadmium
https://github.com/pitrou
pitrou https://github.com/pitrou
awaiting changes https://github.com/python/cpython/issues?q=state%3Aopen%20label%3A%22awaiting%20changes%22
stale https://github.com/python/cpython/issues?q=state%3Aopen%20label%3Astale
Please reload this pagehttps://github.com/python/cpython/pull/22737
https://github.com/fbidu
https://github.com/Fidget-Spinner
https://github.com/terryjreedy
https://github.com/bedevere-bot
https://github.com/iritkatriel
https://github.com/serhiy-storchaka
https://github.com/the-knights-who-say-ni
https://github.com
Termshttps://docs.github.com/site-policy/github-terms/github-terms-of-service
Privacyhttps://docs.github.com/site-policy/privacy-policies/github-privacy-statement
Securityhttps://github.com/security
Statushttps://www.githubstatus.com/
Communityhttps://github.community/
Docshttps://docs.github.com/
Contacthttps://support.github.com?tags=dotcom-footer

Viewport: width=device-width


URLs of crawlers that visited me.