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

fix: no longer hide exceptions when loading session file #125

Merged
merged 1 commit into from
Oct 16, 2023

Conversation

gigajuwels
Copy link
Contributor

@gigajuwels gigajuwels commented Oct 4, 2023

This PR will require that the session file can be de-serialized. If it can't be de-serialized, the entire Core init process should fail.

@gigajuwels gigajuwels mentioned this pull request Oct 4, 2023
@skibitsky
Copy link
Member

I agree that a deserialization failure should throw an exception here. However, I'm concerned about a situation where, if the session cache is already corrupted, the exception being thrown might prevent the core from initializing. In such a scenario, clients could get stuck, unable to reset the corrupted cache. They'd then have to initialize the proper storage separately and manually clear the cached session. Given this, perhaps we could catch the exception during Core initialization, log the error, delete the corrupted session, and then proceed with the Core initialization process?

@skibitsky
Copy link
Member

Just realised that it didn't hide exception: bc8c1f1#diff-ba33f66e80b057d0ef22533f2a00a6c8c68ef5395435e206c3a4f6a9a35e17c3L123

@skibitsky skibitsky merged commit a60ee65 into 2.0 Oct 16, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants