Invalid Session Exception when time passes after logging in

I initiate Realm and App globally through the Application class:

Then I check if a user is logged in.

If there is no user logged in the application sends you to the login screen so you can log in. After logging in, Mongodb Realm functions are called but after a while, when calling a function, it throws the Invalid Session exception.

To be able to call a function again I have to uninstall the application and log in again.

At the moment I’m not using a synchronized Realm, I just interact with the functions through the App.
Why is this exception thrown? Doesn’t the SDK update the user’s session automatically? Does it have something to do with the fact that he doesn’t use a synchronised Realm?

Hey, thanks for the detailed report. I too encountered this and reported it here: We’re working on a fix (see associated PR) and hope to have it released very soon.

1 Like

This topic was automatically closed 5 days after the last reply. New replies are no longer allowed.