Bug 1572171 - python2 is bytecompiled by /usr/bin/python2.7, not the built binary
Summary: python2 is bytecompiled by /usr/bin/python2.7, not the built binary
Alias: None
Product: Fedora
Classification: Fedora
Component: python2
Version: rawhide
Hardware: Unspecified
OS: Unspecified
Target Milestone: ---
Assignee: Miro Hrončok
QA Contact: Fedora Extras Quality Assurance
Depends On:
TreeView+ depends on / blocked
Reported: 2018-04-26 10:19 UTC by Miro Hrončok
Modified: 2018-04-30 11:02 UTC (History)
9 users (show)

Fixed In Version: python2-2.7.14-17.fc29
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Last Closed: 2018-04-30 11:02:12 UTC
Type: Bug

Attachments (Terms of Use)

System ID Private Priority Status Summary Last Updated
Red Hat Bugzilla 1570250 0 unspecified CLOSED All the pythons do extra crazy things to stop BRP python bytecompile 2021-02-22 00:41:40 UTC

Internal Links: 1570250

Description Miro Hrončok 2018-04-26 10:19:23 UTC
While all the other pythons turn of the brp-python-bytecmpile script and bytecompile the files manually by the freshly built binary, python2 apparently just lets brp-python-bytecmpile bytecompile everything with /usr/bin/python2.7.

This might bite use some day for the following reason:

 * pythoon2 now uses python2 during buildtime without buildrequiring it explicitly and things works because it is pulled in transitively
 * if the bytecode format changes (extremely unlikely, however possible), the build has to be bootstrapped.

While I think the severity of this is fairly minimal, I'd like to solve this while looking into bz1570250.

Comment 1 Miro Hrončok 2018-04-26 10:35:46 UTC
Running brp-python-bytecompile also results in:

DEPRECATION WARNING: python2 invoked with /usr/bin/python.

Twice at the end of the script.

Note You need to log in before you can comment on or make changes to this bug.