[solved] cant get deluged-debug.exe to log

Specific support for Deluge on Microsoft Windows OS
haydent
Member
Member
Posts: 30
Joined: Tue Apr 12, 2016 10:24 am

[solved] cant get deluged-debug.exe to log

Post by haydent »

*answer - should have been debug not DEBUG

*updated question, my problem is now that deluged-debug.exe produces no output if run :

deluged-debug.exe -L DEBUG

or

deluged-debug.exe -L DEBUG -l log.txt


have just taken the plugin template from the wiki and added a couple of log lines, then run deluge in debug (windows) but i never see the result of my code ??

Code: Select all

class Core(CorePluginBase):
    def enable(self):
        self.config = deluge.configmanager.ConfigManager("texttab.conf", DEFAULT_PREFS)
        log.info("enable")

    def disable(self):
        log.info("disable")

    def update(self):
       pass
running "deluge-debug.exe -L INFO" is see the system INFO messages that my plugin is being enabled and disabled but i dont see my INFO messages
Last edited by haydent on Wed Apr 27, 2016 12:07 am, edited 2 times in total.
haydent
Member
Member
Posts: 30
Joined: Tue Apr 12, 2016 10:24 am

Re: cant get my plugin to log

Post by haydent »

seems it was due to me not running classic mode, ie deluged daemon and client. in classic mode the logging happens, but not the other way.

i even run deluged-debug.exe -L INFO as well, but when in the mode (not classic) my log entries dont appear at all.

is there a different way you are meant to log from the daemon ?
haydent
Member
Member
Posts: 30
Joined: Tue Apr 12, 2016 10:24 am

Re: cant get my plugin to log

Post by haydent »

ok, so i worked out that if running non-classsic mode ie client and daemon you need to put logging commands in the gtkui.py to see them from the client process, but id still like to work out why i cant get the log output from the deluged daemon...
bro
Top Bloke
Top Bloke
Posts: 364
Joined: Sun Aug 28, 2011 6:46 pm
Location: Norway

Re: cant get my plugin to log

Post by bro »

When running with daemon and GTKUI as thin client you have to separate processes. Naturally, you will not see the log statements from another process. You must specify one log file for the daemon and another for for the GTKUI and you should see all your log statments.
When reporting issues, please include any relevant information such as OS (and version), python version (for Windows users this depends on which Deluge installer was used), Deluge version and plugin version.
haydent
Member
Member
Posts: 30
Joined: Tue Apr 12, 2016 10:24 am

Re: cant get my plugin to log

Post by haydent »

yes i figured this but even when using "deluged-debug.exe -L INFO -l debug.txt" for the thin client it does not show any logs at all, not even with DEBUG.
Cas
Top Bloke
Top Bloke
Posts: 3679
Joined: Mon Dec 07, 2009 6:04 am
Location: Scotland

Re: cant get my plugin to log

Post by Cas »

Sounds like it could be a permission issue with creating the log file

http://dev.deluge-torrent.org/wiki/Trou ... ficLogging
haydent
Member
Member
Posts: 30
Joined: Tue Apr 12, 2016 10:24 am

Re: cant get my plugin to log

Post by haydent »

its in windows with no such problem normally, the text file is created, and if there is a fatal error or something that gets logged but logging messages dont show up, also to show this i run daemon with out specifying log file so it should output to shell but nothing is shown... (thanks for your help so far)
Cas
Top Bloke
Top Bloke
Posts: 3679
Joined: Mon Dec 07, 2009 6:04 am
Location: Scotland

Re: cant get my plugin to log

Post by Cas »

I would not bring it up if it wasn't a potential issue on Windows, what path are you using for the log file?
haydent
Member
Member
Posts: 30
Joined: Tue Apr 12, 2016 10:24 am

Re: cant get deluged-debug.exe to log

Post by haydent »

just deluged-debug.exe -L DEBUG -l log.txt so it creates it in the program folder
Cas
Top Bloke
Top Bloke
Posts: 3679
Joined: Mon Dec 07, 2009 6:04 am
Location: Scotland

Re: cant get deluged-debug.exe to log

Post by Cas »

Which is why the wiki link doesn't do that...
Post Reply