Hi all,
as a new Fedora Python maintainer, I have set myself a goal of moving Fedora to 
Python 3 as a default. This is going to be a multirelease effort that is going 
to affect lots of Fedora parts. Since we will need to switch default package 
manager from Yum to DNF (which is supposed to work with Python 3), we will need 
to wait for that. I've been told that DNF should be default in F22, so that's 
my target, too. That should also give everyone else plenty of time to work on 
other essential packages to make this happen.

Here is my analysis/proposal:
Before switching, we need to make sure that everything "important" (*) is 
Python 3 compatible. There are three steps I see in this transition:
1) Getting rid of Python 2 in mock minimal buildroot.
2) Porting Anaconda to Python 3.
3) Making all livecd packages depend on Python 3 by default (and eventually 
getting rid of Python 2 from livecd) - this will also require switching from 
Yum to DNF as a default, that is supposed to support Python 3.
( 4) Making as much of the remaining packages Python 3 compatible )

In past few days, I've been going through packages that are part of the above 
steps. I have reported numerous bugs asking upstream and/or Fedora maintainers 
for help with porting to Python 3. We have some spare cycles in our small 
Python packaging team, that we will try to provide to whoever needs them most, 
but we're limited and we'll have to rely on the upstreams to do most of the 
work. I'm attaching a document with list of packages that need porting with 
some notes/links to opened bugs. Sometime soon, I'll open a tracking bug for 
this, so that everyone can see where we are quickly.
(*) I call these "important" packages (in terms of being important for the 
Python 3 switch)

>From packaging point of view, this will probably require:
1) Renaming python package to python2
2) Renaming python3 package to python
3) Switching the %{?with_python3} conditionals in specfiles to %{?with_python2} 
(we will probably create a script to automate this, at least partially)


FAQ:
Q: Why do we need to switch to Python 3?
A: Because Python 2 is old, slower, less pythonic, doesn't get any more 
functionality and it won't be that long before the official upstream support 
ends [1]

Q: How do I port to Python 3?
A: There are tons of tutorials and howtos about porting and the differencies in 
general. E.g. [2] (general), [3] (c-extensions)

Q: What about Python 2?
A: We will maintain that at least as long as upstream supports it. After that, 
I'd prefer dropping it, but since I know there will be people wanting to keep 
it around, I'll gladly give the maintenance to someone else.


I'll be glad to answer all your questions and discuss the above points. Nothing 
is set into stone and I'd love to hear your ideas and comments.
Thanks for reading this through!
Slavek.

-- 
Regards,
Bohuslav "Slavek" Kabrda.

[1] http://www.python.org/dev/peps/pep-0373/
[2] http://docs.python.org/dev/howto/pyporting.html
[3] http://docs.python.org/3/howto/cporting.html
minimal buildroot:
- gdb - OK?: http://www.gnu.org/software/gdb/download/ANNOUNCEMENT (since gdb 
itself depends on this, we will just need to switch to building with Python 3)

anaconda:
- (anaconda itself and all of its subpackages)
- anaconda-yum-plugins - XXX requires yum => would require the same 
functionality from dnf
- authconfig - TODO - https://bugzilla.redhat.com/show_bug.cgi?id=984907
             - python-newt - TODO - 
https://bugzilla.redhat.com/show_bug.cgi?id=963839
             - pygtk2 - XXX - not for Python 3, will need to port to PyGObject
- firewalld - TODO - https://fedorahosted.org/firewalld/ticket/9
            - python-slip - TODO - https://fedorahosted.org/python-slip/ticket/1
- iscsi-initiator-utils - TODO - 
https://bugzilla.redhat.com/show_bug.cgi?id=985321
- langtable-python - TODO - https://bugzilla.redhat.com/show_bug.cgi?id=985317
- libuser-python - TODO - https://fedorahosted.org/libuser/ticket/13
- pykickstart - TODO - https://bugzilla.redhat.com/show_bug.cgi?id=985310
- pyparted - TODO - https://bugzilla.redhat.com/show_bug.cgi?id=985308
- python-IPy - TODO - https://bugzilla.redhat.com/show_bug.cgi?id=985307
- python-babel - TODO - http://babel.edgewall.org/ticket/209
- python-blivet - TODO - https://bugzilla.redhat.com/show_bug.cgi?id=985301
- python-cryptsetup - TODO - https://bugzilla.redhat.com/show_bug.cgi?id=985297
- python-meh - TODO - https://bugzilla.redhat.com/show_bug.cgi?id=985294
- python-nss - TODO - https://bugzilla.redhat.com/show_bug.cgi?id=985290
- python-pwquality - TODO - https://fedorahosted.org/libpwquality/ticket/2
- python-pyblock - TODO - https://bugzilla.redhat.com/show_bug.cgi?id=985295
- python-urlgrabber - TODO - https://bugzilla.redhat.com/show_bug.cgi?id=985288
                    - python-pycurl - TODO - 
https://github.com/p/pycurl/pull/28 (is this the official upstream?)
livecd (without anaconda):
- rpm-python - TODO - https://bugzilla.redhat.com/show_bug.cgi?id=531543 (patch 
finished, not built in koji yet)
- yum - replaced by dnf in Fedora 22 (?)
- dnf - python-hawkey - TODO - part of dnf effort
      - python-iniparse - TODO - last version released in 2010, not Python 3 
compatible, but looks fairly simple to patch
      - python-librepo - TODO - https://github.com/Tojaj/librepo/issues/17

- PackageKit - https://bugs.freedesktop.org/show_bug.cgi?id=66992
- PackageKit-yum-plugin - XXX requires yum => would require the same 
functionality from dnf
- gupnp - TODO - https://bugzilla.gnome.org/show_bug.cgi?id=704383
- libpurple - TODO - https://developer.pidgin.im/ticket/15695
- nfs-utils -TODO - https://bugzilla.redhat.com/show_bug.cgi?id=985325
- pygobject - not for Python 3, will be replaced by python3-gobject
- pygkt2 - not for Python 3, will be replaced by python3-gobject
- python-paste - 
https://bitbucket.org/ianb/pastescript/issue/7/make-support-py3k
- rhythmbox - https://bugzilla.gnome.org/show_bug.cgi?id=686450
- samba - https://bugzilla.samba.org/show_bug.cgi?id=10028
- speech-dispatcher - TODO - already supports Python 3, just needs to convert 
shebang
- sos - TODO - https://github.com/sosreport/sosreport/issues/100
      - libxml2-python - TODO - last version in 2004?; but sos could probably 
switch to python3-lxml
- sssd python-sssdconfig - TODO - https://fedorahosted.org/sssd/ticket/2017
-- 
devel mailing list
devel@lists.fedoraproject.org
https://admin.fedoraproject.org/mailman/listinfo/devel

Reply via email to