wx._core.wxAssertionError: C++ assertion “wxWindow::FindFocus() == GetWindow()” failed at …\src\msw\caret.cpp(160) in wxCaret::DoMove(): how did we lose focus?
The above exception was the direct cause of the following exception:
SystemError: <class ‘wx._core.CommandEvent’> returned a result with an exception set
In order to check the operation of an experimental program that I created three days ago, I tried to run the program, and the following message appeared. Although the program started without any problems, after it finished, the screen stopped responding and did not change no matter what I clicked. How should I deal with this issue?
@_h23j107a More detail would be useful if you’d like people to help with your issue. Consider editing your post and adding in.
What version of PsychoPy are you on? Include whether you are using a Mac, Windows, etc., and the version, too.
What is your task? Do you have any custom code or anything else? Can you press the ‘Escape’ Key and end the experiment? Does it save your data? Are you planning to use Pavlovia?
Is this happening every time? Did this happen once?
Some potential solutions (though more quick fixes - without more information, I cannot make any proper recommendations to fix the issue) are:
Update your PsychoPy version
Ensure your Monitor settings are correct (in Tools → Monitor Centre).
If you have multiple monitors, temporarily set PsychoPy to use only your primary display
Try unticking File → PsychoPy Preferences → General → full-screen
Try unticking allow GUI (if ticked) in the same place as above.
If relevant, remove custom code, e.g., anything that manipulates the caret or window focus
Check and ensure your Properties settings → Screens are correct, e.g., Monitor, Screen, Window Size, etc.