Page 1 of 1

0.8.0Beta1 [1ba588f] error message

Posted: October 17th, 2015, 10:10 am
by RevDrew
I keep getting this message, for the most part sabnzbd is idle and it just randomly pops up;
[17/Oct/2015:10:26:47] ENGINE TypeError("argument of type 'NoneType' is not iterable",)
Traceback (most recent call last):
File "L:\Python\SABnzbd\cherrypy\wsgiserver\wsgiserver2.py", line 1354, in communicate
req.parse_request()
File "L:\Python\SABnzbd\cherrypy\wsgiserver\wsgiserver2.py", line 618, in parse_request
success = self.read_request_line()
File "L:\Python\SABnzbd\cherrypy\wsgiserver\wsgiserver2.py", line 685, in read_request_line
if NUMBER_SIGN in path:
TypeError: argument of type 'NoneType' is not iterable
no idea what it's about and it still seems to work okay when I use it.

Re: 0.8.0Beta1 [1ba588f] error message

Posted: October 17th, 2015, 10:21 am
by shypike
Odd. This comes from deep inside the embedded webserver we use.
It's written by a third party.
I'll check whether it's a known problem (with a solution).

Re: 0.8.0Beta1 [1ba588f] error message

Posted: October 19th, 2015, 4:51 am
by RevDrew
Not sure if it matters but I just extracted .8 over my .7.2 installation.
That's the way I have always 'upgraded' in the past.

running source on Win 7, Python 2.7.10

Re: 0.8.0Beta1 [1ba588f] error message

Posted: October 19th, 2015, 5:24 am
by sander
FWIW:

Looks the same: https as http://groups.google.com/forum/#!topic/ ... zHtLD8BCCM

With this analysis / patch:
From the error message it looks like python is complaining about being
asked to work with the 'path' variable when path is None. e.g. we may
want something like this: instead of

if NUMBER_SIGN in path:

we could have

if path and NUMBER_SIGN in path:


Farther down in that function there is a line that says

if QUESTION_MARK in path:

That will probaby fail in the same way.

Looking at cherrypy's code, it appears 'path' can certainly become
None from some calls to parse_request_uri() - there is a case where
the function returns (None, uri, None), which would set the path to
None and presumably trigger this bug.
...
Summary: looks like a cherrypy bug. I'm not sure what the correct fix is.
Or just ignore as it is causing a real problem, right? https://forums.sabnzbd.org/viewtopic.php?f=3&t=19204 ... :P

Re: 0.8.0Beta1 [1ba588f] error message

Posted: October 20th, 2015, 9:54 am
by shypike
OK, so this bug is in both the old and the new versions of CherryPy. Great.
I have never seen it myself, so it likely to be one those transient problems, very hard to catch.
Maybe I can create a patch that at least takes away the unnecessary noise.

Re: 0.8.0Beta1 [1ba588f] error message

Posted: October 21st, 2015, 1:55 pm
by shypike
I've patched CherryPy, but I cannot predict side effects because I cannot reproduce the issue.
We'll have to wait for Beta2 for feedback.

Re: 0.8.0Beta1 [1ba588f] error message

Posted: October 21st, 2015, 1:58 pm
by RevDrew
It doesn't affect operation, it's just an occasional error.
Interesting I've never noticed it before, unless it just wasn't showing up in previous versions.

No worries though, everything works as it should.

Re: 0.8.0Beta1 [1ba588f] error message

Posted: November 7th, 2015, 1:38 am
by firesale
Just chiming in what my error looks like as it looks similar to OP's error.

Code: Select all

07/Nov/2015:07:34:48] HTTP Traceback (most recent call last): File "cherrypy\_cprequest.pyo", line 670, in respond File "cherrypy\lib\encoding.pyo", line 217, in __call__ File "cherrypy\_cpdispatch.pyo", line 61, in __call__ File "sabnzbd\interface.pyo", line 433, in api File "sabnzbd\api.pyo", line 100, in api_handler File "sabnzbd\api.pyo", line 499, in _api_history File "sabnzbd\api.pyo", line 959, in report File "json\__init__.pyo", line 243, in dumps File "json\encoder.pyo", line 207, in encode File "json\encoder.pyo", line 270, in iterencode UnicodeDecodeError: 'utf8' codec can't decode byte 0xf6 in position 7: invalid start byte

Re: 0.8.0Beta1 [1ba588f] error message

Posted: November 7th, 2015, 4:27 am
by shypike
This is a different problem altogether.
It looks like a text hasn't been properly converted to Unicode.
Can you tell more about when this happens?

Re: 0.8.0Beta1 [1ba588f] error message

Posted: December 11th, 2015, 2:23 pm
by wacker
I get the same error all the time. 0.8.0Beta3.
Seems like it posts the error for each rar file that has been downloaded.
Any ideas?
Thanks


[11/Dec/2015:20:19:15] HTTP Traceback (most recent call last): File "/usr/share/sabnzbdplus/cherrypy/_cprequest.py", line 670, in respond response.body = self.handler() File "/usr/share/sabnzbdplus/cherrypy/lib/encoding.py", line 217, in __call__ self.body = self.oldhandler(*args, **kwargs) File "/usr/share/sabnzbdplus/cherrypy/_cpdispatch.py", line 61, in __call__ return self.callable(*self.args, **self.kwargs) File "/usr/share/sabnzbdplus/sabnzbd/interface.py", line 436, in api return api_handler(kwargs) File "/usr/share/sabnzbdplus/sabnzbd/api.py", line 102, in api_handler response = _api_table.get(mode, (_api_undefined, 2))[0](name, output, kwargs) File "/usr/share/sabnzbdplus/sabnzbd/api.py", line 153, in _api_queue return _api_queue_table.get(name, (_api_queue_default, 2))[0](output, value, kwargs) File "/usr/share/sabnzbdplus/sabnzbd/api.py", line 269, in _api_queue_default return report(output, keyword='queue', data=remove_callable(info)) File "/usr/share/sabnzbdplus/sabnzbd/api.py", line 970, in report response = json.dumps(info) File "/usr/lib/python2.7/json/__init__.py", line 243, in dumps return _default_encoder.encode(obj) File "/usr/lib/python2.7/json/encoder.py", line 207, in encode chunks = self.iterencode(o, _one_shot=True) File "/usr/lib/python2.7/json/encoder.py", line 270, in iterencode return _iterencode(o, 0) UnicodeDecodeError: 'utf8' codec can't decode byte 0xf6 in position 7: invalid start byte

Re: 0.8.0Beta1 [1ba588f] error message

Posted: December 11th, 2015, 4:55 pm
by safihre
Your bug is a little different, but we are aware of it!
A new beta will come out very soon to fix this error!