Note: This is a public test instance of Red Hat Bugzilla. The data contained within is a snapshot of the live data so any changes you make will not be reflected in the production Bugzilla. Email is disabled so feel free to test any aspect of the site that you want. File any problems you find or give feedback at bugzilla.redhat.com.
Bug 1551535 - ara: python3-ara-tests requires both Python 2 and Python 3
Summary: ara: python3-ara-tests requires both Python 2 and Python 3
Keywords:
Status: CLOSED WONTFIX
Alias: None
Product: Fedora
Classification: Fedora
Component: ara
Version: 29
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: David Moreau Simard
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks: PYTHON3 PYTHON3-PYTHON2
TreeView+ depends on / blocked
 
Reported: 2018-03-05 11:11 UTC by Iryna Shcherbina
Modified: 2019-07-03 21:02 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2019-07-03 21:02:09 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)

Description Iryna Shcherbina 2018-03-05 11:11:54 UTC
The python3-ara-tests (0.14.6-1.fc29) RPM requires both Python 2 and Python 3:

$ dnf --disablerepo=* --enablerepo=rawhide repoquery --requires python3-ara-tests | grep python
/usr/bin/python2
python(abi) = 3.6
...

This happened due to recently introduced shebangs mangling [0], and you might see the warnings in the build log:

> *** WARNING: mangling shebang in /usr/lib/python3.6/site-packages/ara/tests/integration/helpers/junit_check.py from #!/usr/bin/env python to #!/usr/bin/python2. This will become an ERROR, fix it manually!

The executable contains `#!/usr/bin/env python` shebang, which is forbidden by the guidelines and is automatically mangled to `#!/usr/bin/python2` during build. Please fix the shebang to be `#!/usr/bin/python3` explicitly [1] or remove the executable bit from the file if not needed.


If anything is unclear, or if you need any kind of assistance, you can
ask on IRC (#fedora-python on Freenode), or reply here. We'll be happy
to help investigating or fixing this issue!

[0] https://pagure.io/packaging-committee/issue/738#comment-490366
[1] http://python-rpm-porting.readthedocs.io/en/latest/application-modules.html#fixing-shebangs

Comment 1 Jan Kurik 2018-08-14 10:12:25 UTC
This bug appears to have been reported against 'rawhide' during the Fedora 29 development cycle.
Changing version to '29'.

Comment 2 Miro Hrončok 2019-03-17 21:53:20 UTC
David?

Comment 3 David Moreau Simard 2019-03-18 13:42:09 UTC
Thanks for pinging me Miro.

I intend on fixing this with the upcoming release of ARA 1.0 in the next few weeks.

Is that a reasonable timeline or is this blocking something at this time ?

Comment 4 Miro Hrončok 2019-03-18 14:01:00 UTC
in the next few weeks is fine. thanks.

Comment 5 Miro Hrončok 2019-05-07 10:57:07 UTC
Shall we package the 1.0.0.0a4 version in rawhide?

Comment 6 Miro Hrončok 2019-06-17 19:08:34 UTC
I see ara 1.0.0 and 1.0.1 is out \o/. Can you plese update the package?

Comment 7 David Moreau Simard 2019-06-25 14:44:46 UTC
This is still on the to-do list but I will bump the priority. Thanks.

Comment 8 Lumír Balhar 2019-06-27 07:23:47 UTC
Ara now FTBFS in Fedora rawhide because of ambiguous shebang:
BUILDSTDERR: *** ERROR: ambiguous python shebang in /usr/lib/python3.7/site-packages/ara/tests/integration/helpers/junit_check.py: #!/usr/bin/env python. Change it to python3 (or python2) explicitly.
BUILDSTDERR: *** WARNING: ./usr/lib/python3.7/site-packages/ara/db/env.py is executable but has empty or no shebang, removing executable bit
BUILDSTDERR: *** WARNING: ./usr/lib/python3.7/site-packages/ara/db/script.py.mako is executable but has empty or no shebang, removing executable bit

Comment 9 David Moreau Simard 2019-07-03 14:16:39 UTC
I've started working on updating the ara packaging to the latest version.

There are two dependencies that needs to be taken care of first:
- dynaconf isn't packaged (https://github.com/rochacbruno/dynaconf)
- python3-django-rest-framework isn't recent enough and needs to be updated (>= 3.9.1)

Comment 10 David Moreau Simard 2019-07-03 21:02:09 UTC
@Miro, Lumir, I will track the progress of the packaging update in the following bug: https://bugzilla.redhat.com/show_bug.cgi?id=1674656

Going to mark this as won't fix (it'll be fixed via 1674656)


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