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

gh-99248: [Enum] fix negative number infinite loop #99256

Merged
merged 2 commits into from
Nov 8, 2022

Conversation

ethanfurman
Copy link
Member

@ethanfurman ethanfurman commented Nov 8, 2022

  • _iter_bits_lsb() now raises a ValueError if a negative number is passed in

  • verify() now skips checking negative numbers for named flags

- _iter_bits_lsb() now raises a ValueError if a negative number
  is passed in

- verify() now skips checking negative numbers for named flags
@ethanfurman ethanfurman added type-bug An unexpected behavior, bug, or error stdlib Python modules in the Lib dir 3.11 only security fixes 3.12 bugs and security fixes needs backport to 3.11 only security fixes labels Nov 8, 2022
@ethanfurman ethanfurman self-assigned this Nov 8, 2022
@ethanfurman ethanfurman merged commit 0b4ffb0 into python:main Nov 8, 2022
@miss-islington
Copy link
Contributor

Thanks @ethanfurman for the PR 🌮🎉.. I'm working now to backport this PR to: 3.11.
🐍🍒⛏🤖

miss-islington pushed a commit to miss-islington/cpython that referenced this pull request Nov 8, 2022
)

[Enum] fix negative number infinite loop

- _iter_bits_lsb() now raises a ValueError if a negative number
  is passed in

- verify() now skips checking negative numbers for named flags
(cherry picked from commit 0b4ffb0)

Co-authored-by: Ethan Furman <ethan@stoneleaf.us>
@bedevere-bot
Copy link

GH-99259 is a backport of this pull request to the 3.11 branch.

@bedevere-bot bedevere-bot removed the needs backport to 3.11 only security fixes label Nov 8, 2022
miss-islington added a commit that referenced this pull request Nov 8, 2022
[Enum] fix negative number infinite loop

- _iter_bits_lsb() now raises a ValueError if a negative number
  is passed in

- verify() now skips checking negative numbers for named flags
(cherry picked from commit 0b4ffb0)

Co-authored-by: Ethan Furman <ethan@stoneleaf.us>
@ethanfurman ethanfurman deleted the enum-negative_verify branch November 8, 2022 20:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
3.11 only security fixes 3.12 bugs and security fixes stdlib Python modules in the Lib dir type-bug An unexpected behavior, bug, or error
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants