<feed xmlns='http://www.w3.org/2005/Atom'>
<title>python.git/Lib/compileall.py, branch 3.7</title>
<subtitle>Unnamed repository; edit this file 'description' to name the repository.</subtitle>
<id>http://dangofactory.net/cgit/cgit.cgi/Server/python.git/atom/Lib/compileall.py?h=3.7</id>
<link rel='self' href='http://dangofactory.net/cgit/cgit.cgi/Server/python.git/atom/Lib/compileall.py?h=3.7'/>
<link rel='alternate' type='text/html' href='http://dangofactory.net/cgit/cgit.cgi/Server/python.git/'/>
<updated>2020-03-01T19:06:54Z</updated>
<entry>
<title>[3.7] bpo-39769: Fix compileall ddir for subpkgs. (GH-18676) (GH-18718) (GH-18725)</title>
<updated>2020-03-01T19:06:54Z</updated>
<author>
<name>Gregory P. Smith</name>
<email>greg@krypto.org</email>
</author>
<published>2020-03-01T19:06:54Z</published>
<link rel='alternate' type='text/html' href='http://dangofactory.net/cgit/cgit.cgi/Server/python.git/commit/?id=7c64726ced3d6b5d04537386d6a9ca6d179c3be4'/>
<id>urn:sha1:7c64726ced3d6b5d04537386d6a9ca6d179c3be4</id>
<content type='text'>
Fix compileall.compile_dir() ddir= behavior on sub-packages.

Fixes compileall.compile_dir's ddir parameter and compileall command
line flag `-d` to no longer write the wrong pathname to the generated
pyc file for submodules beneath the root of the directory tree being
compiled.  This fixes a regression introduced with Python 3.5.

Tests backported from GH 02673352b5db6ca4d3dc804965facbedfe66425d, the
implementation is different due to intervening code changes.  But still
quiet simple.

Why was the bug ever introduced?  The refactoring to add parallel
execution kept the ddir -&gt; dfile computations but discarded the results
instead of sending them to compile_file().  This fixes that.  Lack of tests
meant this went unnoticed..
(cherry picked from commit ce720d3e0674d6ac6f1b950c20a89be4cfde7853)

Co-authored-by: Gregory P. Smith &lt;greg@krypto.org&gt; [Google]</content>
</entry>
<entry>
<title>bpo-34022: Stop forcing of hash-based invalidation with SOURCE_DATE_EPOCH (GH-9607)</title>
<updated>2018-11-28T17:45:36Z</updated>
<author>
<name>Miss Islington (bot)</name>
<email>31488909+miss-islington@users.noreply.github.com</email>
</author>
<published>2018-11-28T17:45:36Z</published>
<link rel='alternate' type='text/html' href='http://dangofactory.net/cgit/cgit.cgi/Server/python.git/commit/?id=24b51b1a4919e310d338629cc60371387f475a32'/>
<id>urn:sha1:24b51b1a4919e310d338629cc60371387f475a32</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.
(cherry picked from commit a6b3ec5b6d4f6387820fccc570eea08b9615620d)

Co-authored-by: Elvis Pranskevichus &lt;elvis@magic.io&gt;</content>
</entry>
<entry>
<title>bpo-29877: compileall: import ProcessPoolExecutor only when needed (GH-4856)</title>
<updated>2018-11-23T17:41:54Z</updated>
<author>
<name>Miss Islington (bot)</name>
<email>31488909+miss-islington@users.noreply.github.com</email>
</author>
<published>2018-11-23T17:41:54Z</published>
<link rel='alternate' type='text/html' href='http://dangofactory.net/cgit/cgit.cgi/Server/python.git/commit/?id=903a3e8d67b61594c0fa17fb201769ca924b38f8'/>
<id>urn:sha1:903a3e8d67b61594c0fa17fb201769ca924b38f8</id>
<content type='text'>
Importing ProcessPoolExecutor may hang or cause an error when the import
accesses urandom on a low resource platform

https://bugs.python.org/issue29877
(cherry picked from commit 1d817e4c8259f49602eefe9729743f6d9d748e8d)

Co-authored-by: Dustin Spicuzza &lt;dustin@virtualroadside.com&gt;</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 #28485: Merge single-threading fix from 3.5 into 3.6</title>
<updated>2016-11-05T01:35:25Z</updated>
<author>
<name>Martin Panter</name>
<email>vadmium+py@gmail.com</email>
</author>
<published>2016-11-05T01:35:25Z</published>
<link rel='alternate' type='text/html' href='http://dangofactory.net/cgit/cgit.cgi/Server/python.git/commit/?id=cee93c3b73a115e9f2982b9210be15c417a482dc'/>
<id>urn:sha1:cee93c3b73a115e9f2982b9210be15c417a482dc</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Issue #28485: Check for negative workers even without ProcessPoolExecutor</title>
<updated>2016-11-05T01:11:36Z</updated>
<author>
<name>Martin Panter</name>
<email>vadmium+py@gmail.com</email>
</author>
<published>2016-11-05T01:11:36Z</published>
<link rel='alternate' type='text/html' href='http://dangofactory.net/cgit/cgit.cgi/Server/python.git/commit/?id=88281ceed02d8f4599cb22f196e40bc30f4fb689'/>
<id>urn:sha1:88281ceed02d8f4599cb22f196e40bc30f4fb689</id>
<content type='text'>
This matches the documentation, and passes the test suite when multithreading
is disabled.
</content>
</entry>
<entry>
<title>Issue #28226: compileall now supports pathlib</title>
<updated>2016-09-30T21:54:18Z</updated>
<author>
<name>Berker Peksag</name>
<email>berker.peksag@gmail.com</email>
</author>
<published>2016-09-30T21:54:18Z</published>
<link rel='alternate' type='text/html' href='http://dangofactory.net/cgit/cgit.cgi/Server/python.git/commit/?id=812a2b65af1897aa9694ff65fc62516a4e10269c'/>
<id>urn:sha1:812a2b65af1897aa9694ff65fc62516a4e10269c</id>
<content type='text'>
</content>
</entry>
<entry>
<title>Issue #25768: Make compileall functions return booleans and document</title>
<updated>2015-12-27T21:17:04Z</updated>
<author>
<name>Brett Cannon</name>
<email>brett@python.org</email>
</author>
<published>2015-12-27T21:17:04Z</published>
<link rel='alternate' type='text/html' href='http://dangofactory.net/cgit/cgit.cgi/Server/python.git/commit/?id=1e3c3e906c9f1fcc463cfb3641d078eec773666f'/>
<id>urn:sha1:1e3c3e906c9f1fcc463cfb3641d078eec773666f</id>
<content type='text'>
the return values as well as test them.

Thanks to Nicholas Chammas for the bug report and initial patch.
</content>
</entry>
<entry>
<title>Merge: #24903: Remove misleading error message to fix regression.</title>
<updated>2015-12-05T04:04:37Z</updated>
<author>
<name>R David Murray</name>
<email>rdmurray@bitdance.com</email>
</author>
<published>2015-12-05T04:04:37Z</published>
<link rel='alternate' type='text/html' href='http://dangofactory.net/cgit/cgit.cgi/Server/python.git/commit/?id=939614c48c3b0b5adeb408294a032118411ab987'/>
<id>urn:sha1:939614c48c3b0b5adeb408294a032118411ab987</id>
<content type='text'>
</content>
</entry>
<entry>
<title>#24903: Remove misleading error message to fix regression.</title>
<updated>2015-12-05T03:54:38Z</updated>
<author>
<name>R David Murray</name>
<email>rdmurray@bitdance.com</email>
</author>
<published>2015-12-05T03:54:38Z</published>
<link rel='alternate' type='text/html' href='http://dangofactory.net/cgit/cgit.cgi/Server/python.git/commit/?id=ced699b4c7e79e0a53e3ca7f2d789b761d4a9e76'/>
<id>urn:sha1:ced699b4c7e79e0a53e3ca7f2d789b761d4a9e76</id>
<content type='text'>
Before the argparse conversion, compileall would (sometimes) accept multiple
paths when -d was specified.  Afterward, it does not.  The corresponding check
in the original code claimed to prevent multiple *directories* from being
specified...but it didn't really work even to do that.  So this patch fixes
the regression by invoking the consenting adults rule: if you specify a
combination of arguments to compileall that produces files with inconsistent
destdirs (which you could do before), it is on you.

Patch by Jake Garver.
</content>
</entry>
</feed>
