Bug 1737908 - autodownloader depends on Python 2
Summary: autodownloader depends on Python 2
Keywords:
Status: CLOSED RAWHIDE
Alias: None
Product: Fedora
Classification: Fedora
Component: autodownloader
Version: 31
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Hans de Goede
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks: F31_PY2REMOVAL
TreeView+ depends on / blocked
 
Reported: 2019-08-06 11:30 UTC by Lumír Balhar
Modified: 2019-11-04 20:52 UTC (History)
5 users (show)

Fixed In Version: autodownloader-0.4.0-1.fc32
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2019-11-04 20:51:15 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)

Description Lumír Balhar 2019-08-06 11:30:45 UTC
Python 2.7 will reach end-of-life in January 2020, over 9 years after it was released. This falls within the Fedora 31 lifetime.
Packages that depend on Python 2 are being switched to Python 3 or removed from Fedora: https://fedoraproject.org/wiki/Changes/F31_Mass_Python_2_Package_Removal#Information_on_Remaining_Packages
Python 2 will be retired in Fedora 32: https://fedoraproject.org/wiki/Changes/RetirePython2

To help planning, we'd like to know the plans for autodownloader's future. Specifically:


- What is the reason for the Python2 dependency? (Is it software written in Python, or does it just provide Python bindings, or use Python in the build system or test runner?) 

- What are the upstream/community plans/timelines regarding Python 3?

- What is the guidance for porting to Python 3? (Assuming that there is someone who generally knows how to port to Python 3, but doesn't know anything about the particular package, what are the next steps to take?)


This bug is filed semi-automatically, and might not have all the context specific to autodownloader.
If you need anything from us, or something is unclear, please mention it here.

Thank you.

Comment 1 Hans de Goede 2019-08-06 20:17:23 UTC
(In reply to Lumír Balhar from comment #0)
> - What is the reason for the Python2 dependency? (Is it software written in
> Python, or does it just provide Python bindings, or use Python in the build
> system or test runner?) 

autodownloader is a small app written in python.

> - What are the upstream/community plans/timelines regarding Python 3?

I guess I am upstream, I have put porting this to python3 on my (too long) todo list.

> - What is the guidance for porting to Python 3? (Assuming that there is
> someone who generally knows how to port to Python 3, but doesn't know
> anything about the particular package, what are the next steps to take?)

If someone can help that would be great, there is no specific guidance I can give you, but the app is so simple that none is needed I think.

Comment 2 Ben Cotton 2019-08-13 17:08:20 UTC
This bug appears to have been reported against 'rawhide' during the Fedora 31 development cycle.
Changing version to '31'.

Comment 3 Ben Cotton 2019-08-13 17:35:32 UTC
This bug appears to have been reported against 'rawhide' during the Fedora 31 development cycle.
Changing version to 31.

Comment 4 Lumír Balhar 2019-08-14 08:12:26 UTC
Some more info:
- 10 non-python packages depend on it
- It uses GTK (+ Glade) so it has to be ported to a newer version of these libraries
- ~720 lines of code with a lot of comments
- no tests but we can use the example config file and also config files from dependant packages to test it

Will see whether I'll have time to help you with that.

Comment 5 Lumír Balhar 2019-08-21 13:44:51 UTC
Just FYI:

The current plan is to remove packages with dependency on Python 2 from Fedora 32 in the middle of November 2019. If you want to keep your package in Fedora after that date and you cannot port it to Python 3 yet, you need to request a FESCo exception for the package and all its Python 2 dependencies (even transitive) [1]. If you don't want to maintain it anymore, please orphan the package.

If you're considering filing the exception request, let us know. We can help (for example, we can help find all the dependencies).

[1] https://fedoraproject.org/wiki/Changes/RetirePython2#FESCo_exceptions

Comment 6 Vít Ondruch 2019-09-02 11:49:38 UTC
Just FTR, it appears this tool is used by games based on quake3 engine. It would be shame to loose these games due to this small tool.

Comment 7 Lumír Balhar 2019-09-16 08:19:08 UTC
I've tried to start with porting this tool to Python 3 and newer GTK but I am not experienced enough in GUI applications development to do that. Moreover, it seems that the .glade file is too old to be loaded in the newest Glade UI designer and it also seems that the original developers used GladeGen tool which is also ancient and basically cannot be found.

I think that it might be better to rewrite this tool's GUI part from scratch and use just the configuration parser and downloader.

What do you think about it?

Comment 8 Hans de Goede 2019-09-16 08:25:55 UTC
Thank you for looking into this.

Re-doing the UI is fine with me.

Comment 9 Lumír Balhar 2019-09-16 08:59:53 UTC
Is there anybody who would like to do that?

Comment 10 Hans de Goede 2019-09-17 06:32:26 UTC
Hmm, it seems unfortunate that pygtk2 does not have a python3 version, now moving to python3 also forces a rewrite of the UI bits.

I've looking into this / fixing this on my todo list. I hope to get this done for F32, but I can could certainly use some help with this.

Comment 11 Miro Hrončok 2019-10-15 10:38:39 UTC
I've requested an exception to buy you more time: https://pagure.io/fesco/issue/2248

Comment 12 Hans de Goede 2019-10-16 09:07:27 UTC
(In reply to Miro Hrončok from comment #11)
> I've requested an exception to buy you more time:
> https://pagure.io/fesco/issue/2248

Great, thank you.

Comment 13 Lumír Balhar 2019-11-04 15:33:23 UTC
I've managed to convert the Glade file to GTK3 Builder UI file and make this tool Python 2/3 compatible.

It seems to work with all Fedora autodlrc files from dependant packages with both Pythons in rawhide.

My fork: https://github.com/frenzymadness/AutoDownloader (see the note in the readme file)
Specfile PR: https://src.fedoraproject.org/rpms/autodownloader/pull-request/1

It's not using Glade anymore so it would be nice to refactor this tool a little bit but it works and does not depend on Python 2 and that counts :)

Because I'll maintain the fork, feel free to make me a co-maintainer of this package as well. Let me also know about any bug or incompatibility you find.

Comment 14 Pete Walter 2019-11-04 20:51:15 UTC
Nice, thanks! I've merged the pull request and added you to the project as a co-maintainer.

Comment 15 Hans de Goede 2019-11-04 20:52:54 UTC
Yes very nice, I was planning on merging this myself, but Pete beat me to it (which is even better).

Thank you very much for doing this!


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