-
Notifications
You must be signed in to change notification settings - Fork 63
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ZMQ ioloop.install crash Windows 10 Python 3.8 #77
Comments
I think this might be fixed in 4829916#diff-47959962e9ca72578ddb3c2f786731e8 which is in |
Ok, can you see if meshcat 0.0.19 fixes your issue? |
Thanks! I did
in my python 3.8 environments. Re-running The prompt prints this and nothing else happens,
If I Ctrl-C I get the traceback
I'm unsure about the internals of meshcat but does this indicate that it is handing while attempting to start the ZMQ subprocess? Or is this what you would expect and it's just that the browser window did not open automatically? |
Ah, that's interesting. Can you try just running `meshcat-server --open`
and see what that does? In theory this should all work on Windows, but I
haven't used it on Windows myself in a long time.
…On Fri, Sep 4, 2020 at 3:50 AM Daniel ***@***.***> wrote:
Thanks!
I did
pip install --upgrade meshcat
in my python 3.8 environments.
Re-running box.py gets rid of the error, but I'm not it's still working.
I was expecting a browser window to open and show the scene?
The prompt prints this and nothing else happens
(pvtrace-test-2.1.4) C:\Users\daniel.farrell\Documents\pvtrace>python box.py
Fatal Python error: _Py_HashRandomization_Init: failed to get random numbers to initialize Python
Python runtime state: preinitialized
If I Ctrl-C I get the traceback
Traceback (most recent call last):
File "box.py", line 8, in <module>
vis = meshcat.Visualizer().open()
File "C:\Users\daniel.farrell\AppData\Local\Continuum\anaconda3\envs\pvtrace-test-2.1.4\lib\site-packages\meshcat\visualizer.py", line 82, in __init__
self.window = ViewerWindow(zmq_url=zmq_url, start_server=(zmq_url is None), server_args=server_args)
File "C:\Users\daniel.farrell\AppData\Local\Continuum\anaconda3\envs\pvtrace-test-2.1.4\lib\site-packages\meshcat\visualizer.py", line 21, in __init__
self.server_proc, self.zmq_url, self.web_url = start_zmq_server_as_subprocess(
File "C:\Users\daniel.farrell\AppData\Local\Continuum\anaconda3\envs\pvtrace-test-2.1.4\lib\site-packages\meshcat\servers\zmqserver.py", line 69, in start_zmq_server_as_subprocess
line = server_proc.stdout.readline().strip().decode("utf-8")
KeyboardInterrupt
^C
I'm unsure about the internals of meshcat but does this indicate that it
is handing while attempting to start the ZMQ subprocess? Or is this that
you would expect and it's just that the browser windows did not open
automatically?
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#77 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAEQQDSHQAJLL7OI4WUWMITSECL4BANCNFSM4QU7D6MA>
.
|
Ah! Our old friend has returned
I can confirm this is using meshcat-0.0.19 on Python 3.8 on Windows 10. |
This seems to be this bug in tornado tornadoweb/tornado#2608 the workaround is in the release notes https://www.tornadoweb.org/en/stable/releases/v6.0.4.html#general-changes
So the fix seems to be detecting Windows, Python version, and manually setting the event loop policy. I can prepare a pull request at some point, probably the weekend. |
@danieljfarrell The issue is fixed by tornado 6.1.0 for me, so this workaround is not needed anymore. FYI With current meshcat-python master (i.e. after #81 was merged) I can run pvtrace (and box.py fwiw) in a fresh Python3.8 conda environment both on work and personal PC. |
So if meshcat-python sets |
This is specific to (in the testing I have done so far):
a workaround it to create a Python 3.7 environment
I have a clean python 3.8 environment created using conda,
I downloaded the box.py example and ran it
and I get the following traceback,
Using Python 3.8.5
These are the installed packages
Any ideas on how I can work around this problem? Maybe I need to use an earlier version of meshcat?This seems to be a problem with Python 3.8 on Window 10.
The text was updated successfully, but these errors were encountered: