Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

gh-69152: add method get_proxy_response_headers to HTTPConnection class#104248

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
gpshead merged 20 commits intopython:mainfromnametkin:new
May 16, 2023

Conversation

nametkin
Copy link
Contributor

@nametkinnametkin commentedMay 6, 2023
edited by bedevere-bot
Loading

@nametkinnametkinforce-pushed thenew branch 2 times, most recently fromd493391 to383ad4dCompareMay 8, 2023 11:54
@nametkin
Copy link
ContributorAuthor

@gpshead, please look at this PR. Did I understand your idea correctly?

Copy link
Member

@gpsheadgpshead left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others.Learn more.

yep, this is what I had in mind. Thanks for the followup PR.

@bedevere-bot
Copy link

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 phraseI have made the requested changes; please review again. I will then notify any core developers who have left a review that you're ready for them to take another look at this pull request.

@nametkin
Copy link
ContributorAuthor

@gpshead, thank you for review.
I have made the requested changes; please review again

@bedevere-bot
Copy link

Thanks for making the requested changes!

@gpshead: please review the changes made to this pull request.

@arhadthedev
Copy link
Member

The PR will be merged after the feature freezing 3.12b1 is published next week. Currently core devs implement remaining PEPs and fix bugs introduced by them.

nametkin reacted with thumbs up emoji

@gpsheadgpsheadenabled auto-merge (squash)May 16, 2023 05:57
@gpsheadgpshead merged commit85ec192 intopython:mainMay 16, 2023
@nametkinnametkin deleted the new branchMay 16, 2023 07:19
carljm added a commit to carljm/cpython that referenced this pull requestMay 16, 2023
* main:pythonGH-104510: Fix refleaks in `_io` base types (python#104516)pythongh-104539: Fix indentation error in logging.config.rst (python#104545)pythongh-104050: Don't star-import 'types' in Argument Clinic (python#104543)pythongh-104050: Add basic typing to CConverter in clinic.py (python#104538)pythongh-64595: Fix write file logic in Argument Clinic (python#104507)pythongh-104523: Inline minimal PGO rules (python#104524)pythongh-103861: Fix Zip64 extensions not being properly applied in some cases (python#103863)pythongh-69152: add method get_proxy_response_headers to HTTPConnection class (python#104248)pythongh-103763: Implement PEP 695 (python#103764)pythongh-104461: Run tkinter test_configure_screen on X11 only (pythonGH-104462)pythongh-104469: Convert _testcapi/watchers.c to use Argument Clinic (python#104503)pythongh-104482: Fix error handling bugs in ast.c (python#104483)pythongh-104341: Adjust tstate_must_exit() to Respect Interpreter Finalization (pythongh-104437)pythonGH-102613: Fix recursion error from `pathlib.Path.glob()` (pythonGH-104373)
@sobolevn
Copy link
Member

sobolevn commentedJun 10, 2023
edited
Loading

Sorry for being late for the review, but I would like to note thatget_proxy_response_headers now is not consistent in its return type. If there are headers, it returnsHTTPMessage class (which has thismro:(<class 'http.client.HTTPMessage'>, <class 'email.message.Message'>, <class 'object'>)), but if there are no headers it returns{}. Why?

I think that the source of this confusion is thatemail.message.Message behaves like aMapping, but I still think that we should change the default value toNone before it is too late.

This way we can say that this method returnsOptional[HTTPMessage] and notHTTPMessage | dict[str, str] (orMapping[str, str], which will erase a lot of useful methods).

I will open a new PR for this.

nametkin, arhadthedev, and gpshead reacted with thumbs up emoji

Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment
Reviewers

@gpsheadgpsheadgpshead approved these changes

Assignees

@gpsheadgpshead

Labels
None yet
Projects
None yet
Milestone
No milestone
Development

Successfully merging this pull request may close these issues.

5 participants
@nametkin@bedevere-bot@arhadthedev@sobolevn@gpshead

[8]ページ先頭

©2009-2025 Movatter.jp