Psychopy crashes due to pyglet error

Hi Everyone,

I am working on a psychopy experiment that keeps crashing after ~15 minutes of running.
The error I get is as follows:

    raise GLException(msg)
pyglet.gl.lib.GLException: b'invalid value'

I trace back this error to the TextStim() method.

I’m using windows 11
python 3.8.0
psychopy 2022.2.4
pyglet 1.4.10
AMD 6400 graphic card with the latest driver (Adrenalin 22.11.2)

I would love to hear if anyone has suggestions for debugging this.