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-100218: correctly seterrno whensocket.if_{nametoindex,indextoname} raiseOSError#140905

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

Conversation

@picnixz
Copy link
Member

@picnixzpicnixz commentedNov 2, 2025
edited by bedevere-appbot
Loading

@picnixz
Copy link
MemberAuthor

I usedhttps://man.cx/if_nametoindex#heading5 for the default errors of each function.

@picnixzpicnixz added the 🔨 test-with-buildbotsTest PR w/ buildbots; report in status section labelNov 2, 2025
@bedevere-bot
Copy link

🤖 New build scheduled with the buildbot fleet by@picnixz for commit551a199 🤖

Results will be shown at:

https://buildbot.python.org/all/#/grid?branch=refs%2Fpull%2F140905%2Fmerge

If you want to schedule another build, you need to add the🔨 test-with-buildbots label again.

@bedevere-botbedevere-bot removed the 🔨 test-with-buildbotsTest PR w/ buildbots; report in status section labelNov 2, 2025
@picnixz
Copy link
MemberAuthor

All failures are urllib2net failures that already track:#140748.

vstinner reacted with thumbs up emoji

Copy link
Member

@vstinnervstinner left a comment

Choose a reason for hiding this comment

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

LGTM

@picnixzpicnixz merged commit3ce2d57 intopython:mainNov 9, 2025
125 of 132 checks passed
@miss-islington-app
Copy link

Thanks@picnixz for the PR 🌮🎉.. I'm working now to backport this PR to: 3.13, 3.14.
🐍🍒⛏🤖

@picnixzpicnixz deleted the fix/socket/set-errno-after-if-nametoindex-100218 branchNovember 9, 2025 12:45
miss-islington pushed a commit to miss-islington/cpython that referenced this pull requestNov 9, 2025
…ndextoname}` raise `OSError` (pythonGH-140905)Previously, socket.if_nametoindex() and socket.if_indextoname() could raisean `OSError` with a `None` errno. Now, the errno from libc is propagated.(cherry picked from commit3ce2d57)Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>
@bedevere-app
Copy link

GH-141284 is a backport of this pull request to the3.14 branch.

@miss-islington-app
Copy link

Sorry,@picnixz, I could not cleanly backport this to3.13 due to a conflict.
Please backport usingcherry_picker on command line.

cherry_picker 3ce2d57b2f02030353af314d89c5f6215d2f5c96 3.13

@bedevere-appbedevere-appbot removed the needs backport to 3.14bugs and security fixes labelNov 9, 2025
picnixz added a commit to picnixz/cpython that referenced this pull requestNov 9, 2025
…index,indextoname}` raise `OSError` (pythonGH-140905)Previously, socket.if_nametoindex() and socket.if_indextoname() could raisean `OSError` with a `None` errno. Now, the errno from libc is propagated.(cherry picked from commit3ce2d57)Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>
@bedevere-app
Copy link

GH-141285 is a backport of this pull request to the3.13 branch.

@bedevere-appbedevere-appbot removed the needs backport to 3.13bugs and security fixes labelNov 9, 2025
picnixz added a commit that referenced this pull requestNov 9, 2025
…indextoname}` raise `OSError` (GH-140905) (#141284)gh-100218: correctly set `errno` when `socket.if_{nametoindex,indextoname}` raise `OSError` (GH-140905)Previously, socket.if_nametoindex() and socket.if_indextoname() could raisean `OSError` with a `None` errno. Now, the errno from libc is propagated.(cherry picked from commit3ce2d57)Co-authored-by: Bénédikt Tran <10796600+picnixz@users.noreply.github.com>
picnixz added a commit that referenced this pull requestNov 9, 2025
…indextoname}` raise `OSError` (GH-140905) (#141285)Previously, socket.if_nametoindex() and socket.if_indextoname() could raisean `OSError` with a `None` errno. Now, the errno from libc is propagated.(cherry picked from commit3ce2d57)
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment

Reviewers

@vstinnervstinnervstinner approved these changes

@efimov-mikhailefimov-mikhailefimov-mikhail approved these changes

Assignees

@picnixzpicnixz

Labels

None yet

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

4 participants

@picnixz@bedevere-bot@vstinner@efimov-mikhail

[8]ページ先頭

©2009-2025 Movatter.jp