-
Notifications
You must be signed in to change notification settings - Fork 323
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix restoring cloud projects that have been closed (e.g. from inactivity) #7584
Conversation
i think there are still issues with cloud project behavior - e.g. if they should open in the background |
Ok so when the cloud project isn't available anymore we don't throw any errors that ok but the working ones are not available under Screen.Recording.2023-08-18.at.12.06.00.movWhen switching to from cloud to local tab I see my project was dropped in the background (I havent opened any local project) Retrieving local project after closing Enso works fine |
@PabloBuchu that should be fixed now |
actually nvm... one second |
Not sure what was fixed but works completely the same:
Screen.Recording.2023-08-18.at.17.29.43.mov |
@PabloBuchu you might have forgotten to rebuild enso |
|
No it doesnt work both bugs are still present... Try to reopen Enso couple of times |
oh nvm. if you're reopening relatively quickly i think i know what the issue could be |
still can't repro unfortunately... it's definitely a problem, i might need more specific repro steps? |
Ok so problem with dropping project when switching between cloud / local is gone. Still If I have running cloud project and close Enso. After relaunch can use top icon to go to workspace.. (the same for local works fine) Screen.Recording.2023-08-21.at.11.48.17.mp4 |
@PabloBuchu could you possibly record with localstorage open? (Application -> Local Storage), and have the (note that if you're opening the project somewhere else, e.g. the browser or if the localStorage thing isn't helpful, maybe change this: const [projectStartupInfo, setProjectStartupInfo] =
React.useState<backendModule.ProjectStartupInfo | null>(null); into: const [projectStartupInfo, setProjectStartupInfo] =
hooks.useDebugState<backendModule.ProjectStartupInfo | null>(null); |
@somebody1234 I recorded a properly working flow in Screen.Recording.2023-08-25.at.09.05.31.mp4 |
side note: i just realized that projects that aren't visible, are not closed (because of course, the frontend doesn't know about them). maybe it means the backend should eventually close the user's previously opened project itself edit: or perhaps they should stay open, because the user may have it open on another device??? |
Pull Request Description
Fix issues restoring cloud projects that have been closed.
On current develop, the frontend assumes cloud projects are still open from the last time they were open. If this is not the case, it tries to open WebSocket endpoints that no longer exist
Important Notes
For a relatively easy way to test:
Enso.dmg
or./ide run watch
localhost:8080
Should also test restoring local projects to make sure that didn't break.
I was unable to properly test cloud projects (the one I tested with opened, but was blank with just the IDE background and no cursor and no nodes, for some reason)
Checklist
Please ensure that the following checklist has been satisfied before submitting the PR:
The documentation has been updated, if necessary.Screenshots/screencasts have been attached, if there are any visual changes. For interactive or animated visual changes, a screencast is preferred.Scala,
Java,
and
Rust
style guides. In case you are using a language not listed above, follow the Rust style guide.
Unit tests have been written where possible.If GUI codebase was changed, the GUI was tested when built using./run ide build
.