Skip to content

Conversation

@vstinner
Copy link
Member

@vstinner vstinner commented Oct 7, 2025

Move the function to the internal C API and no longer export it.

Move the function to the internal C API and no longer export it.
@vstinner
Copy link
Member Author

vstinner commented Oct 7, 2025

The _PyCode_ConstantKey() function is private, not documented, and not tested.

A code search in PyPI top 15,000 projects didn't find any project using this function.

I wrote this function many years ago to fix a bug in CPython. This function is useless outside CPython.

@vstinner vstinner changed the title Remove _PyCode_ConstantKey() function gh-70030: Remove _PyCode_ConstantKey() function Oct 7, 2025
@vstinner vstinner merged commit a2850a3 into python:main Oct 8, 2025
55 checks passed
@vstinner vstinner deleted the remove_code_constant_key branch October 8, 2025 20:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants