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 1313024 - antlr: Provide a Python 3 subpackage
Summary: antlr: Provide a Python 3 subpackage
Keywords:
Status: CLOSED NOTABUG
Alias: None
Product: Fedora
Classification: Fedora
Component: antlr
Version: rawhide
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: gil cattaneo
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks: PYTHON3
TreeView+ depends on / blocked
 
Reported: 2016-02-29 18:39 UTC by Tomas Orsava
Modified: 2016-03-01 10:06 UTC (History)
5 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2016-02-29 19:33:22 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)

Description Tomas Orsava 2016-02-29 18:39:18 UTC
Upstream, this software supports Python 3. Please provide a Python 3
package for Fedora.


According to the Python packaging guidelines [0], software must be
packaged for Python 3 if upstream supports it.
The guidelines give detailed information on how to do this, and even
provide an example spec file [1].

The current best practice is to provide subpackages for the two Python
versions (called "Common SRPM" in the guidelines). Alternatively, if
nothing depends on your Python2 package, you can just switch to Python 3
entirely.

It's ok to do this in Rawhide only, however, it would be greatly
appreciated if you could push it to Fedora 24 as well.


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


[0] https://fedoraproject.org/wiki/Packaging:Python
[1] https://fedoraproject.org/wiki/Packaging:Python#Example_common_spec_file

Comment 1 gil cattaneo 2016-02-29 19:15:16 UTC
(In reply to T. Orsava from comment #0)
> Upstream, this software supports Python 3. Please provide a Python 3
> package for Fedora.

any idea?

running install
running install_lib
creating /builddir/build/BUILDROOT/antlr-2.7.7-41.fc25.x86_64/usr/lib/python3.5
creating /builddir/build/BUILDROOT/antlr-2.7.7-41.fc25.x86_64/usr/lib/python3.5/site-packages
creating /builddir/build/BUILDROOT/antlr-2.7.7-41.fc25.x86_64/usr/lib/python3.5/site-packages/antlr
copying build/lib/antlr/__init__.py -> /builddir/build/BUILDROOT/antlr-2.7.7-41.fc25.x86_64/usr/lib/python3.5/site-packages/antlr
copying build/lib/antlr/antlr.py -> /builddir/build/BUILDROOT/antlr-2.7.7-41.fc25.x86_64/usr/lib/python3.5/site-packages/antlr
byte-compiling /builddir/build/BUILDROOT/antlr-2.7.7-41.fc25.x86_64/usr/lib/python3.5/site-packages/antlr/__init__.py to __init__.cpython-35.pyc
byte-compiling /builddir/build/BUILDROOT/antlr-2.7.7-41.fc25.x86_64/usr/lib/python3.5/site-packages/antlr/antlr.py to antlr.cpython-35.pyc
writing byte-compilation script '/tmp/tmpemgyo85t.py'
/usr/bin/python3 -O /tmp/tmpemgyo85t.py
  File "/usr/lib/python3.5/site-packages/antlr/antlr.py", line 48
    print "error: ", fmt % tuple(args)
                  ^
SyntaxError: invalid syntax
removing /tmp/tmpemgyo85t.py
running install_egg_info
Writing /builddir/build/BUILDROOT/antlr-2.7.7-41.fc25.x86_64/usr/lib/python3.5/site-packages/antlr-2.7.5RC1-py3.5.egg-info
  File "/usr/lib/python3.5/site-packages/antlr/antlr.py", line 48
    print "error: ", fmt % tuple(args)
                  ^
SyntaxError: invalid syntax
+ cd ../..
+ /usr/lib/rpm/check-buildroot
+ /usr/lib/rpm/brp-compress
+ /usr/lib/rpm/brp-strip /usr/bin/strip
+ /usr/lib/rpm/brp-strip-comment-note /usr/bin/strip /usr/bin/objdump
+ /usr/lib/rpm/brp-strip-static-archive /usr/bin/strip
+ /usr/lib/rpm/brp-python-bytecompile /usr/bin/python 1
Bytecompiling .py files below /builddir/build/BUILDROOT/antlr-2.7.7-41.fc25.x86_64/usr/lib/python3.5 using /usr/bin/python3.5
*** Error compiling '/builddir/build/BUILDROOT/antlr-2.7.7-41.fc25.x86_64/usr/lib/python3.5/site-packages/antlr/antlr.py'...
  File "/usr/lib/python3.5/antlr.py", line 48
    print "error: ", fmt % tuple(args)
                  ^
SyntaxError: invalid syntax
RPM build errors:
error: Bad exit status from /var/tmp/rpm-tmp.G4zpsw (%install)

Comment 2 gil cattaneo 2016-02-29 19:15:36 UTC
Task info: http://koji.fedoraproject.org/koji/taskinfo?taskID=13179801

Comment 3 gil cattaneo 2016-02-29 19:33:22 UTC
Seem do not support Py3, then see https://fedoraproject.org/wiki/Packaging:Python#Python_Version_Support
Before open a bug or theorize some compatibility, please, connect the brain :)

Comment 4 Petr Viktorin 2016-03-01 09:43:29 UTC
Can you please update the upstream URL for the packages?
Currently upstream link (shown for example at https://admin.fedoraproject.org/pkgdb/package/rpms/antlr/) goes to http://www.antlr.org/ (ANTLR 4), which does support Python 3.

The link for this package should be http://www.antlr2.org/

Comment 5 gil cattaneo 2016-03-01 09:54:21 UTC
(In reply to Petr Viktorin from comment #4)
> Can you please update the upstream URL for the packages?
> Currently upstream link (shown for example at
> https://admin.fedoraproject.org/pkgdb/package/rpms/antlr/) goes to
> http://www.antlr.org/ (ANTLR 4), which does support Python 3.
> 
> The link for this package should be http://www.antlr2.org/

antlr4 packages is already available in Fedora, but do not provides the "Python runtime support". If you want this feature, please, open a bug in for the right component.
Regards

Comment 6 Petr Viktorin 2016-03-01 09:57:00 UTC
(In reply to gil cattaneo from comment #5)
> (In reply to Petr Viktorin from comment #4)
> > Can you please update the upstream URL for the packages?
> > Currently upstream link (shown for example at
> > https://admin.fedoraproject.org/pkgdb/package/rpms/antlr/) goes to
> > http://www.antlr.org/ (ANTLR 4), which does support Python 3.
> > 
> > The link for this package should be http://www.antlr2.org/
> 
> antlr4 packages is already available in Fedora, but do not provides the
> "Python runtime support". If you want this feature, please, open a bug in
> for the right component.

That's the plan.


Meanwhile, can you please make the antlr 2 package's URL link to antlr 2, and not antlr4?
Should I open a new bug for this as well?

Comment 7 gil cattaneo 2016-03-01 09:59:13 UTC
(In reply to Petr Viktorin from comment #6)
> (In reply to gil cattaneo from comment #5)
> > (In reply to Petr Viktorin from comment #4)
> > > Can you please update the upstream URL for the packages?
> > > Currently upstream link (shown for example at
> > > https://admin.fedoraproject.org/pkgdb/package/rpms/antlr/) goes to
> > > http://www.antlr.org/ (ANTLR 4), which does support Python 3.
> > > 
> > > The link for this package should be http://www.antlr2.org/
> > 
> > antlr4 packages is already available in Fedora, but do not provides the
> > "Python runtime support". If you want this feature, please, open a bug in
> > for the right component.
> 
> That's the plan.
> 
https://admin.fedoraproject.org/pkgdb/package/rpms/antlr4/
> 
> Meanwhile, can you please make the antlr 2 package's URL link to antlr 2,
> and not antlr4?
Why also the antlr3 and antlr32 have the same URL ...
> Should I open a new bug for this as well?
yes, sure

Comment 8 gil cattaneo 2016-03-01 10:03:31 UTC
if is for the URL the bug is invalid because is the same

Comment 9 Petr Viktorin 2016-03-01 10:06:46 UTC
(In reply to gil cattaneo from comment #7)
> (In reply to Petr Viktorin from comment #6)
> > (In reply to gil cattaneo from comment #5)
> > > (In reply to Petr Viktorin from comment #4)
> > > > Can you please update the upstream URL for the packages?
> > > > Currently upstream link (shown for example at
> > > > https://admin.fedoraproject.org/pkgdb/package/rpms/antlr/) goes to
> > > > http://www.antlr.org/ (ANTLR 4), which does support Python 3.
> > > > 
> > > > The link for this package should be http://www.antlr2.org/
> > > 
> > > antlr4 packages is already available in Fedora, but do not provides the
> > > "Python runtime support". If you want this feature, please, open a bug in
> > > for the right component.
> > 
> > That's the plan.
> > 
> https://admin.fedoraproject.org/pkgdb/package/rpms/antlr4/
> > 
> > Meanwhile, can you please make the antlr 2 package's URL link to antlr 2,
> > and not antlr4?
> Why also the antlr3 and antlr32 have the same URL ...

antlr3 and anrlt32 link to  http://www.antlr3.org/ (see the "upstream" link at https://admin.fedoraproject.org/pkgdb/package/rpms/antlr3/ and https://admin.fedoraproject.org/pkgdb/package/rpms/antlr32/)

> > Should I open a new bug for this as well?
> yes, sure

https://bugzilla.redhat.com/show_bug.cgi?id=1313275


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