-
Type: Bug
-
Resolution: Incomplete
-
Priority: Trivial - P5
-
None
-
Affects Version/s: None
-
Component/s: None
How frequently does the bug occur?
Unexpectedly on Production for 5% of users
Description
Hi
I’m using @realm/react with flexible sync. My problem is after I login the app is stuck on the spinner from the fallback prop of the RealmProvider. However if I close and open the app again it still showing the loader till 8-10 minutes in some case, also this is not happening to all user it only happening to 5% of user, and occurrence pattern is unrecognizable.
Here is my code:
import React from 'react'; import {AppProvider, UserProvider, createRealmContext} from '@realm/react'; import LoginComponent from './App/Components/Views/Login'; import DemoComponent from './App/Components/Views/Demo'; import LoadingSpinner from './App/Shared/LoadingSpinner'; import {TemplateCategorySchema} from './App/RealmModels/schema'; function App(): JSX.Element { const realmConfig: Realm.Configuration = { schema: [ TemplateCategorySchema ], }; const { RealmProvider } = createRealmContext(realmConfig); return ( <AppProvider id={'dynamicforms-qa-jqtpx'}> <UserProvider fallback={LoginComponent}> <RealmProvider sync={{ flexible: true, }} fallback={() => <LoadingSpinner />}> <DemoComponent /> </RealmProvider> </UserProvider> </AppProvider> ) } export default App;
For some users spinner stays for minutes even if user close and reopen app issue persist for some time.
Please recommend what I'm missing here, also it is very helpful if you have any idea of the root cause.
Stacktrace & log output
No response
Can you reproduce the bug?
Sometimes
Reproduction Steps
This is happening for some of user it is not getting reproduce in debugging phase
Version
0.3.2
What services are you using?
Atlas Device Sync
Are you using encryption?
No
Platform OS and version(s)
iOS iPhone 14Pro
Build environment
This is happening on Production environment
Cocoapods version
1.15.0