OS (e.g. Win10): Win10
PsychoPy version (e.g. 1.84.x): 2023.2.3
Standard Standalone? (y/n): yes
What was i doing beforehand?:
Yesterday, i was working on a psychopy experiment by copy-pasting some routines from 1 experiment to the other. When i tried to test it, the builder crashed and froze and after a while i just manually ended the session…
Now the file will not open anymore, and I get an error. However the error is about the codecs file that I cannot edit. Because of that, I am unsure if I just corrupted my files and will not be able to open them anymore, or if there is something else happening. What should I do when this happens? Can I retrieve my file in some way?
Error message:
If i try to open the experiment-file without opening the builder beforehand, I see the starting image + black python screen, and then everything goes away again.
If i open the builder beforehand, and then open the file, i get this error:
Traceback (most recent call last):
File “C:\Program Files\PsychoPy\lib\site-packages\wx\core.py”, line 2326, in Notify
self.notify()
File “C:\Program Files\PsychoPy\lib\site-packages\psychopy\app_psychopyApp.py”, line 729, in _bgCheckAndLoad
self.MacOpenFile(fileName)
File “C:\Program Files\PsychoPy\lib\site-packages\psychopy\app_psychopyApp.py”, line 936, in MacOpenFile
self.newBuilderFrame(fileName=fileName)
File “C:\Program Files\PsychoPy\lib\site-packages\psychopy\app_psychopyApp.py”, line 872, in newBuilderFrame
self.builder = BuilderFrame(None, -1,
File “C:\Program Files\PsychoPy\lib\site-packages\psychopy\app\builder\builder.py”, line 215, in init
self.fileOpen(filename=fileName, closeCurrent=False)
File “C:\Program Files\PsychoPy\lib\site-packages\psychopy\app\builder\builder.py”, line 755, in fileOpen
self.updateReadme()
File “C:\Program Files\PsychoPy\lib\site-packages\psychopy\app\builder\builder.py”, line 908, in updateReadme
self.readmeFrame = ReadmeFrame(
File “C:\Program Files\PsychoPy\lib\site-packages\psychopy\app\builder\builder.py”, line 3195, in init
self.ctrl = utils.MarkdownCtrl(self, file=filename, style=wx.BOTTOM)
File “C:\Program Files\PsychoPy\lib\site-packages\psychopy\app\utils.py”, line 514, in init
self.load()
File “C:\Program Files\PsychoPy\lib\site-packages\psychopy\app\utils.py”, line 590, in load
self.rawTextCtrl.SetValue(f.read())
File “C:\Program Files\PsychoPy\lib\codecs.py”, line 322, in decode
(result, consumed) = self._buffer_decode(data, self.errors, final)
UnicodeDecodeError: ‘utf-8’ codec can’t decode byte 0xe9 in position 205: invalid continuation byte
The code around the part of the error is:
def decode(self, input, final=False):
# decode input (taking the buffer into account)
data = self.buffer + input
(result, consumed) = self._buffer_decode(data, self.errors, final)
# keep undecoded input until the next call
self.buffer = data[consumed:]
return result
I am quite a novice with both psychopy and python. I thought it might be the _ between self. and buffer since the other parts of the syntax do not have that dash, but I am not allowed to change the code since it it psychopy’s own code (i assume?). Additionally, I wouldn’t know why suddenly this is a problem now, wile it isn’t for other experiments…
I hope this is enough information! Thanks a lot in advance