<feed xmlns='http://www.w3.org/2005/Atom'>
<title>python.git/Lib/py_compile.py, branch 3.10</title>
<subtitle>Python interpreter</subtitle>
<id>http://dangofactory.net/cgit/cgit.cgi/Server/python.git/atom/Lib/py_compile.py?h=3.10</id>
<link rel='self' href='http://dangofactory.net/cgit/cgit.cgi/Server/python.git/atom/Lib/py_compile.py?h=3.10'/>
<link rel='alternate' type='text/html' href='http://dangofactory.net/cgit/cgit.cgi/Server/python.git/'/>
<updated>2021-10-15T12:14:35Z</updated>
<entry>
<title>bpo-45428: Fix reading filenames from stdin in py_compile (GH-28848)</title>
<updated>2021-10-15T12:14:35Z</updated>
<author>
<name>Miss Islington (bot)</name>
<email>31488909+miss-islington@users.noreply.github.com</email>
</author>
<published>2021-10-15T12:14:35Z</published>
<link rel='alternate' type='text/html' href='http://dangofactory.net/cgit/cgit.cgi/Server/python.git/commit/?id=2b6eb8149656541044884e76212495175e061a0a'/>
<id>urn:sha1:2b6eb8149656541044884e76212495175e061a0a</id>
<content type='text'>
Strip trailing '\n'.
(cherry picked from commit 59a633d3e2071d65aa6638da5cf767a5c1310271)

Co-authored-by: Graham Inggs &lt;ginggs@debian.org&gt;</content>
</entry>
<entry>
<title>bpo-38731: Add --quiet option to py_compile CLI (GH-17134)</title>
<updated>2020-07-25T19:58:45Z</updated>
<author>
<name>Gregory Schevchenko</name>
<email>3405066+gvsheva@users.noreply.github.com</email>
</author>
<published>2020-07-25T19:58:45Z</published>
<link rel='alternate' type='text/html' href='http://dangofactory.net/cgit/cgit.cgi/Server/python.git/commit/?id=daff39070e7ea71b0ba49d9150ac7a210a125682'/>
<id>urn:sha1:daff39070e7ea71b0ba49d9150ac7a210a125682</id>
<content type='text'>
</content>
</entry>
<entry>
<title>bpo-22640: Add silent mode to py_compile.compile() (GH-12976)</title>
<updated>2019-05-28T16:29:04Z</updated>
<author>
<name>Joannah Nanjekye</name>
<email>33177550+nanjekyejoannah@users.noreply.github.com</email>
</author>
<published>2019-05-28T16:29:04Z</published>
<link rel='alternate' type='text/html' href='http://dangofactory.net/cgit/cgit.cgi/Server/python.git/commit/?id=2e33ecd7c9b0cac3efc6fcbdd4547fd086b4e2d1'/>
<id>urn:sha1:2e33ecd7c9b0cac3efc6fcbdd4547fd086b4e2d1</id>
<content type='text'>
</content>
</entry>
<entry>
<title>bpo-34022: Stop forcing of hash-based invalidation with SOURCE_DATE_EPOCH (GH-9607)</title>
<updated>2018-10-10T16:43:14Z</updated>
<author>
<name>Elvis Pranskevichus</name>
<email>elvis@magic.io</email>
</author>
<published>2018-10-10T16:43:14Z</published>
<link rel='alternate' type='text/html' href='http://dangofactory.net/cgit/cgit.cgi/Server/python.git/commit/?id=a6b3ec5b6d4f6387820fccc570eea08b9615620d'/>
<id>urn:sha1:a6b3ec5b6d4f6387820fccc570eea08b9615620d</id>
<content type='text'>
Unconditional forcing of ``CHECKED_HASH`` invalidation was introduced in
3.7.0 in bpo-29708.  The change is bad, as it unconditionally overrides
*invalidation_mode*, even if it was passed as an explicit argument to
``py_compile.compile()`` or ``compileall``.  An environment variable
should *never* override an explicit argument to a library function.
That change leads to multiple test failures if the ``SOURCE_DATE_EPOCH``
environment variable is set.

This changes ``py_compile.compile()`` to only look at
``SOURCE_DATE_EPOCH`` if no explicit *invalidation_mode* was specified.
I also made various relevant tests run with explicit control over the
value of ``SOURCE_DATE_EPOCH``.

While looking at this, I noticed that ``zipimport`` does not work
with hash-based .pycs _at all_, though I left the fixes for
subsequent commits.</content>
</entry>
<entry>
<title>bpo-29708: Setting SOURCE_DATE_EPOCH forces hash-based .pyc files (GH-5200)</title>
<updated>2018-01-24T21:26:18Z</updated>
<author>
<name>Bernhard M. Wiedemann</name>
<email>githubbmw@lsmod.de</email>
</author>
<published>2018-01-24T21:26:18Z</published>
<link rel='alternate' type='text/html' href='http://dangofactory.net/cgit/cgit.cgi/Server/python.git/commit/?id=ccbe5818af20f8c12043f5c30c277a74714405e0'/>
<id>urn:sha1:ccbe5818af20f8c12043f5c30c277a74714405e0</id>
<content type='text'>
To support reproducible builds, the setting of of SOURCE_DATE_EPOCH triggers the py_compile module -- and by extension, compileall -- to forcibly compile with hash-based .pyc files. This eliminates the possibility of timestamp-based .pyc files which vary between builds.</content>
</entry>
<entry>
<title>closes bpo-31650: PEP 552 (Deterministic pycs) implementation (#4575)</title>
<updated>2017-12-09T18:26:52Z</updated>
<author>
<name>Benjamin Peterson</name>
<email>benjamin@python.org</email>
</author>
<published>2017-12-09T18:26:52Z</published>
<link rel='alternate' type='text/html' href='http://dangofactory.net/cgit/cgit.cgi/Server/python.git/commit/?id=42aa93b8ff2f7879282b06efc73a31ec7785e602'/>
<id>urn:sha1:42aa93b8ff2f7879282b06efc73a31ec7785e602</id>
<content type='text'>
Python now supports checking bytecode cache up-to-dateness with a hash of the
source contents rather than volatile source metadata. See the PEP for details.

While a fairly straightforward idea, quite a lot of code had to be modified due
to the pervasiveness of pyc implementation details in the codebase. Changes in
this commit include:

- The core changes to importlib to understand how to read, validate, and
  regenerate hash-based pycs.

- Support for generating hash-based pycs in py_compile and compileall.

- Modifications to our siphash implementation to support passing a custom
  key. We then expose it to importlib through _imp.

- Updates to all places in the interpreter, standard library, and tests that
  manually generate or parse pyc files to grok the new format.

- Support in the interpreter command line code for long options like
  --check-hash-based-pycs.

- Tests and documentation for all of the above.
</content>
</entry>
<entry>
<title>Issue #23911: Move path-based bootstrap code to a separate frozen module.</title>
<updated>2015-05-03T01:15:18Z</updated>
<author>
<name>Eric Snow</name>
<email>ericsnowcurrently@gmail.com</email>
</author>
<published>2015-05-03T01:15:18Z</published>
<link rel='alternate' type='text/html' href='http://dangofactory.net/cgit/cgit.cgi/Server/python.git/commit/?id=32439d6eb63f1ea31aed1e45459f0f50f965ef51'/>
<id>urn:sha1:32439d6eb63f1ea31aed1e45459f0f50f965ef51</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Issue #23811: Add missing newline to the PyCompileError error message.</title>
<updated>2015-04-14T15:58:45Z</updated>
<author>
<name>Berker Peksag</name>
<email>berker.peksag@gmail.com</email>
</author>
<published>2015-04-14T15:58:45Z</published>
<link rel='alternate' type='text/html' href='http://dangofactory.net/cgit/cgit.cgi/Server/python.git/commit/?id=012e287081f85feebe0a49c73de8b4a84f0a1b02'/>
<id>urn:sha1:012e287081f85feebe0a49c73de8b4a84f0a1b02</id>
<content type='text'>
Patch by Alex Shkop.
</content>
</entry>
<entry>
<title>Issue #23811: Add missing newline to the PyCompileError error message.</title>
<updated>2015-04-14T15:57:55Z</updated>
<author>
<name>Berker Peksag</name>
<email>berker.peksag@gmail.com</email>
</author>
<published>2015-04-14T15:57:55Z</published>
<link rel='alternate' type='text/html' href='http://dangofactory.net/cgit/cgit.cgi/Server/python.git/commit/?id=34c9be7ebdc135e38914d161b028f5b56bf00642'/>
<id>urn:sha1:34c9be7ebdc135e38914d161b028f5b56bf00642</id>
<content type='text'>
Patch by Alex Shkop.
</content>
</entry>
<entry>
<title>Issue #23731: Implement PEP 488.</title>
<updated>2015-04-13T18:21:02Z</updated>
<author>
<name>Brett Cannon</name>
<email>brett@python.org</email>
</author>
<published>2015-04-13T18:21:02Z</published>
<link rel='alternate' type='text/html' href='http://dangofactory.net/cgit/cgit.cgi/Server/python.git/commit/?id=f299abdafa0f2b6eb7abae274861b19b361c96bc'/>
<id>urn:sha1:f299abdafa0f2b6eb7abae274861b19b361c96bc</id>
<content type='text'>
The concept of .pyo files no longer exists. Now .pyc files have an
optional `opt-` tag which specifies if any extra optimizations beyond
the peepholer were applied.
</content>
</entry>
</feed>
