Internal error when editing prefs

Greetings Jon et al.!

I’m running the latest Psychopy on a MacBook Air running 10.14.6 (Mojave).

I was having some weirdness that I can’t document terribly well that I’ll tell you about first. Psychopy was running fine and then, after no updates or anything obvious 1) it would only half launch - that is “PsychPy” would appear in the menu bar and the icon would appear in the dock, but that’s it until I clicked the icon in the dock, then the splash screen would appear followed by the coder and runner windows as normal. But 2) when I ran my code, the display would run fine, it would exit on a keypress, but no outputs (from print() e.g.) would appear in the runner window’s stdout pane, and no exit message would appear.

Deleting both .cfg files, a restart, and clean re-install seem to have fixed this. But now, whenever I try to edit anything in the preferences, I get the following

wx._core.wxAssertionError: C++ assertion “”tlw”” failed at /Users/robind/projects/bb2/dist-osx-py36/build/ext/wxWidgets/src/osx/window_osx.cpp(731) in DoClientToScreen(): TopLevel window missing

The above exception was the direct cause of the following exception:

SystemError: <class ‘wx._propgrid.PropertyGridEvent’> returned a result with an error set

I don’t really need to edit anything in the prefs, but thought I’d let you know.


ps. please let me know if there’s a prefered method of filing bug reports.

Hi Larry! :slightly_smiling_face:

A couple of those I did actually know about

  1. the issue with having to click on the dock icon before PsychoPy opens is something I’ve seen but haven’t tracked down. It doesn’t happen in the self-installed-python version only when psychopy is bundled into an app and I can’t work out why there’s a difference (my guess is some new Apple security policy block but not sure)
  2. With the failure to print messages into the output, that’s something that we’ve fixed a couple of issues in recent releases. It turned out that this was occurring with some ways of launching PsychoPy but not others - if you launched by double-clicking an experiment and/or closed the Runner view after it opened then the stdout pipe was lost - but those ones have been fixed. If you can find a sequence of actions to reliably cause the issue with 2020.2.6 then let us know and we’ll work out what other way there is to break it!
  3. failure to edit prefs is a new one for me and I haven’t been able to replicate that on my Mac so, similarly, any extra information would be great. The error message in that one is pretty limited!

Hi Jon! Long time no see!

Thanks for the info!

Okay, I can reproduce that error by trying to edit the Hardware → audio library pref “by hand”
The error does not occur if edit it using the pop up box by hitting the … button on the right, nor does it seem to occur for any of the other preferences I have tried.

1 Like

Ah, excellent. Now we know how to produce the bug we can work on a fix! :slight_smile:

And Todd has fixed another buglet that might fix the non-printing issue. We’ll push out a new version next week. The clicking on the dock thing is likely to be harder though (as in I don’t have a clue what that’s about yet!)

Hopefully catch up with you again at a conference one day, when we’re allowed to move around the real world again! :blush:

best wishes,