[Deluge] #3476: GTKUI logs error when enabling plugin.

5 views
Skip to first unread message

Deluge

unread,
Jun 24, 2021, 8:20:38 AM6/24/21
to delug...@googlegroups.com
#3476: GTKUI logs error when enabling plugin.
----------------------------+---------------------
Reporter: mhertz | Type: bug
Status: new | Priority: minor
Milestone: needs verified | Component: Unknown
Version: 2.0.0 | Keywords:
----------------------------+---------------------
In latest python-setuptools 1.57 there's a metadata change causing the
description being added to actual payload of generated PKG-INFO and not as
header-field like previously. The metadata-spec states it CAN do this, but
always does in my tests when using this version. Whenever enabling a
plugin, then will show an error in log/terminal about 'None' not supported
as first argument, as now is in payload and not in a 'Description' header
field anymore, and per spec returns None in that case. I guess can be
changed to check for this circumstance, but I quickly just changed line
1147 in deluge/ui/gtk3/preferences.py from: '

{{{
self.builder.get_object('label_plugin_details').set_text(
plugin_info['Description']
)
}}}
Into instead:
{{{
self.builder.get_object('label_plugin_details').set_text(
plugin_info['Summary']
)
}}}
Which works for old and new PKG-INFO generated files.

Here's two examples of generated AutoAdd.egg-info/PKG-INFO files from
unmodified deluge git clone and built with 'python setup.py bdist_egg',
first with latest python-setuptools 1.57, and next with previous python-
setuptools 1.56.2(both python3, as on arch, python means python3, and btw
using latest python 3.9.5 also):
{{{
Metadata-Version: 2.1
Name: AutoAdd
Version: 1.8
Summary: Monitors folders for .torrent files.
Home-page: http://dev.deluge-torrent.org/wiki/Plugins/AutoAdd
Author: Chase Sterling, Pedro Algarvio
Author-email: chase.s...@gmail.com, pe...@algarvio.me
License: GPLv3
Platform: UNKNOWN

Monitors folders for .torrent files.

}}}
{{{
Metadata-Version: 2.1
Name: AutoAdd
Version: 1.8
Summary: Monitors folders for .torrent files.
Home-page: http://dev.deluge-torrent.org/wiki/Plugins/AutoAdd
Author: Chase Sterling, Pedro Algarvio
Author-email: chase.s...@gmail.com, pe...@algarvio.me
License: GPLv3
Description: Monitors folders for .torrent files.
Platform: UNKNOWN
}}}
Thanks in advance.

--
Ticket URL: <https://dev.deluge-torrent.org/ticket/3476>
Deluge <https://deluge-torrent.org/>
Deluge Project

Deluge

unread,
Jun 24, 2021, 8:24:08 AM6/24/21
to delug...@googlegroups.com
#3476: GTKUI logs error when enabling plugin.
---------------------+----------------------------
Reporter: mhertz | Owner:

Type: bug | Status: new
Priority: minor | Milestone: needs verified
Component: GTK UI | Version: 2.0.0
Resolution: | Keywords:
---------------------+----------------------------
Changes (by mhertz):

* component: Unknown => GTK UI


--
Ticket URL: <https://dev.deluge-torrent.org/ticket/3476#comment:1>

Deluge

unread,
Jan 12, 2022, 1:02:42 PM1/12/22
to delug...@googlegroups.com
#3476: GTKUI logs error when enabling plugin.
---------------------+-------------------
Reporter: mhertz | Owner:
Type: bug | Status: new
Priority: minor | Milestone: 2.0.6

Component: GTK UI | Version: 2.0.0
Resolution: | Keywords:
---------------------+-------------------
Changes (by Cas):

* milestone: needs verified => 2.0.6


--
Ticket URL: <https://dev.deluge-torrent.org/ticket/3476#comment:2>

Deluge

unread,
Jan 12, 2022, 2:08:41 PM1/12/22
to delug...@googlegroups.com
#3476: GTKUI logs error when enabling plugin.
---------------------+-------------------
Reporter: mhertz | Owner:
Type: bug | Status: new

Priority: minor | Milestone: 2.0.6
Component: GTK UI | Version: 2.0.0
Resolution: | Keywords:
---------------------+-------------------

Comment (by Cas):

Some links to get further details on the issue:

https://packaging.python.org/en/latest/specifications/core-
metadata/#description

> Changed in version 2.1: This field may be specified in the message body
instead.
>
> Alternatively, the distribution’s description may instead be provided in
the message body (i.e., after a completely blank line following the
headers, with no indentation or other special formatting necessary).


A related warehouse issue: https://github.com/pypa/warehouse/issues/8174

--
Ticket URL: <https://dev.deluge-torrent.org/ticket/3476#comment:3>

Deluge

unread,
Jan 12, 2022, 3:24:39 PM1/12/22
to delug...@googlegroups.com
#3476: GTKUI logs error when enabling plugin.
---------------------+-------------------
Reporter: mhertz | Owner:
Type: bug | Status: new

Priority: minor | Milestone: 2.0.6
Component: GTK UI | Version: 2.0.0
Resolution: | Keywords:
---------------------+-------------------

Comment (by Cas):

Thanks for reporting!

This needing fixing when parsing the metadata in the Pluginmanagerbase so
that all UIs would not encounter this error.

Fixed in [2351d658449] and [c3cd7f5e5cd1]

--
Ticket URL: <https://dev.deluge-torrent.org/ticket/3476#comment:4>

Deluge

unread,
Jan 12, 2022, 3:24:44 PM1/12/22
to delug...@googlegroups.com
#3476: GTKUI logs error when enabling plugin.
---------------------+--------------------
Reporter: mhertz | Owner:
Type: bug | Status: closed

Priority: minor | Milestone: 2.0.6
Component: GTK UI | Version: 2.0.0
Resolution: Fixed | Keywords:
---------------------+--------------------
Changes (by Cas):

* status: new => closed
* resolution: => Fixed


--
Ticket URL: <https://dev.deluge-torrent.org/ticket/3476#comment:5>

Reply all
Reply to author
Forward
0 new messages