Opened 6 years ago

Closed 6 years ago

#2730 closed bug (Fixed)

dev versions of Deluge not runs with latest setuptools

Reported by: barmalej2 Owned by: Cas
Priority: minor Milestone: 1.3.12
Component: Core Version: 1.3-stable
Keywords: Cc:

Description

I am trying to run deluge 1.3.11.dev0 (taken from git 1.3 stable branch) with libtorrent-1.0.3 on Zyxel NAS (NSA310 kernel-2.6.31.8, armv5tel GNU/Linux, uClibc based system).
If I upgrade setuptools to latest 11.3.1 version, deluged refuses to run:

[ERROR ] 21:30:53 main:237 invalid literal for int() with base 10: 'dev0'
Traceback (most recent call last):
File "/ffp/lib/python2.7/site-packages/deluge/main.py", line 230, in start_daemon
Daemon(options, args)
File "/ffp/lib/python2.7/site-packages/deluge/core/daemon.py", line 138, in __init__
self.core = Core(listen_interface=listen_interface)
File "/ffp/lib/python2.7/site-packages/deluge/core/core.py", line 83, in __init__
version = [int(value.split("-")[0]) for value in deluge.common.get_version().split(".")]
ValueError: invalid literal for int() with base 10: 'dev0'

If revert back to older setuptools version 7.0, deluged runs without problem. I have zero python programming knowledge, so looked at how DJango resolved similar issue: https://github.com/django/django/commit/1739ae9edc6e6c07ca20cad36dd15316f18f3f8e

Changing row:

version = [int(value.split("-")[0]) for value in deluge.common.get_version().split(".")]

to

version = [int(value.split("-")[0]) for value in deluge.common.get_version().split(".") if value.isdigit()]

in core.py, lets me run deluged again with latest setuptools. Don't know, if that is suitable way to solve issue, but it works. I hope to draw attention of deluge devs (Cas potentially) at this small problem.

Best rgds, b2

Change History (2)

comment:1 Changed 6 years ago by Cas

  • Milestone changed from 1.3.x to 1.3.12
  • Owner set to Cas
  • Status changed from new to assigned

comment:2 Changed 6 years ago by Cas

  • Resolution set to Fixed
  • Status changed from assigned to closed

Fixed in 1.3-stable: [630aa730d52f5]

Note: See TracTickets for help on using tickets.