As mentioned in the Summary, deluge-console crashes with the following
traceback:
{{{
Traceback (most recent call last):
File "/usr/bin/deluge-console", line 33, in <module>
sys.exit(load_entry_point('deluge==2.0.5', 'console_scripts', 'deluge-
console')())
File "/usr/lib/python3.10/site-packages/deluge/ui/console/__init__.py",
line 19, in start
Console().start()
File "/usr/lib/python3.10/site-packages/deluge/ui/console/console.py",
line 164, in start
return deluge.common.run_profiled(
File "/usr/lib/python3.10/site-packages/deluge/common.py", line 1351, in
run_profiled
return func(*args)
File "/usr/lib/python3.10/site-packages/deluge/ui/console/console.py",
line 159, in run
return c.start_ui()
File "/usr/lib/python3.10/site-packages/deluge/ui/console/main.py", line
164, in start_ui
wrapper(self.run)
File "/usr/lib/python3.10/curses/__init__.py", line 94, in
wrapper
return func(stdscr, *args, **kwds)
File "/usr/lib/python3.10/site-packages/deluge/ui/console/main.py", line
252, in run
colors.init_colors()
File "/usr/lib/python3.10/site-
packages/deluge/ui/console/utils/colors.py", line 110, in init_colors
counter = define_pair(counter, 'white', 'grey', curses.COLOR_WHITE,
241)
File "/usr/lib/python3.10/site-
packages/deluge/ui/console/utils/colors.py", line 91, in define_pair
curses.init_pair(counter, fg, bg)
ValueError: Color number is greater than COLORS-1 (7).
}}}
A quick change in line [https://git.deluge-
torrent.org/deluge/tree/deluge/ui/console/utils/colors.py#n94 94] of
colors.py from:
{{{ except curses.error as ex: }}}
to:
{{{ except (curses.error, ValueError) as ex: }}}
Allows the program to continue and works as expected but you are welcome
to dig into the root cause of the actual issue.
--
Ticket URL: <https://dev.deluge-torrent.org/ticket/3518>
Deluge <https://deluge-torrent.org/>
Deluge Project
* status: new => closed
* resolution: => Fixed
* milestone: needs verified => 2.1.0
Comment:
Thanks for reporting, looks like a change in Python 3.10 and fixed via
[cd63efd93]
--
Ticket URL: <https://dev.deluge-torrent.org/ticket/3518#comment:1>