Gamez
Gamez copied to clipboard
Cannot connect to SabNZBD
the log lists: http://0.0.0.0:8092/sabnzbd/api?mode=get_config&apikey=*******************************§ion=misc&keyword=script_dir
When I access the url it gives an API key incorrect error. if I remove the '§ion=misc' part it gives me some acces... I don't know what happens exactly. It looks like the URL is malformed in some way.
Using version 1.1.17.6 on a Synology
I have the same error message here. So I tried to investigate. I don't know anything about Python, but the problem seems to be: GameTasks.py (l.368): url = "http://" + sabnzbdHost + ":" + sabnzbdPort + "/sabnzbd/api?mode=get_config&apikey=" + sabnzbdApi + "§ion=misc&keyword=script_dir"
§ion is unescaped and so translated to §ion
a quick fix is to modified the line to: url = "http://" + sabnzbdHost + ":" + sabnzbdPort + "/sabnzbd/api?mode=get_config&apikey=" + sabnzbdApi + "&section=misc&keyword=script_dir"
A better way would be to escape the entire line before opening it but again, I don't know anything about Python.
Source: https://www.inkling.com/read/programming-python-mark-lutz-4th/chapter-15/more-on-html-and-url-escapes