ah  okay  new plan add the following to the top of ginport  invalidateevents void ginport  invalidateevents v local v context  context no need to invalidate the events if the context itself was already invalidated  the apieventhandler will have already cleaned up the listeners  if  state  kinvalidated return then i think  we should not need any special workarounds either here or in the test s js file  mind giving that a try 