Skip to content
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

Workspace changes not auto saved when application gracefully crashes #35

Closed
Kirlac opened this issue Jan 16, 2020 · 3 comments
Closed
Assignees
Labels
bug Something isn't working

Comments

@Kirlac
Copy link

Kirlac commented Jan 16, 2020

When the app crashes I lose everything that was set up since the application was last closed. I added a collection with a couple of requests, set up my environment/filled in my variables etc. and then ran the first request. It submitted to my api server and appeared to process successfully there however Nightingale decided to pop up an error stating it has to shut down because it couldn't parse the uri (or something to that effect). After acknowledging the error message, nightingale closed as it suggested it would and helpfully discarded all of my unsaved work.

Some potential improvement suggestions:

  • Cache unsaved workspace changes: effectively auto save every change as it happens (instead of on close), but just cache this in a temporary file rather than updating the current workspace. That way unsaved changes can be recovered later if necessary (or easily discarded if not) without overwriting the saved workspace. The saved workspace can still then be updated with the "save on close" setting as per normal and the cached version can be removed until there are further changes.

  • Have the app honor the "save on close" setting and attempt to save the workspace when it needs to shut down. If the application is aware enough to tell me it's about to crash, it should be aware enough to save the workspace first. Even better, the "I'm about to crash" dialog could give the option to save (probably "save as") or discard changes before closing.

I will try to do some debugging and get a repro for the invalid uri parsing crash once I get my workspace set back up. Then I can file a new issue for the crash specifically as the request definitely made it to my server before nightingale decided the uri couldn't be parsed so that seems a bit off.
EDIT: My crash issue seems to be covered by #31 so I will update there if I find any more details.

Version info: Nightingale (free) v3.2.1.0

@dpaulino
Copy link
Contributor

dpaulino commented Jan 16, 2020

Thanks for creating the issue, and I'm sorry about the inconvenience. I really appreciate the details you provided, and I will investigate saving on close.

Please do let me know if you end up finding the cause of the crash. I am working on #31 right now, but I'd like to address the cause of your crash as well.

@dpaulino dpaulino self-assigned this Jan 16, 2020
@dpaulino dpaulino added the bug Something isn't working label Jan 16, 2020
@Kirlac
Copy link
Author

Kirlac commented Jan 16, 2020

Thanks @dpaulino - I don't think it's necessarily a major issue assuming the application doesn't usually crash. I did a little more testing to narrow down what was causing the host parsing error and my situation does seem to be the same as #31 (as far as I can tell. I get the same error popup in the same condition) so I have commented there with my findings - it seems to be a problem with variables in the host part of the url.

Thanks for all of your hard work on this. It's a really nice application aside from this little bug.

@dpaulino
Copy link
Contributor

Just finished up work on this. Once the next update is released, Nightingale will save your workspace upon crashing. Thanks again for this valuable feedback!

@dpaulino dpaulino added pending release Work completed. Will be available in a future release. and removed pending release Work completed. Will be available in a future release. labels Jan 25, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants