GH Player Document closed event

I’ve had a user report problems using ggRhinoIFC in grasshopper player.
This plugin uses events and component expiry to manage data as the assembled database has relationships that are interfacing with other components data.

It seems when gh player is run, a script is opened, solved and seems to then close the script.
But when the script is run in the player context, no events are raised by the instance server.
Is there anyway to detect when the document is closed to flag to the plugin to release all data?
I looked at subscribing to events such as gh_document EnabledChanged but haven’t yet found it.

Thanks in advance for any suggestions.