Python 3.13 support

Suggestions and discussion of future versions
Post Reply
mooninite
Member
Member
Posts: 11
Joined: Sat Aug 22, 2015 4:05 am

Python 3.13 support

Post by mooninite »

Fedora bug report:
https://bugzilla.redhat.com/show_bug.cgi?id=2308168

Short summary: Deluge GTK UI tries to import 'cgi' and it is no longer available in Python 3.13.

https://peps.python.org/pep-0594/#cgi

There are recommendations for its replacement in the above link.

https://peps.python.org/pep-0594/#deprecated-modules
User avatar
ambipro
Moderator
Moderator
Posts: 672
Joined: Thu May 19, 2022 3:33 am
Contact:

Re: Python 3.13 support

Post by ambipro »

I don't think supporting pre-release versions of python in production software is generally something that is done.

Can you not install 3.10 or 12 and create a venv to run deluge in?
mtasaka
New User
New User
Posts: 1
Joined: Tue Aug 27, 2024 10:56 pm

Re: Python 3.13 support

Post by mtasaka »

Note that as https://peps.python.org/pep-0594/#deprecated-modules says, cgi module is already marked as deprecated in python 3.11, and even with python 3.12 (on Fedora 40, python3-3.12.5-1.fc40), you can already see the warning as:


$ python --version
Python 3.12.5
$ python -Wdefault /usr/bin/deluge-gtk
....
....
/usr/lib/python3.12/site-packages/deluge/httpdownloader.py:9: DeprecationWarning: 'cgi' is deprecated and slated for removal in Python 3.13
User avatar
ambipro
Moderator
Moderator
Posts: 672
Joined: Thu May 19, 2022 3:33 am
Contact:

Re: Python 3.13 support

Post by ambipro »

We use 3.10.
mooninite
Member
Member
Posts: 11
Joined: Sat Aug 22, 2015 4:05 am

Re: Python 3.13 support

Post by mooninite »

There is a proposed patch I would like to RFC.

https://src.fedoraproject.org/fork/mtas ... oval.patch
User avatar
ambipro
Moderator
Moderator
Posts: 672
Joined: Thu May 19, 2022 3:33 am
Contact:

Re: Python 3.13 support

Post by ambipro »

Have you tested this to work without introducing a breaking change? I'd be very doubtful that until it 3.13 was finalized at least it would be merged, but you can (or if you can't I suppose I could on your behalf) make a PR to the https://github.com/deluge-torrent/deluge for Cas to consider.

Once again, we are using 3.10, so your proposed change while it make it work for you, would have to keep compatibility with our 3.7 and 3.10 tests at the very least.
mooninite
Member
Member
Posts: 11
Joined: Sat Aug 22, 2015 4:05 am

Re: Python 3.13 support

Post by mooninite »

User avatar
ambipro
Moderator
Moderator
Posts: 672
Joined: Thu May 19, 2022 3:33 am
Contact:

Re: Python 3.13 support

Post by ambipro »

Your PR is merged.
Post Reply