theia
theia copied to clipboard
Dirty editors cannot be saved after application recovers from "offline" mode
Bug Description:
If a backend process hogs resources and blocks frontend<->backend communication the application will go "offline" and eventually recover. During this time, the frontend can be slow to recognize that connection is interrupted as per #12194 and a user may continue to make edits to a file, putting it into a dirty state. When the application finally recovers from "offline" mode, it is impossible to save any new changes to the existing editor. The editor must be closed and reopened.
Steps to Reproduce:
- Build this branch which adds a command to hang the backend for 3 minutes.
- Start Theia for browser and open an editor (
FileA.txt
) - Run the command "hang backend"
- Start making edits to
FileA.txt
and try to save them (they will fail because the backend is blocked, notice also that there is no indication that there is a failure) - Eventually (about 1 min) the status bar will turn yellow (#12194), after 3 minutes the "hang backend" command will complete and the status bar will return to blue. The application should be interactive again
- notice that you still cannot save your edits you made to
FileA.txt
Additional Information
- Operating System:
- Linux
- Theia Version: Master