A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://mail.python.org/pipermail/python-dev/2015-November/142126.html below:

[Python-Dev] PYC filename and optimization

[Python-Dev] PYC filename and optimization [Python-Dev] PYC filename and optimizationBrett Cannon brett at python.org
Thu Nov 5 13:10:41 EST 2015
On Thu, 5 Nov 2015 at 07:41 Barry Warsaw <barry at python.org> wrote:

> On Nov 05, 2015, at 11:33 AM, Victor Stinner wrote:
>
> >- Lib/__pycache__/os.cpython-36.pyc: default mode
> >- Lib/__pycache__/os.cpython-36.fat-0.pyc: FAT mode
> >
> >With -O:
> >
> >- Lib/__pycache__/os.cpython-36.opt-1.pyc: default mode
> >- Lib/__pycache__/os.cpython-36.fat-1.pyc: FAT mode
> >
> >
> >With -OO:
> >
> >- Lib/__pycache__/os.cpython-36.opt-2.pyc: default mode
> >- Lib/__pycache__/os.cpython-36.fat-2.pyc: FAT mode
> >
> >Is it the "correct" way to name .pyc files? I had to modify unit tests
> >which expected an exact filename.
>
> I think this is the logical extension of PEP 488 for your use case.
>

It will require tweaking importlib.util.cache_from_source() to no longer
restriction to alphanumeric-only for the optimization level, but that can
be tweaked to use `opt-` when given an alphanumeric and then to blindly use
another value otherwise.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/python-dev/attachments/20151105/a08c286d/attachment.html>
More information about the Python-Dev mailing list

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4