GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — gh-135532: use `defining_class` for copying BLAKE-2 and SHA-3 objects by picnixz · Pull Request #135838 · python/cpython

Conversation

@picnixz

@picnixz picnixz commented Jun 23, 2025 •
edited by bedevere-app Bot
Loading

Uh oh!

There was an error while loading. Please reload this page.

Copy link
Copy Markdown
Member

Performance are left untouched even if we're not using a METH_NOARGS. I tried to remove the defining_class in existing code but it didn't help. If we were to allow subclassing in the future, this saves some work as we would only need to touch constructors and not the methods themselves.

  • Issue: Rewrite & cleanup HACL*-based extension modules #135532

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

All reactions
@picnixz
use 'defining_class' when copying HACL*-based hashes
f631476
@picnixz
picnixz requested review from gpshead and tiran as code owners June 23, 2025 10:22
@picnixz picnixz added skip news type-refactor Code refactoring (with no changes in behavior) labels Jun 23, 2025
@bedevere-app bedevere-app Bot added the awaiting core review label Jun 23, 2025
@picnixz picnixz changed the title gh-135532: use defining_class for copying HACL*-based BLAKE-2 and SHA-3 objects gh-135532: use defining_class for copying BLAKE-2 and SHA-3 objects Jun 23, 2025
@bedevere-app bedevere-app Bot mentioned this pull request Jun 23, 2025
Rewrite & cleanup HACL*-based extension modules #135532
Closed
@picnixz

picnixz commented Jun 23, 2025

Copy link
Copy Markdown
Member Author

!buildbot FIPS only

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@bedevere-bot

bedevere-bot commented Jun 23, 2025

Copy link
Copy Markdown

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

Results will be shown at:

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

The command will test the builders whose names match following regular expression: FIPS only

The builders matched are:

  • AMD64 RHEL8 FIPS Only Blake2 Builtin Hash PR
  • AMD64 CentOS9 FIPS Only Blake2 Builtin Hash PR
All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@picnixz
simplify test
26a029c
@picnixz

picnixz commented Jun 23, 2025

Copy link
Copy Markdown
Member Author

!buildbot FIPS only

All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@bedevere-bot

bedevere-bot commented Jun 23, 2025

Copy link
Copy Markdown

🤖 New build scheduled with the buildbot fleet by @picnixz for commit 26a029c 🤖

Results will be shown at:

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

The command will test the builders whose names match following regular expression: FIPS only

The builders matched are:

  • AMD64 RHEL8 FIPS Only Blake2 Builtin Hash PR
  • AMD64 CentOS9 FIPS Only Blake2 Builtin Hash PR
All reactions

Sorry, something went wrong.

Uh oh!

There was an error while loading. Please reload this page.

@picnixz
picnixz merged commit ef4fc86 into python:main Jun 24, 2025
@picnixz
picnixz deleted the refactor/hashlib/defining-class-135532 branch June 24, 2025 07:58
@bedevere-app bedevere-app Bot removed the awaiting core review label Jun 24, 2025
AndPuQing pushed a commit to AndPuQing/cpython that referenced this pull request Jul 11, 2025
@picnixz @AndPuQing
pythongh-135532: use defining_class for copying BLAKE-2 and SHA-3 o…
e856bb9
…bjects (python#135838)
Pranjal095 pushed a commit to Pranjal095/cpython that referenced this pull request Jul 12, 2025
@picnixz @Pranjal095
pythongh-135532: use defining_class for copying BLAKE-2 and SHA-3 o…
9b530a9
…bjects (python#135838)
taegyunkim pushed a commit to taegyunkim/cpython that referenced this pull request Aug 4, 2025
@picnixz @taegyunkim
pythongh-135532: use defining_class for copying BLAKE-2 and SHA-3 o…
6c18125
…bjects (python#135838)
Agent-Hellboy pushed a commit to Agent-Hellboy/cpython that referenced this pull request Aug 19, 2025
@picnixz @Agent-Hellboy
pythongh-135532: use defining_class for copying BLAKE-2 and SHA-3 o…
4dc62a2
…bjects (python#135838)
@devdanzin devdanzin mentioned this pull request Jul 2, 2026
hashlib BLAKE2 .copy() crashes with Py_UNREACHABLE in py_blake2_clear when the copy's allocation fails #152851
Closed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Reviewers

@gpshead gpshead Awaiting requested review from gpshead gpshead is a code owner
@tiran tiran Awaiting requested review from tiran

Uh oh!

There was an error while loading. Please reload this page.

Assignees

No one assigned

Labels

skip news type-refactor Code refactoring (with no changes in behavior)

Projects

None yet

Milestone

No milestone

Development

Successfully merging this pull request may close these issues.

Uh oh!

There was an error while loading. Please reload this page.

2 participants

@picnixz @bedevere-bot
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
You are visitor 01402503 — GeezerVison does not store the pages you look up.
Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.