10000 gh-120056: Add `IP_RECVERR`, `IP_RECVORIGDSTADDR`, `IP_RECVTTL` to `socket` module by sobolevn · Pull Request #120058 · python/cpython · GitHub
[go: up one dir, main page]

Skip to content

gh-120056: Add IP_RECVERR, IP_RECVORIGDSTADDR, IP_RECVTTL to socket module #120058

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 8000

Merged
merged 4 commits into from
Jun 12, 2024

Conversation

sobolevn
Copy link
Member
@sobolevn sobolevn commented Jun 4, 2024

Copy link
Member
@Eclips4 Eclips4 left a comment

Choose a reason for hiding this comment

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

LGTM!

@jeremyhylton jeremyhylton self-assigned this Jun 8, 2024
@@ -8421,6 +8421,12 @@ socket_exec(PyObject *m)
#ifdef IP_RECVTOS
ADD_INT_MACRO(m, IP_RECVTOS);
#endif
#ifdef IP_RECVERR
Copy link
Contributor

Choose a reason for hiding this comment

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

Can you insert these in alphabetical order?

OOC why these two options? Just looking at man 7 ip, it looks like there are a few other options we are missing, e.g. IP_RECVORIGDSTADDR. Would it make sense to add more to make this list of options more complete?

Copy link
Member Author

Choose a reason for hiding this comment

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

Sure, I added these two, because I only needed these two :)
Will add more.

sobolevn added 2 commits June 9, 2024 10:49
< 8000 batch-deferred-content class="d-inline-block" data-url="/commits/badges">
@sobolevn sobolevn changed the title gh-120056: Add IP_RECVERR and IP_RECVTTL to socket module gh-120056: Add IP_RECVERR, IP_RECVORIGDSTADDR, IP_RECVTTL to socket module Jun 9, 2024
Copy link
Member
@vstinner vstinner left a comment

Choose a reason for hiding this comment

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

LGTM.

We don't copy/paste socket constant manual pages (documentation, since the documentation is big, platform dependent, and it would be really complicated to maintain such documentation. If we decide to add a little bit more documentation than the plain generic "Many constants of these forms, documented in the Unix documentation on sockets and/or the IP protocol, are also defined in the socket module" sentence, I suggest to do it in a separated PR and not only for these 3 constants.

@jeremyhylton jeremyhylton merged commit f5a9c34 into python:main Jun 12, 2024
38 checks passed
@sobolevn
8000 Copy link
Member Author

Thanks everyone!

mrahtz pushed a commit to mrahtz/cpython that referenced this pull request Jun 30, 2024
… to `socket` module (python#120058)

* pythongh-120056: Add `IP_RECVERR` and `IP_RECVTTL` to `socket` module

* Fix news

* Address review

* Update NEWS
noahbkim pushed a commit to hudson-trading/cpython that referenced this pull request Jul 11, 2024
… to `socket` module (python#120058)

* pythongh-120056: Add `IP_RECVERR` and `IP_RECVTTL` to `socket` module

* Fix news

* Address review

* Update NEWS
estyxx pushed a commit to estyxx/cpython that referenced this pull request Jul 17, 2024
… to `socket` module (python#120058)

* pythongh-120056: Add `IP_RECVERR` and `IP_RECVTTL` to `socket` module

* Fix news

* Address review

* Update NEWS
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants
0