Intermittent work / fail behavior of OCP CAD Viewer #104
Replies: 8 comments 2 replies
-
I'm on vacation and away from any keyboard, so I cannot reproduce it. |
Beta Was this translation helpful? Give feedback.
-
Can you check the developer tools of VS Code? It could be that you are running into a graphic driver issue here. We had that earlier with Linux |
Beta Was this translation helpful? Give feedback.
-
It has something to do with opening a "folder" vs opening a file. When I open a folder (which opens a new workspace), it doesn't work. But when I open the file directly, it works as expected. |
Beta Was this translation helpful? Give feedback.
-
I just discovered the problem can also happen when opening the file directly. I think it is some kind of a race condition. Opening a folder changes the timing and causes it to fail every time (so far). Opening a file works more often, but can also fail. My test system is on the slow side (running in VirtualBox) so it probably is exposing this race condition where a faster system would not see it. |
Beta Was this translation helpful? Give feedback.
-
The viewer opens for example when you load or save a Python file that imports build123d or cadquery. If you close the viewer pane and then save the Python file again, does the viewer start again properly? |
Beta Was this translation helpful? Give feedback.
-
hmm, interesting. |
Beta Was this translation helpful? Give feedback.
-
Developer Tools Console - CAD Viewer Failed Developer Tools Console - CAD Viewer Worked The logs are exactly the same up to line 33. Console Log Lines 36-39 in failed case:
Console Log Lines 36-38 in working case:
|
Beta Was this translation helpful? Give feedback.
-
Thanks @WayneSherman |
Beta Was this translation helpful? Give feedback.
-
Using
code --install-extension ms-python.python
code --install-extension bernhard-42.ocp-cad-viewer # ver 2.4.1
After following the installation instructions, if I directly load the auto created file "ocp_vscode_demo.py" then everything works.
But if I open "folder" which opens a "workspace" (the folder only contains the one demo file), the viewer pane stays empty and I get the following error when trying to run ocp_vscode_demo.py:
The above exception leads to other exceptions and finally "RuntimeError: Cannot access viewer config. Is the viewer running?"
Thanks for the help.
Beta Was this translation helpful? Give feedback.
All reactions