Editor Commit Before Project Close

I do commit at FileEditor state to document atFileEditor.deselectNotify method. When I close a project, deselectNotify is called. In the method I check that project not disposed and not disposing. But when I create WriteCommandAction the project becomes disposing. Sometimes it leads to exceptions like 

"Sorry but parent: project is being disposed so the child: ...

How to deal with this?

0
1 comment

From what I see, deselectNotify on project closing is invoked when project.isOpen() returns false already. This is also done on EDT, so there shouldn't be a race condition here.

Please provide more information about your exceptions, e.g. stack traces. Sample plugin project where this can be reproduced might also help. Please also mention IDEA version where you observe this behaviour. It's better to create a ticket in YouTrack with all this information.

0

Please sign in to leave a comment.