Search code examples
javascriptpythonv8pyv8

PyV8: event queue full


I'm using PyV8 and I get this error:

#...
  File "code\engine\window.py", line 345, in run_script
    res = self.js_context.eval(js)
error: Event queue full

I am indeed running multiple things at once. How can I get around this limitation? I haven't managed to find any mention of this anywhere... the trouble with only running on .eval() at a time is that I have javascript code calling python code which calls back into the javascript code...


Solution

  • Oh boy. It's just PyV8's poor error reporting at fault. What happened is my app uses pygame, and it was posting too many pygame events (thus overflowing its queue) before dealing with them. I really wish PyV8 would show the line numbers where the error happened, in the python code called from the javascript code...