-
-
Notifications
You must be signed in to change notification settings - Fork 68
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
NSWindow main thread error when trying to setup Gymnasium (openapi gym) #257
Comments
Ok so i missed this #10 (comment) when i was looking through the issues. So i just tried putting the code in a But based on that comment is this something that even can be addressed on the clj-python side? |
Most likely you have to run in embedded mode. I am surprised clojure -m didn't solve the issue but especially with windowing systems there is a lot going on such as signal handling callbacks that the JVM does when it is the main process that potentially other systems do not work well with. |
Embedded mode is this? https://clj-python.github.io/libpython-clj/embedded.html |
@eoliphan did you try the equivalent code in Python? I tend to find that's a pretty good troubleshooting step for some of these issues. Make sure this works out for you from the directory where you are running your code: env/bin/python <(cat << eof
import gymnasium as gym
env = gym.make("LunarLander-v2", render_mode="human")
env.reset(seed=42)
eof
)
# should return 0
echo "$?" |
Hi, im trying to run some simple gymnasium stuff and getting the following error:
I'm on OSX Sonoma (silicon), python 3.11.6, Clojure 1.11.1 and java 17. I was actually about to write this as a crash report, but decided to try another Java 17 jvm and was able to get the error output instead.
In any case, is there something one can do with libpython-clj to setup the call such that it's on the main thread?
The text was updated successfully, but these errors were encountered: