Re: New User needs help please
Posted: Thu Nov 27, 2014 6:48 am
Thanks l hope you do get time to have a look and fix it, as l have no idea how to.
Support Forum for the Deluge BitTorrent Client
https://forum.deluge-torrent.org/
Code: Select all
if(!downloadInProgress())
{
Runtime.getRuntime().exec("cmd /c start shutdown.bat");
}
Code: Select all
shutdown /s -t 60 -c "Deluge downloads finished"
I was just wondering if something like that is possible, rather than all of the lines that was written instead, I figure this is a more simple way to go about it.Cas wrote:Sorry what is this related to? The plugin does shutdown when all torrents are finished.
Ok, sorry. Just treat it as separate. I was just thinking in another way, yours is way better. I'm just trying to learn a bit of code, so I want to know if somehow, you can have it just run cmd/terminal commands, which sounds like it would be easier. Nevermind, and thanks for the cool plugin.Cas wrote:Still don't understand what you are asking. The plugin has to determine if torrents are still downloading, provides more options than just shutdown and is cross-platform...
Code: Select all
/usr/lib/python2.7/dist-packages/deluge/ui/gtkui/listview.py:250: GtkWarning: gtk_tree_model_sort_set_sort_column_id: assertion 'header != NULL' failed
self.treeview.get_model().set_sort_column_id(column_state.sort, column_state.sort_order)
Code: Select all
[ERROR ] 09:23:55 eventmanager:59 Event handler TorrentFinishedEvent failed in <bound method Core.on_event_torrent_finished of <autoshutdown.core.Core object at 0x7f9dc0165e90>> with exception org.freedesktop.DBus.Error.UnknownMethod: Method "Shutdown" with signature "" on interface "org.freedesktop.UPower" doesn't exist
Code: Select all
[ERROR ] 09:24:19 init:57 Unable to disable plugin!
[ERROR ] 09:24:19 init:58 deregister_event_handler() takes exactly 3 arguments (2 given)
Traceback (most recent call last):
File "/usr/lib/python2.7/dist-packages/deluge/plugins/init.py", line 55, in disable
self.plugin.disable()
File "/home/MyUserName/.config/deluge/plugins/AutoShutdown-1.2-py2.7.egg/autoshutdown/core.py", line 108, in disable
component.get("EventManager").deregister_event_handler(self.on_event_torrent_finished)
TypeError: deregister_event_handler() takes exactly 3 arguments (2 given)
Code: Select all
/usr/lib/python2.7/dist-packages/deluge/ui/gtkui/gtkui.py:180: Warning: Attempt to add property GnomeProgram::sm-connect after class was initialised
self.gnome_prog = gnome.init("Deluge", deluge.common.get_version())
/usr/lib/python2.7/dist-packages/deluge/ui/gtkui/gtkui.py:180: Warning: Attempt to add property GnomeProgram::show-crash-dialog after class was initialised
self.gnome_prog = gnome.init("Deluge", deluge.common.get_version())
/usr/lib/python2.7/dist-packages/deluge/ui/gtkui/gtkui.py:180: Warning: Attempt to add property GnomeProgram::display after class was initialised
self.gnome_prog = gnome.init("Deluge", deluge.common.get_version())
/usr/lib/python2.7/dist-packages/deluge/ui/gtkui/gtkui.py:180: Warning: Attempt to add property GnomeProgram::default-icon after class was initialised
self.gnome_prog = gnome.init("Deluge", deluge.common.get_version())
[ERROR ] 18:00:58 eventmanager:59 Event handler TorrentFinishedEvent failed in <bound method Core.on_event_torrent_finished of <autoshutdown.core.Core object at 0xa6d8576c>> with exception org.freedesktop.DBus.Error.UnknownMethod: Method "Shutdown" with signature "" on interface "org.freedesktop.UPower" doesn't exist