Skip to content
Permalink
Browse files

bpo-35224: Bump the pyc magic number after the change in MAP_ADD (GH-…

…14313)

(cherry picked from commit 663131a)

Co-authored-by: Pablo Galindo <Pablogsal@gmail.com>
  • Loading branch information...
miss-islington and pablogsal committed Jun 22, 2019
1 parent 874ff65 commit 5c8b4e2b5de647a67dd1b6414fa520d2b8e973aa
Showing with 124 additions and 122 deletions.
  1. +3 −1 Lib/importlib/_bootstrap_external.py
  2. +121 −121 Python/importlib_external.h
@@ -266,6 +266,8 @@ def _write_atomic(path, data, mode=0o666):
# Python 3.8a1 3400 (move frame block handling to compiler #17611)
# Python 3.8a1 3401 (add END_ASYNC_FOR #33041)
# Python 3.8a1 3410 (PEP570 Python Positional-Only Parameters #36540)
# Python 3.8b2 3420 (Reverse evaluation order of key: value in dict
# comprehensions #35224)
#
# MAGIC must change whenever the bytecode emitted by the compiler may no
# longer be understood by older implementations of the eval loop (usually
@@ -274,7 +276,7 @@ def _write_atomic(path, data, mode=0o666):
# Whenever MAGIC_NUMBER is changed, the ranges in the magic_values array
# in PC/launcher.c must also be updated.

MAGIC_NUMBER = (3410).to_bytes(2, 'little') + b'\r\n'
MAGIC_NUMBER = (3420).to_bytes(2, 'little') + b'\r\n'
_RAW_MAGIC_NUMBER = int.from_bytes(MAGIC_NUMBER, 'little') # For import.c

_PYCACHE = '__pycache__'

0 comments on commit 5c8b4e2

Please sign in to comment.
You can’t perform that action at this time.