Red Hat Bugzilla – Bug 182498
Unnecessary byte-compilation of python scripts in /usr/bin
Last modified: 2009-03-07 03:37:18 EST
brp-python-bytecompile byte-compiles also executable scripts in /usr/bin. There
should be no reason to do that; python won't byte-compile the invoked scripts to
disk either. This results in unneeded junk in the bin dirs, for example on my
$ ls /usr/bin/*.py?
/usr/bin/exif.pyc /usr/bin/games-server.pyc /usr/bin/orient.pyc
/usr/bin/exif.pyo /usr/bin/games-server.pyo /usr/bin/orient.pyo
I'm not sure of the best approach to fix this, but limiting the byte compilation
to things below /usr/lib, /usr/lib64, and /usr/share could be worth considering.
It might also be worth considering naming things *.py in /bin we have #! magic
for a reason...
Yep, agreed, but I think not byte-compiling them would still be useful as
renaming things may cause need for unnecessary patchwork for package maintainers
or upstream doc deviation etc.
Changing component to rpm as the script is in rpm-build, not redhat-rpm-config.
Reassigning to owner after bugzilla made a mess, sorry about the noise...
Based on the date this bug was created, it appears to have been reported
against rawhide during the development of a Fedora release that is no
longer maintained. In order to refocus our efforts as a project we are
flagging all of the open bugs for releases which are no longer
maintained. If this bug remains in NEEDINFO thirty (30) days from now,
we will automatically close it.
If you can reproduce this bug in a maintained Fedora version (7, 8, or
rawhide), please change this bug to the respective version and change
the status to ASSIGNED. (If you're unable to change the bug's version
or status, add a comment to the bug and someone will change it for you.)
Thanks for your help, and we apologize again that we haven't handled
these issues to this point.
The process we're following is outlined here:
We will be following the process here:
http://fedoraproject.org/wiki/BugZappers/HouseKeeping to ensure this
doesn't happen again.
Yes, still happens with current Rawhide, rpm-220.127.116.11-1.fc9.x86_64
Changing version to '9' as part of upcoming Fedora 9 GA.
More information and reason for this action is here:
Fixed upstream now, bin and sbin directories are excluded from byte compilation.
I thought this is fixed but koji as well as local rawhide build failed and still generating .pyo and .pyc in /usr/bin
Upstream != rawhide, but it is in rawhide too now.