Bug 1297899 - RFE Please build twisted with python3 support
RFE Please build twisted with python3 support
Status: CLOSED ERRATA
Product: Fedora
Classification: Fedora
Component: python-twisted (Show other bugs)
rawhide
All Linux
unspecified Severity medium
: ---
: ---
Assigned To: Petr Viktorin
Fedora Extras Quality Assurance
: FutureFeature
Depends On:
Blocks: 1194577 PYTHON3 PY3PATCH-PUSH 1244505
  Show dependency treegraph
 
Reported: 2016-01-12 12:50 EST by Raphael Groner
Modified: 2016-07-10 01:59 EDT (History)
7 users (show)

See Also:
Fixed In Version: python-twisted-16.1.1-2.fc25 python-twisted-16.2.0-2.fc24
Doc Type: Enhancement
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2016-07-10 01:59:31 EDT
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)
spec with python3 support (12.25 KB, text/plain)
2016-03-11 04:02 EST, Julien Enselme
no flags Details
dist-git patch to add python3 support (7.43 KB, application/mbox)
2016-05-10 08:42 EDT, Petr Viktorin
no flags Details
dist-git patch to add python3 support (7.92 KB, patch)
2016-05-10 14:02 EDT, Petr Viktorin
no flags Details | Diff

  None (edit)
Description Raphael Groner 2016-01-12 12:50:49 EST
Description of problem:
Please build a twisted package for python3 support.

Version-Release number of selected component (if applicable):
-

How reproducible:
yes

Steps to Reproduce:
1. dnf install python3-twisted
2.
3.

Actual results:
fail

Expected results:
package python3-twisted is available

Additional info:
New python packaging guidelines are simplified to build with both python2 and python3. See the provided example.
https://fedoraproject.org/wiki/Packaging:Python#Example_common_spec_file
Comment 1 Petr Viktorin 2016-02-22 06:55:13 EST
Not all of Twisted is ported to Python3 upstream, but a large part of the important functionality is, and upstream does a good job documenting their status (in twisted.python.dist3).
Enough of Twisted is ported that some dependent packages in Fedora could start switching to py3.


Please let me know if you'd like help with packaging for Python3.
Comment 2 Jan Kurik 2016-02-24 10:38:40 EST
This bug appears to have been reported against 'rawhide' during the Fedora 24 development cycle.
Changing version to '24'.

More information and reason for this action is here:
https://fedoraproject.org/wiki/Fedora_Program_Management/HouseKeeping/Fedora24#Rawhide_Rebase
Comment 3 Julien Enselme 2016-03-10 17:14:14 EST
I tried to add python3 support. I got to the spec in attachement (relies on my update proposal to twisted 15.5.0). However, I have lots of RPMS build errors with stuff listed twice and stuff installed in /usr/twisted. That will require more work:

RPM build errors:
    File listed twice: /usr/lib/python2.7/site-packages/twisted/plugins
    File listed twice: /usr/lib/python3.4/site-packages/twisted/plugins
    File listed twice: /usr/lib/python3.4/site-packages/twisted/plugins/__init__.py
    File listed twice: /usr/lib/python3.4/site-packages/twisted/plugins/__pycache__
    File listed twice: /usr/lib/python3.4/site-packages/twisted/plugins/__pycache__/__init__.cpython-34.pyc
    File listed twice: /usr/lib/python3.4/site-packages/twisted/plugins/__pycache__/__init__.cpython-34.pyo
    File listed twice: /usr/lib/python3.4/site-packages/twisted/plugins/__pycache__/twisted_trial.cpython-34.pyc
    File listed twice: /usr/lib/python3.4/site-packages/twisted/plugins/__pycache__/twisted_trial.cpython-34.pyo
    File listed twice: /usr/lib/python3.4/site-packages/twisted/plugins/__pycache__/twisted_web.cpython-34.pyc
    File listed twice: /usr/lib/python3.4/site-packages/twisted/plugins/__pycache__/twisted_web.cpython-34.pyo
    File listed twice: /usr/lib/python3.4/site-packages/twisted/plugins/twisted_trial.py
    File listed twice: /usr/lib/python3.4/site-packages/twisted/plugins/twisted_web.py
    Installed (but unpackaged) file(s) found:
   /usr/twisted/conch/topfiles/NEWS
   /usr/twisted/conch/topfiles/README
   /usr/twisted/internet/iocpreactor/build.bat
   /usr/twisted/internet/iocpreactor/iocpsupport/acceptex.pxi
   /usr/twisted/internet/iocpreactor/iocpsupport/connectex.pxi
   /usr/twisted/internet/iocpreactor/iocpsupport/iocpsupport.c
   /usr/twisted/internet/iocpreactor/iocpsupport/iocpsupport.pyx
   /usr/twisted/internet/iocpreactor/iocpsupport/winsock_pointers.c
   /usr/twisted/internet/iocpreactor/iocpsupport/winsock_pointers.h
   /usr/twisted/internet/iocpreactor/iocpsupport/wsarecv.pxi
   /usr/twisted/internet/iocpreactor/iocpsupport/wsasend.pxi
   /usr/twisted/internet/iocpreactor/notes.txt
   /usr/twisted/internet/test/fake_CAs/chain.pem
   /usr/twisted/internet/test/fake_CAs/not-a-certificate
   /usr/twisted/internet/test/fake_CAs/thing1.pem
   /usr/twisted/internet/test/fake_CAs/thing2-duplicate.pem
   /usr/twisted/internet/test/fake_CAs/thing2.pem
   /usr/twisted/internet/test/process_cli.py
   /usr/twisted/internet/test/process_cli.pyc
   /usr/twisted/internet/test/process_cli.pyo
   /usr/twisted/internet/test/process_helper.py
   /usr/twisted/internet/test/process_helper.pyc
   /usr/twisted/internet/test/process_helper.pyo
   /usr/twisted/mail/test/rfc822.message
   /usr/twisted/mail/test/server.pem
   /usr/twisted/mail/topfiles/NEWS
   /usr/twisted/mail/topfiles/README
   /usr/twisted/manhole/gladereactor.glade
   /usr/twisted/manhole/inspectro.glade
   /usr/twisted/manhole/logview.glade
   /usr/twisted/manhole/ui/gtk2manhole.glade
   /usr/twisted/names/topfiles/NEWS
   /usr/twisted/names/topfiles/README
   /usr/twisted/news/topfiles/NEWS
   /usr/twisted/news/topfiles/README
   /usr/twisted/pair/topfiles/NEWS
   /usr/twisted/pair/topfiles/README
   /usr/twisted/positioning/test/receiver.py
   /usr/twisted/positioning/test/receiver.pyc
   /usr/twisted/positioning/test/receiver.pyo
   /usr/twisted/python/_sendmsg.c
   /usr/twisted/python/test/pullpipe.py
   /usr/twisted/python/test/pullpipe.pyc
   /usr/twisted/python/test/pullpipe.pyo
   /usr/twisted/python/twisted-completion.zsh
   /usr/twisted/runner/portmap.c
   /usr/twisted/runner/topfiles/NEWS
   /usr/twisted/runner/topfiles/README
   /usr/twisted/spread/ui/login2.glade
   /usr/twisted/test/_preamble.py
   /usr/twisted/test/_preamble.pyc
   /usr/twisted/test/_preamble.pyo
   /usr/twisted/test/plugin_basic.py
   /usr/twisted/test/plugin_basic.pyc
   /usr/twisted/test/plugin_basic.pyo
   /usr/twisted/test/plugin_extra1.py
   /usr/twisted/test/plugin_extra1.pyc
   /usr/twisted/test/plugin_extra1.pyo
   /usr/twisted/test/plugin_extra2.py
   /usr/twisted/test/plugin_extra2.pyc
   /usr/twisted/test/plugin_extra2.pyo
   /usr/twisted/test/process_cmdline.py
   /usr/twisted/test/process_cmdline.pyc
   /usr/twisted/test/process_cmdline.pyo
   /usr/twisted/test/process_echoer.py
   /usr/twisted/test/process_echoer.pyc
   /usr/twisted/test/process_echoer.pyo
   /usr/twisted/test/process_fds.py
   /usr/twisted/test/process_fds.pyc
   /usr/twisted/test/process_fds.pyo
   /usr/twisted/test/process_linger.py
   /usr/twisted/test/process_linger.pyc
   /usr/twisted/test/process_linger.pyo
   /usr/twisted/test/process_reader.py
   /usr/twisted/test/process_reader.pyc
   /usr/twisted/test/process_reader.pyo
   /usr/twisted/test/process_signal.py
   /usr/twisted/test/process_signal.pyc
   /usr/twisted/test/process_signal.pyo
   /usr/twisted/test/process_stdinreader.py
   /usr/twisted/test/process_stdinreader.pyc
   /usr/twisted/test/process_stdinreader.pyo
   /usr/twisted/test/process_tester.py
   /usr/twisted/test/process_tester.pyc
   /usr/twisted/test/process_tester.pyo
   /usr/twisted/test/process_tty.py
   /usr/twisted/test/process_tty.pyc
   /usr/twisted/test/process_tty.pyo
   /usr/twisted/test/process_twisted.py
   /usr/twisted/test/process_twisted.pyc
   /usr/twisted/test/process_twisted.pyo
   /usr/twisted/test/raiser.c
   /usr/twisted/test/raiser.pyx
   /usr/twisted/test/server.pem
   /usr/twisted/test/stdio_test_consumer.py
   /usr/twisted/test/stdio_test_consumer.pyc
   /usr/twisted/test/stdio_test_consumer.pyo
   /usr/twisted/test/stdio_test_halfclose.py
   /usr/twisted/test/stdio_test_halfclose.pyc
   /usr/twisted/test/stdio_test_halfclose.pyo
   /usr/twisted/test/stdio_test_hostpeer.py
   /usr/twisted/test/stdio_test_hostpeer.pyc
   /usr/twisted/test/stdio_test_hostpeer.pyo
   /usr/twisted/test/stdio_test_lastwrite.py
   /usr/twisted/test/stdio_test_lastwrite.pyc
   /usr/twisted/test/stdio_test_lastwrite.pyo
   /usr/twisted/test/stdio_test_loseconn.py
   /usr/twisted/test/stdio_test_loseconn.pyc
   /usr/twisted/test/stdio_test_loseconn.pyo
   /usr/twisted/test/stdio_test_producer.py
   /usr/twisted/test/stdio_test_producer.pyc
   /usr/twisted/test/stdio_test_producer.pyo
   /usr/twisted/test/stdio_test_write.py
   /usr/twisted/test/stdio_test_write.pyc
   /usr/twisted/test/stdio_test_write.pyo
   /usr/twisted/test/stdio_test_writeseq.py
   /usr/twisted/test/stdio_test_writeseq.pyc
   /usr/twisted/test/stdio_test_writeseq.pyo
   /usr/twisted/topfiles/CREDITS
   /usr/twisted/topfiles/ChangeLog.Old
   /usr/twisted/topfiles/NEWS
   /usr/twisted/topfiles/README
   /usr/twisted/trial/test/mockdoctest.py
   /usr/twisted/trial/test/mockdoctest.pyc
   /usr/twisted/trial/test/mockdoctest.pyo
   /usr/twisted/trial/test/moduleself.py
   /usr/twisted/trial/test/moduleself.pyc
   /usr/twisted/trial/test/moduleself.pyo
   /usr/twisted/trial/test/moduletest.py
   /usr/twisted/trial/test/moduletest.pyc
   /usr/twisted/trial/test/moduletest.pyo
   /usr/twisted/trial/test/novars.py
   /usr/twisted/trial/test/novars.pyc
   /usr/twisted/trial/test/novars.pyo
   /usr/twisted/trial/test/ordertests.py
   /usr/twisted/trial/test/ordertests.pyc
   /usr/twisted/trial/test/ordertests.pyo
   /usr/twisted/trial/test/packages.py
   /usr/twisted/trial/test/packages.pyc
   /usr/twisted/trial/test/packages.pyo
   /usr/twisted/trial/test/sample.py
   /usr/twisted/trial/test/sample.pyc
   /usr/twisted/trial/test/sample.pyo
   /usr/twisted/trial/test/scripttest.py
   /usr/twisted/trial/test/scripttest.pyc
   /usr/twisted/trial/test/scripttest.pyo
   /usr/twisted/web/topfiles/NEWS
   /usr/twisted/web/topfiles/README
   /usr/twisted/words/im/instancemessenger.glade
   /usr/twisted/words/topfiles/NEWS
   /usr/twisted/words/topfiles/README
   /usr/twisted/words/xish/xpathparser.g
Comment 4 Raphael Groner 2016-03-11 03:47:29 EST
What attachment do we talk about? There's none in this bug (yet).

For the duplicated files listed: Just use %{python2_sitelib}/* and %{python3_sitelib}/* as in the example common spec file of the guidelines wiki page.

I think /usr/twisted/ must be changed in %{_datadir}/%{name}/ and I guess those test folders can be excluded from the package. Please poke upstream.
Comment 5 Julien Enselme 2016-03-11 04:02 EST
Created attachment 1135156 [details]
spec with python3 support
Comment 6 Julien Enselme 2016-03-11 04:04:01 EST
> What attachment do we talk about? There's none in this bug (yet).

I forgot to add it, sorry.

> I think /usr/twisted/ must be changed in %{_datadir}/%{name}/ and I guess those test folders can be excluded from the package. Please poke upstream.

Probably yes. I'll try to continue my work today.
Comment 7 Raphael Groner 2016-03-11 04:38:09 EST
Sorry, I mean %{_datadir}/%{srcname}/ of course, to be compliant with the example common spec file of the wiki page.
Comment 9 Petr Viktorin 2016-05-10 08:42:41 EDT
I've polished the patch a bit. Attaching a patch for dist-git.

Koji scratch build: http://koji.fedoraproject.org/koji/taskinfo?taskID=13994666
Comment 10 Petr Viktorin 2016-05-10 08:42 EDT
Created attachment 1155756 [details]
dist-git patch to add python3 support
Comment 11 Petr Viktorin 2016-05-10 14:02 EDT
Created attachment 1155825 [details]
dist-git patch to add python3 support

Scratch that, I forgot to take care of Obsoletes & co.

Here is an updated patch.

Koji scratch build: http://koji.fedoraproject.org/koji/taskinfo?taskID=13997909
Comment 12 Tomas Orsava 2016-05-11 09:12:07 EDT
I reviewed Petr's patch and it looks good.

As the assignee—Thomas—hasn't responded in several months, I hope he won't mind if the patch is pushed for him.
Comment 13 Fedora Update System 2016-06-26 18:02:23 EDT
python-twisted-16.2.0-2.fc24 has been submitted as an update to Fedora 24. https://bodhi.fedoraproject.org/updates/FEDORA-2016-1c2cd11eac
Comment 14 Fedora Update System 2016-06-26 18:11:23 EDT
python-twisted-16.2.0-2.fc23 has been submitted as an update to Fedora 23. https://bodhi.fedoraproject.org/updates/FEDORA-2016-fd1d324745
Comment 15 Fedora Update System 2016-06-27 20:27:05 EDT
python-twisted-16.2.0-2.fc23 has been pushed to the Fedora 23 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2016-fd1d324745
Comment 16 Fedora Update System 2016-06-28 00:25:14 EDT
python-twisted-16.2.0-2.fc24 has been pushed to the Fedora 24 testing repository. If problems still persist, please make note of it in this bug report.
See https://fedoraproject.org/wiki/QA:Updates_Testing for
instructions on how to install test updates.
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2016-1c2cd11eac
Comment 17 Fedora Update System 2016-07-09 19:54:12 EDT
python-twisted-16.2.0-2.fc23 has been pushed to the Fedora 23 stable repository. If problems still persist, please make note of it in this bug report.
Comment 18 Fedora Update System 2016-07-10 01:59:24 EDT
python-twisted-16.2.0-2.fc24 has been pushed to the Fedora 24 stable repository. If problems still persist, please make note of it in this bug report.

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