You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Because sometimes, I got an error there.
It appends when the data are not complete.
Sample:
JS: {"category":"tracker","request":"get","statuscode":200,"
Exception in thread Thread-1:
Traceback (most recent call last):
File "C:\Python27\lib\threading.py", line 808, in __bootstrap_inner
self.run()
File "C:\Python27\lib\threading.py", line 761, in run
self.__target(*self.__args, **self.__kwargs)
File "...test\peyetribe.py", line 418, in _listener_thread
f = json.loads(js)
File "C:\Python27\lib\json\__init__.py", line 338, in loads
return _default_decoder.decode(s)
File "C:\Python27\lib\json\decoder.py", line 365, in decode
obj, end = self.raw_decode(s, idx=_w(s, 0).end())
File "C:\Python27\lib\json\decoder.py", line 381, in raw_decode
obj, end = self.scan_once(s, idx)
ValueError: end is out of bounds
Can see that the message is troncated, ##{"category":"tracker","request":"get","statuscode":200,"##
Then, json decoder fail.
Maybe should put a try/except block :)
The text was updated successfully, but these errors were encountered:
Thanks for the comment and apologies for the delayed response; seems like it got lost in my junk box somehow.
Anyway, I'll have a look at what happens -- it might also be that the packet is somehow split into two in the network side; this should of course be handled gracefully and the packet re-assembled before being sent to the parser.
I have never seen it on any of the machines we've been using this on. What is your setup (platform/OS)? Do you pass the packets through a "real" network or do you use the internal loopback network interface?
I am on W7-64, py27
Actually, I get this error with a specific setup:
eyetribe and my script on the same PC
my script does the connexion with eyetribe server using your module, and display some of the result (at 10Hz) in a tkinter gui
I get that error if I play to much with the gui (using my mouse).
If I do not play with the gui, no problems. Which actually work for me because it was just to show some datas.
I paste it here http://pastebin.com/jffZ5fSk
It's not my script, just a part of it as it is much longer. I hope it works still.. I do not have an eyetribe device to test it now.
Hi,
Line 417, I added a print:
Because sometimes, I got an error there.
It appends when the data are not complete.
Sample:
Can see that the message is troncated, ##{"category":"tracker","request":"get","statuscode":200,"##
Then, json decoder fail.
Maybe should put a try/except block :)
The text was updated successfully, but these errors were encountered: