Widget UI stops updating in the middle of counterProvider changes #3952
Unanswered
jegrasso19
asked this question in
Q&A
Replies: 1 comment
-
I doubt Riverpod bits are the issue here |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
I'm using a progress indicator and counterProvider to track the loading progress of data into a Drift SQLite database in my app. The counterProvider is used to show the percentage of data loaded. Half way through the loading process, the UI stops showing any progress. I've confirmed the counterProvider is updating correctly to the end using ref.listen so I can't figure out what's stopping the UI from showing completion to 100%. I have 40 steps to load my data so the counter increments by 2.5 for each step. The database typically loads in less than 4 seconds. Is there a limit to how quickly the provider can respond? It stops once the data is actually getting added to the database which is at step 20. Am I approaching this the wrong way?
I get the same results whether I'm using the iOS simulator or the Android simulator. I'm using a MacBook M4 Max, so I don't think it's a horsepower issue but it always stops once I start my batch insert of data into the database.
Here is my counterProvider:
Here is my progress indicator widget, which gets called during the loading phase of my .when call:
Here is a screenshot of my data loading. It always stops at 47.5%.
Beta Was this translation helpful? Give feedback.
All reactions