Skip to content
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

Incorrect handling of PyObject_RichCompareBool() in the _zoneinfo module #87298

Open
ZackerySpytz mannequin opened this issue Feb 4, 2021 · 6 comments
Open

Incorrect handling of PyObject_RichCompareBool() in the _zoneinfo module #87298

ZackerySpytz mannequin opened this issue Feb 4, 2021 · 6 comments
Labels
3.11 bug and security fixes 3.12 bugs and security fixes 3.13 new features, bugs and security fixes extension-modules C modules in the Modules dir type-bug An unexpected behavior, bug, or error

Comments

@ZackerySpytz
Copy link
Mannequin

ZackerySpytz mannequin commented Feb 4, 2021

BPO 43132
Nosy @serhiy-storchaka, @pganssle, @ZackerySpytz, @miss-islington
PRs
  • bpo-43132: Fix incorrect handling of PyObject_RichCompareBool() in _zoneinfo #24450
  • [3.9] bpo-43132: Fix incorrect handling of PyObject_RichCompareBool() in _zoneinfo (GH-24450) #24457
  • gh-87298: Add tests for find_in_strong_cache() bug in _zoneinfo #24829
  • 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 = None
    created_at = <Date 2021-02-04.23:48:01.917>
    labels = ['extension-modules', 'type-bug', '3.9', '3.10']
    title = 'Incorrect handling of PyObject_RichCompareBool() in the _zoneinfo module'
    updated_at = <Date 2021-03-11.22:56:35.067>
    user = 'https://github.com/ZackerySpytz'

    bugs.python.org fields:

    activity = <Date 2021-03-11.22:56:35.067>
    actor = 'ZackerySpytz'
    assignee = 'none'
    closed = False
    closed_date = None
    closer = None
    components = ['Extension Modules']
    creation = <Date 2021-02-04.23:48:01.917>
    creator = 'ZackerySpytz'
    dependencies = []
    files = []
    hgrepos = []
    issue_num = 43132
    keywords = ['patch']
    message_count = 6.0
    messages = ['386503', '386517', '386531', '386535', '386548', '386590']
    nosy_count = 4.0
    nosy_names = ['serhiy.storchaka', 'p-ganssle', 'ZackerySpytz', 'miss-islington']
    pr_nums = ['24450', '24457', '24829']
    priority = 'normal'
    resolution = None
    stage = 'patch review'
    status = 'open'
    superseder = None
    type = 'behavior'
    url = 'https://bugs.python.org/issue43132'
    versions = ['Python 3.9', 'Python 3.10']

    @ZackerySpytz
    Copy link
    Mannequin Author

    ZackerySpytz mannequin commented Feb 4, 2021

    PyObject_RichCompareBool() returns -1 on error, but this case is not handled
    by the find_in_strong_cache() function.

    @ZackerySpytz ZackerySpytz mannequin added 3.9 only security fixes 3.10 only security fixes extension-modules C modules in the Modules dir labels Feb 4, 2021
    @serhiy-storchaka
    Copy link
    Member

    New changeset effaec0 by Zackery Spytz in branch 'master':
    bpo-43132: Fix incorrect handling of PyObject_RichCompareBool() in _zoneinfo (GH-24450)
    effaec0

    @serhiy-storchaka
    Copy link
    Member

    New changeset c8b4375 by Miss Islington (bot) in branch '3.9':
    bpo-43132: Fix incorrect handling of PyObject_RichCompareBool() in _zoneinfo (GH-24450) (GH-24457)
    c8b4375

    @pganssle
    Copy link
    Member

    pganssle commented Feb 5, 2021

    Re-opening because this was merged without tests.

    @ZackerySpytz would you mind adding tests to hit these error cases? I've spent some time satisfying myself that it's indeed possible, and I've detailed a general outline here: #24450 (comment)

    @pganssle pganssle reopened this Feb 5, 2021
    @pganssle pganssle added the type-bug An unexpected behavior, bug, or error label Feb 5, 2021
    @pganssle pganssle reopened this Feb 5, 2021
    @pganssle pganssle added the type-bug An unexpected behavior, bug, or error label Feb 5, 2021
    @serhiy-storchaka
    Copy link
    Member

    Sorry, I thought I just forgot to close this issue.

    @ZackerySpytz
    Copy link
    Mannequin Author

    ZackerySpytz mannequin commented Feb 7, 2021

    Okay, I will add some tests.

    @ezio-melotti ezio-melotti transferred this issue from another repository Apr 10, 2022
    @erlend-aasland erlend-aasland added 3.11 bug and security fixes 3.12 bugs and security fixes 3.13 new features, bugs and security fixes and removed 3.10 only security fixes 3.9 only security fixes labels Jan 5, 2024
    Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
    Labels
    3.11 bug and security fixes 3.12 bugs and security fixes 3.13 new features, bugs and security fixes extension-modules C modules in the Modules dir type-bug An unexpected behavior, bug, or error
    Projects
    Development

    No branches or pull requests

    3 participants