-
Notifications
You must be signed in to change notification settings - Fork 6
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix(gui): Smoothening startup Part I (#355)
I think this renders best if split in two pull requests: one dealing with the lower level code (this one) and another dealing with the visible parts of the user interface. This way it's easier for reviewers and also unblocks @EduardGomezEscandell's work more quickly. So in this PR we reduce the duration of a timeout in case no changes in the startup state machine happen and we watch for the creation of the `addr` file. The watch only happens in the code path that causes the GUI to start the agent. For the watch operation to happen we need the directory to exist, so I added a precaution step to create it. It doesn't fail in case the directory already exists. It's important that we start watching the directory before launching the agent, otherwise race conditions could happen. Thus we start watching first, then launch the agent, and finally wait for the watching operation to complete (which may have completed by the time we start waiting, which is not a problem at all). This prevents the GUI from spawning more than one agent process. The last commit increases the timeout of one specific end-to-end test because I could see it failing before in CI killing the context, although I could never reproduce it locally not even with VMs.
- Loading branch information
Showing
5 changed files
with
36 additions
and
4 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters