OK... I tested it. It works now, but still one problem: if the torrent file name contains spaces (and possibly other weird characters) it won't be recognized. This is the log
Code: Select all
http://0.0.0.0:2507/
Pickling state...
Pickling state...
Raising error: Handle not found.
Raising error: Handle not found.
write: /home/radu/some +file+ new.zip.torrent
Raising error:
Error: ''
Traceback (most recent call last):
File "/usr/share/deluge/plugins/WebUi/webpy022/webapi.py", line 304, in wsgifunc
result = func()
File "/usr/share/deluge/plugins/WebUi/webpy022/request.py", line 131, in <lambda>
func = lambda: handle(inp, fvars)
File "/usr/share/deluge/plugins/WebUi/webpy022/request.py", line 61, in handle
return tocall(*([x and urllib.unquote(x) for x in args] + fna))
File "/usr/share/deluge/plugins/WebUi/webserver_framework.py", line 143, in deco
return func(self, name) #ok, continue..
File "/usr/share/deluge/plugins/WebUi/deluge_webserver.py", line 155, in POST
ws.proxy.add_torrent_filecontent(vars.torrent.filename,data_b64)
File "/usr/lib/python2.5/site-packages/dbus/proxies.py", line 136, in __call__
**keywords)
File "/usr/lib/python2.5/site-packages/dbus/connection.py", line 603, in call_blocking
message, timeout)
DBusException: org.freedesktop.DBus.Python.deluge.core.InvalidEncodingError: Traceback (most recent call last):
File "/usr/lib/python2.5/site-packages/dbus/service.py", line 687, in _message_cb
retval = candidate_method(self, *args, **keywords)
File "/usr/share/deluge/plugins/WebUi/dbus_interface.py", line 201, in add_torrent_filecontent
self._add_torrent(filename)
File "/usr/share/deluge/plugins/WebUi/dbus_interface.py", line 242, in _add_torrent
self.interface.config.get("use_compact_storage"))
File "/usr/lib/python2.5/site-packages/deluge/core.py", line 355, in add_torrent
return self.sync() # Syncing will create a new torrent in the core, and return it's ID
File "/usr/lib/python2.5/site-packages/deluge/core.py", line 854, in sync
raise e
InvalidEncodingError: ''
write: /home/radu/deluge_0.337342990697_catia_book.zip.torrent
Pickling state...