Skip to content

Some errnos for BSD/OSX are missing from errno module #87137

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

Closed
ngie-eign mannequin opened this issue Jan 19, 2021 · 6 comments
Closed

Some errnos for BSD/OSX are missing from errno module #87137

ngie-eign mannequin opened this issue Jan 19, 2021 · 6 comments
Labels
3.11 only security fixes extension-modules C modules in the Modules dir type-feature A feature request or enhancement

Comments

@ngie-eign
Copy link
Mannequin

ngie-eign mannequin commented Jan 19, 2021

BPO 42971
Nosy @ronaldoussoren, @ned-deily, @ngie-eign, @ambv
PRs
  • bpo-42971: Add errno.EQFULL (macOS) #24419
  • Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.

    Show more details

    GitHub fields:

    assignee = None
    closed_at = <Date 2021-08-06.21:36:13.658>
    created_at = <Date 2021-01-19.20:56:36.033>
    labels = ['extension-modules', 'type-feature', '3.11']
    title = 'Some errnos for BSD/OSX are missing from errno module'
    updated_at = <Date 2021-08-06.21:36:13.657>
    user = 'https://github.com/ngie-eign'

    bugs.python.org fields:

    activity = <Date 2021-08-06.21:36:13.657>
    actor = 'lukasz.langa'
    assignee = 'none'
    closed = True
    closed_date = <Date 2021-08-06.21:36:13.658>
    closer = 'lukasz.langa'
    components = ['Extension Modules']
    creation = <Date 2021-01-19.20:56:36.033>
    creator = 'ngie'
    dependencies = []
    files = []
    hgrepos = []
    issue_num = 42971
    keywords = ['patch']
    message_count = 6.0
    messages = ['385293', '385295', '386157', '386158', '399154', '399155']
    nosy_count = 4.0
    nosy_names = ['ronaldoussoren', 'ned.deily', 'ngie', 'lukasz.langa']
    pr_nums = ['24419']
    priority = 'normal'
    resolution = 'fixed'
    stage = 'resolved'
    status = 'closed'
    superseder = None
    type = 'enhancement'
    url = 'https://bugs.python.org/issue42971'
    versions = ['Python 3.11']

    @ngie-eign
    Copy link
    Mannequin Author

    ngie-eign mannequin commented Jan 19, 2021

    Some errnos for BSD/OSX are currently not supported by the errno module. It would be helpful for these to be exposed to the end-user so they could programmatically use them instead of reinventing the wheel in a separate module/C extension, or hardcoding the information in consuming pieces of code.

    @ngie-eign ngie-eign mannequin added 3.8 (EOL) end of life extension-modules C modules in the Modules dir labels Jan 19, 2021
    @ngie-eign
    Copy link
    Mannequin Author

    ngie-eign mannequin commented Jan 19, 2021

    Some items that I've noted so far that are missing:

    • ENOATTR (BSD/OSX)
    • ENOLINK (BSD; is reserved on OSX)
    • ENOTSUP (NetBSD, OpenBSD, OSX)

    @terryjreedy terryjreedy added 3.10 only security fixes type-feature A feature request or enhancement and removed 3.8 (EOL) end of life labels Jan 23, 2021
    @ronaldoussoren
    Copy link
    Contributor

    I've checked all three and all of them are present in errnomodule.c, and all of them are defined in the errno module (macOS 11, Python 3.9.1 "universal2" build).

    On first glance all errno values in the macOS 11 SDK are present in errnomodule.c.

    @ronaldoussoren
    Copy link
    Contributor

    I was too quick, EQFULL appears to be missing:

    #define EQFULL          106             /* Interface output queue is full */

    If the script I'm using to check for this is correct this is the only missing errno with the macOS 11 SDK.

    @ambv ambv added 3.11 only security fixes and removed 3.10 only security fixes labels Aug 6, 2021
    @ambv
    Copy link
    Contributor

    ambv commented Aug 6, 2021

    New changeset 17c2316 by Ronald Oussoren in branch 'main':
    bpo-42971: Add errno.EQFULL (macOS) (GH-24419)
    17c2316

    @ambv
    Copy link
    Contributor

    ambv commented Aug 6, 2021

    Thanks for the patch, Ronald, and for the report, Enji! ✨ 🍰 ✨

    @ambv ambv closed this as completed Aug 6, 2021
    @ambv ambv closed this as completed Aug 6, 2021
    @ezio-melotti ezio-melotti transferred this issue from another repository Apr 10, 2022
    Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
    Labels
    3.11 only security fixes extension-modules C modules in the Modules dir type-feature A feature request or enhancement
    Projects
    None yet
    Development

    No branches or pull requests

    3 participants