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
{{ message }}
Repository navigation
"Task exception was never retrieved" and "TypeError" while zooming #14
Steps to reproduce:
(use Chrome/Firefox as the default browser)
(in Win10 cmdline)
D:\code\py>python
Python 3.6.7 (v3.6.7:6ec5cf24b7, Oct 20 2018, 13:35:33) [MSC v.1900 64 bit (AMD64)] on win32
Type "help", "copyright", "credits" or "license" for more information.
>>> import vpython
>>> vpython.__version__
'7.5.1'
>>> vpython.sphere()
<vpython.vpython.sphere object at 0x000001FB85AD1A90>
>>>
Now a browser is opened and the sphere is shown correctly. Zoom in the object sufficiently (probably with other operations, with touch screen), the following will then repeatedly shown:
Task exception was never retrieved
future: <Task finished coro=<WSserver.onMessage() done, defined at C:\Users\xyy82\AppData\Roaming\Python\Python36\site-packages\vpython\no_notebook.py:154> exception=TypeError('must be real number, not NoneType',)>
Traceback (most recent call last):
File "C:\Users\xyy82\AppData\Roaming\Python\Python36\site-packages\vpython\no_notebook.py", line 187, in onMessage
await loop.run_in_executor(None, GW.handle_msg, msg)
File "C:\Program Files\Python36\lib\concurrent\futures\thread.py", line 56, in run
result = self.fn(*self.args, **self.kwargs)
File "C:\Users\xyy82\AppData\Roaming\Python\Python36\site-packages\vpython\vpython.py", line 393, in handle_msg
cvs.handle_event(evt)
File "C:\Users\xyy82\AppData\Roaming\Python\Python36\site-packages\vpython\vpython.py", line 3159, in handle_event
evt['pos'] = list_to_vec(pos)
File "C:\Users\xyy82\AppData\Roaming\Python\Python36\site-packages\vpython\vpython.py", line 177, in list_to_vec
return vector(L[0], L[1], L[2])
File "vpython/cyvector.pyx", line 29, in vpython.cyvector.vector.__init__
TypeError: must be real number, not NoneType
I verify seeing this error. As you imply, the bug appears only if zooming by touching the screen, not if using a mouse or touch pad. No idea what the cause is.
Should I file another bug in vpython/glowscript? Note that all I know about glowscript is it's the backend of the vpython, actually I don't even know how to reproduce this bug directly in glowscript.
I use touch screen often, so fixing this bug would have a great help to me.
PS: it is very nice to see that vpython is now again as easy to use as the old python module visual. Thank you for your works.
Activity
BruceSherwood commentedon Jul 24, 2019
I verify seeing this error. As you imply, the bug appears only if zooming by touching the screen, not if using a mouse or touch pad. No idea what the cause is.
BruceSherwood commentedon Jul 24, 2019
I verify that the same bug occurs with GlowScript VPython, so it is a problem with the GlowScript library, not with the Python code.
bewantbe commentedon Jul 25, 2019
Should I file another bug in vpython/glowscript? Note that all I know about glowscript is it's the backend of the vpython, actually I don't even know how to reproduce this bug directly in glowscript.
I use touch screen often, so fixing this bug would have a great help to me.
PS: it is very nice to see that vpython is now again as easy to use as the old python module visual. Thank you for your works.
BruceSherwood commentedon Jul 25, 2019
No need to file another report.