OK. I’m making some progress here.
Getting PsychoPy to load: The solution by @TarandeepKang solves the problem by not loading pyglet (which won’t be a solution in the long run). The pyglet team have posted some fixes to the top of their 1.5-maintenance branch and using that gets PsychoPy loading again without the hack to validators.
But the issue @walter raises, with CoreFoundation not being found, is the next one to crack. That occurs even if we try to launch a script that does nothing, so it seems to be something in the script-launching process within PsychoPy app
I have actually uploaded a testing release called 2020.2.7rc1 with the first step applied (where PsychoPy should launch but cant yet run scripts on Big Sur)
New release of pyglet (v1.5.11) should fix issue with CoreFoundation. Furthermore, it should prevent future issues with finding libraries.
I don’t think they’ll fix this one:
dyld: Library not loaded: /System/Library/Frameworks/CoreFoundation.framework/Versions/A/CoreFoundation
Referenced from: /Applications/PsychoPy.app/Contents/MacOS/python
Reason: image not found
because I’m getting that even if I launch a script that contains no pyglet calls (just
some potential useful info here about changes in Big Sur
OK, some more positive news… I’ve just had a working setup on Big Sur where I made only the following tweaks:
That was based on Python 3.8 installed from python.org so we might yet have trouble when we port that into the Standalone app bundle (which so far has been built on Py3.6) but fingers crossed it means we should be able to get something working soon!
OK, there’s now a test release availabe that I think works fine on Big Sur on everything except for the new TextBox (I have the fix for that implemented as well but it requires rebuilding the binaries)
Hopefully 2020.2.7 final will be out this afternoon with full Big Sur support back in
It ended up being called 2020.2.8 after a last minute bug in 2020.2.7! But I think this should fix the Big Sur troubles:
Thank you so much for the commitment and speedy fix Jon! Amazing stuff!
Thanks so much Jon for the rapid fix. PsychoPy 2020.2.8 seems to be running just fine on my MacBook Pro 16" with Big Sur.
Just wanted to echo my sincere thanks for the speedy changes, Jon! I am extremely grateful (as are my graduate students).
Eek. So I have some people doing a longitudinal training study (which is covering a significant period of time) that I created in PsychoPy v1.90.2. Someone’s just updated their OS to Big Sur and they’re now receiving the following error message:
Traceback (most recent call last):
File “/Users/username/Music/Current/Study/Experimentfolder/Experiment.py”, line 2, in
from psychopy import locale_setup, sound, gui, visual, core, data, event, logging
File “/Applications/PsychoPy2.app/Contents/Resources/lib/python2.7/psychopy/visual/init.py”, line 26, in
from .text import TextStim
File “/Applications/PsychoPy2.app/Contents/Resources/lib/python2.7/psychopy/visual/text.py”, line 28, in
File “/Applications/PsychoPy2.app/Contents/Resources/lib/python2.7/psychopy/event.py”, line 63, in
from pyglet.window.mouse import LEFT, MIDDLE, RIGHT
File “/Applications/PsychoPy2.app/Contents/Resources/lib/python2.7/pyglet/window/init.py”, line 1896, in
File “/Applications/PsychoPy2.app/Contents/Resources/lib/python2.7/pyglet/init.py”, line 384, in getattr
File “/Applications/PsychoPy2.app/Contents/Resources/lib/python2.7/pyglet/gl/init.py”, line 100, in
from pyglet.gl.lib import GLException
File “/Applications/PsychoPy2.app/Contents/Resources/lib/python2.7/pyglet/gl/lib.py”, line 141, in
from pyglet.gl.lib_agl import link_GL, link_GLU, link_AGL
File “/Applications/PsychoPy2.app/Contents/Resources/lib/python2.7/pyglet/gl/lib_agl.py”, line 49, in
File “/Applications/PsychoPy2.app/Contents/Resources/lib/python2.7/pyglet/lib.py”, line 118, in load_library
File “/Applications/PsychoPy2.app/Contents/Resources/lib/python2.7/pyglet/lib.py”, line 286, in load_framework
raise ImportError(“Can’t find framework %s.” % path)
ImportError: Can’t find framework /System/Library/Frameworks/OpenGL.framework.
As mentioned in the thread above, the issue seems to be with Pyglet and OpenGL. Can anyone recommend a potential way to fix this in such an old version of PsychoPy?
Help much appreciated!
Looking at this from a PsychoPY 1.90.2 perspective: Hotfixes for getting working on Big Sur by peircej · Pull Request #3309 · psychopy/psychopy · GitHub
I can find (both attached):
But I’m not sure what the equivalent file for ‘visual/textbox2/textbox2.py’ would be? The textbox folder (there isn’t a textbox2 folder) contains only:
psychopy/visual/init.py has very similar code to that in Jon’s example, whereas
visual/textbox/fontmanager.py is quite different:
import numpy as np
import unicodedata as ud
from matplotlib import font_manager
from psychopy.core import getTime
from .textureatlas import TextureAtlas
from pyglet.gl import (glGenLists, glNewList, GL_COMPILE, GL_QUADS,
glBegin, glTexCoord2f, glVertex2f, glEnd, glDeleteLists,
glEndList, glTranslatef, glDeleteTextures)
What edits would you suggest I make?fontmanager.py (18.9 KB) init.py|attachment (2.7 KB)
Just to add to this… I know that in general it’s preferred if people continually update their code to the most recent version of PsychoPy, but at the time I wrote it my code worked best in 1.90.2 (which is to say that it didn’t run at all in 1.90.3) so I stuck with it. It’s a several month-long training scheme, with several twists and turns, so not the simplest thing to just update (well, not for me anyway). By this point I’ve had participants taking the training for my experiment for a great deal of time using their own downloaded copies of 1.90.2, so it’s neither easy nor practical for me to have to update the whole lot (although rest assured, I’d write any future experiments in the most up-to-date PsychoPy version). As such, some thoughts on how to save it from the perils of Big Sur would be greatly appreciated if at all possible… thanks
Just downloaded the 2020.2.10 release standalone and installed on my Mac with Big Sur 11.1
Alas, it does not start and shows a PsychoPy error instead.
Any more leads on this?
shows a PsychoPy error instead.
Error messages contain text that is essential to working out what’s going on. If you don’t tell us what the error message was (all of it) then we really can’t help
That’s literally all.
Nothing in the console then either
OK, thanks. That’s not very helpful of Big Sur then!
I wonder if any useful information was stored in the log file. Could you go to a terminal window and run:
Maybe that will give us some clues. Otherwise I’m at a loss how to help right now
Thanks @Jon. I’m struggling a bit. When I open a Terminal and copy and paste the command I get " No such file or directory" I then tried a few things including to navigate to the top level and into the Applications directory where PsychoPy3.app lives. I also changed the spelling from psychopy3 to PsychoPy3 but I always get the same error/
Sorry, I am not too familiar with terminal so I’m probably missing something trivial.
Can you suggest what else I could try to make the command work?
~ is your user folder (also called your home folder). If you are more comfortable using the Mac Finder than the Terminal, then select “Home” from the “Go” menu. Push
CMD + SHIFT + . to see invisible files (files or folders that start with a
. are normally invisible). At the top level of your user folder, you should now see a folder called
.psychopy3, which should contain that log file.