Skip to content

gh-112983: Add the known magic value of 3495 for Python 3.11 bytecode #112985

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

Merged
merged 1 commit into from
Dec 12, 2023

Conversation

wimglenn
Copy link
Contributor

@wimglenn wimglenn commented Dec 12, 2023

This line from @ambv in 1bfe83a got lost somehow (maybe conflict in #94552?)

@carljm
Copy link
Member

carljm commented Dec 12, 2023

Hmm, interesting, I don't think a bad merge is necessary to explain this, just the fact of the backporting process. The PR in main lands first, and it's unnatural there to predict a backport-version bytecode magic number that doesn't exist yet (though I suppose this is the right thing for such a PR to do). The backport PR then adds the backport magic number, but there's nothing in our process that would ever merge that forwards to main again.

This would only occur if we backport a backward-incompatible bytecode change after the beta cutoff, which I think we usually prefer not to do.

Anyway, adding the missing version certainly seems like the right thing to do. Thanks for the PR!

@carljm carljm merged commit 616622c into python:main Dec 12, 2023
@wimglenn wimglenn deleted the issue-112983 branch December 12, 2023 04:25
@wimglenn
Copy link
Contributor Author

@carljm Ah, that makes sense. I see it in the 3.11 branch but not in the 3.12 branch.
https://github.com/python/cpython/blob/3.11/Lib/importlib/_bootstrap_external.py
https://github.com/python/cpython/blob/3.12/Lib/importlib/_bootstrap_external.py
Should this be cherry-picked into 3.12 branch too?

@carljm
Copy link
Member

carljm commented Dec 12, 2023

Good call, yes, we should backport this to 3.12 as well.

@carljm carljm added the needs backport to 3.12 only security fixes label Dec 12, 2023
@miss-islington-app
Copy link

Thanks @wimglenn for the PR, and @carljm for merging it 🌮🎉.. I'm working now to backport this PR to: 3.12.
🐍🍒⛏🤖

miss-islington pushed a commit to miss-islington/cpython that referenced this pull request Dec 12, 2023
…tecode (pythonGH-112985)

Add the known magic value of 3495 for Python 3.11 bytecode
(cherry picked from commit 616622c)

Co-authored-by: wim glenn <jump@wimglenn.com>
@bedevere-app
Copy link

bedevere-app bot commented Dec 12, 2023

GH-113023 is a backport of this pull request to the 3.12 branch.

@bedevere-app bedevere-app bot removed the needs backport to 3.12 only security fixes label Dec 12, 2023
carljm pushed a commit that referenced this pull request Dec 12, 2023
…ytecode (GH-112985) (#113023)

gh-112983: Add the known magic value of 3495 for Python 3.11 bytecode (GH-112985)

Add the known magic value of 3495 for Python 3.11 bytecode
(cherry picked from commit 616622c)

Co-authored-by: wim glenn <jump@wimglenn.com>
aisk pushed a commit to aisk/cpython that referenced this pull request Feb 11, 2024
…tecode (python#112985)

Add the known magic value of 3495 for Python 3.11 bytecode
Glyphack pushed a commit to Glyphack/cpython that referenced this pull request Sep 2, 2024
…tecode (python#112985)

Add the known magic value of 3495 for Python 3.11 bytecode
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