Bug 1014583

Summary: python-pycurl: Support Python 3
Product: [Fedora] Fedora Reporter: Miro Hrončok <mhroncok>
Component: python-pycurlAssignee: Kamil Dudka <kdudka>
Status: CLOSED ERRATA QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 20CC: a.badger, frh+fedora, home, jpopelka, kdudka
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: python-pycurl-7.19.3-1.fc20 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2014-01-10 14:36:22 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On: 984711, 1029565    
Bug Blocks: 985288, 1024819    

Description Miro Hrončok 2013-10-02 11:15:49 UTC
Hi, we would like to use Python 3 on the default installation instead of Python 2 on Fedora 22.

From that perspective, your package is considered as IMPORTANT - that means, is has to be updated to Python 3, for our intention come true.

The goal here is, that at least for F22 you should provide python3- prefixed subpackage.

Please, help use update to Python 3 flawlessly.

Check if upstream already support Python 3, if yes, use it and add te support to the package.

If upstream doesn't support Python 3 yet, encourage it to do so by sending patches and offering your help.

When upstream is dead or unwilling to support Python 3, you'll need to patch this package on Fedora level. Try to avoid this as much as you can, but use it, if it's the last option.

Chances are, that you ARE the upstream. In that case, everything is easier, just do it yourself.

There is a table on wiki, that should list your package. Chances are, that you can see an upstream link that covers the problem. Anyway, please update the table with information you know.

https://fedoraproject.org/wiki/User:Churchyard/python3

I offer my help with this task, so if you have no idea, how to work on this, or it is just not your priority, don't hesitate to ask for help.

(As you've already realized, this is a bulk text, so if something is not quite exact about your package, sorry for that, just ask)

Comment 1 Toshio Ernie Kuratomi 2013-10-02 22:48:58 UTC
Note: do not follow this portion of the advice as it is against the Packaging Guidelines: "When upstream is dead or unwilling to support Python 3, you'll need to patch this package on Fedora level. Try to avoid this as much as you can, but use it, if it's the last option."

If you are in this situation, you'll essentially be forking upstream in order to produce a python3 port.  In that situation, the proper thing to do is to create a new package with the python3 port.  It would be even better to create the proper upstream infrastructure as well (new upstream scm and issue tracker) but that isn't 100% required by the guidelines.

Comment 2 Kamil Dudka 2013-10-03 10:27:05 UTC
(In reply to Toshio Ernie Kuratomi from comment #1)
> Note: do not follow this portion of the advice as it is against the
> Packaging Guidelines: "When upstream is dead or unwilling to support Python
> 3, you'll need to patch this package on Fedora level. Try to avoid this as
> much as you can, but use it, if it's the last option."

Pycurl upstream is NOT dead.  A new release of pycurl was announced last week:

http://curl.haxx.se/mail/curlpython-2013-09/0014.html

Comment 3 Kamil Dudka 2013-10-11 14:25:58 UTC
work in progress:

https://github.com/kdudka/pycurl/compare/python3

Comment 4 Miro Hrončok 2013-10-12 10:34:17 UTC
Great, thanks.

Comment 5 Miro Hrončok 2013-10-23 13:17:35 UTC
Maybe you've already used that, but juts in case you didn't know:

https://aur.archlinux.org/packages/python3-pycurl/
http://packages.ubuntu.com/quantal/python3-pycurl
https://sourceforge.net/p/pycurl/patches/12/

Comment 6 Kamil Dudka 2013-10-25 14:37:46 UTC
Thanks for the pointer!  I am trying to rebase the patch against the latest upstream version of pycurl and make it working...

Comment 7 Kamil Dudka 2013-11-04 19:23:40 UTC
Here is the result of my attempt to rebase the patch:

https://github.com/kdudka/pycurl/compare/python3

The problem is that the python2 API of pycurl relies on the PyString and PyFile types, which do not exist in python3 any more and have no drop-in replacements.

The upstream test-suite depends on cherrypy.  Unfortunately, python3-cherrypy seems to be a dead package on Fedora, waiting for a maintainer.   See bug 984711.

Comment 8 TR Bentley 2013-11-04 19:26:39 UTC
Cherrypy is being removed in F20.

If you'll note, that bug is assigned to 'orphan maintainer' - there's no one
actually maintaining that package currently. It's been dropped from Fedora
20.

Received this from Bill Nottingham.

Comment 9 Kamil Dudka 2013-11-04 19:33:44 UTC
So we need to find a new maintainer for it and get the package back to Fedora.

Comment 10 Miro Hrončok 2013-11-05 11:40:33 UTC
Taking it.

Comment 11 Kamil Dudka 2013-11-05 12:39:41 UTC
(In reply to Miro Hrončok from comment #10)
> Taking it.

That was fast :)  Thanks!

Comment 12 Kamil Dudka 2013-12-09 16:35:31 UTC
There is a new upstream patch providing the python 3 support:

http://curl.haxx.se/mail/curlpython-2013-12/0000.html

I have imported the patch into Fedora:

http://pkgs.fedoraproject.org/cgit/python-pycurl.git/tree/pycurl-7.19.0.2-pyton3.patch?h=private-kdudka-python3

... and built a scratch build with the patch applied:

http://koji.fedoraproject.org/koji/taskinfo?taskID=6272214

Comment 13 Miro Hrončok 2013-12-09 17:46:47 UTC
Great

Comment 14 Kamil Dudka 2014-01-03 14:40:46 UTC
I have updated my private branch to the latest upstream version:

http://pkgs.fedoraproject.org/cgit/python-pycurl.git/tree/pycurl-7.19.0.3-pyton3.patch?h=private-kdudka-python3

... and built a new scratch build from it:

http://koji.fedoraproject.org/koji/taskinfo?taskID=6353202

I am going to merge it into rawhide once the upstream version 7.19.3 is out:

http://curl.haxx.se/mail/curlpython-2013-12/0031.html

Comment 15 Kamil Dudka 2014-01-10 14:36:22 UTC
python-pycurl-7.19.3-2.fc21 provides the python 3 support as distributed by pycurl upstream so I am closing this bug as resolved.  From now on, please file any issues with the python3 support of pycurl as separate bugs.

Comment 16 Frederik Holden 2014-01-21 12:02:31 UTC
Would it be possible to also put this in F20?

Comment 17 Kamil Dudka 2014-01-21 12:13:50 UTC
Yes, it would.  Are you going to depend on python3-pycurl in a Fedora package?

Comment 18 Frederik Holden 2014-01-21 12:17:55 UTC
(In reply to Kamil Dudka from comment #17)
> Yes, it would.  Are you going to depend on python3-pycurl in a Fedora
> package?

No, it's just that I would like to use it for some personal scripts.

Comment 19 Fedora Update System 2014-01-21 13:53:45 UTC
python-pycurl-7.19.3-1.fc20 has been submitted as an update for Fedora 20.
https://admin.fedoraproject.org/updates/python-pycurl-7.19.3-1.fc20

Comment 20 Frederik Holden 2014-01-22 16:11:59 UTC
Thank you so much for putting it in F20, Kamil. I've been testing it today, and it's working great!

Comment 21 Kamil Dudka 2014-01-22 16:24:18 UTC
Great!  Thanks for testing it, Frederik.

Comment 22 Fedora Update System 2014-01-28 04:42:40 UTC
python-pycurl-7.19.3-1.fc20 has been pushed to the Fedora 20 stable repository.  If problems still persist, please make note of it in this bug report.