You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I noticed these logs on a Crashlytics report, and I'm not sure how they would be possible to create.
My Flutter app assigns a unique number to each network request, and this number is included in the logs.
The implementation is roughly:
int _id =0; // global// ...@overrideFuture<Response> invokeAPI(args) async {
int id =++_id;
logger.fine('[invokeAPI #$id] $basePath$path');
final sw =Stopwatch()..start();
final response =awaitsuper.invokeAPI(args);
sw.stop();
logger.fine('[invokeAPI #$id] Response after ${sw.elapsedMilliseconds/1000}s from $basePath$path');
return response;
}
The important detail is that the number is a global private variable which is only ever mutated in this one spot.
Yet the logs below from this crashlytics report seem to indicate multiple instances of this code is running!
Result of clicking the "Download .log" button in Crashlytics (somewhat redacted)
Notice how the timestamps from both crashlytics itself and the package:logging log output are sequential, yet somehow there are two separate counter sequences (one in the 3600s and one in the 12000s).
If this was a bug with how Crashlytics combines logs from different app sessions, you'd expect there to be two sets of disjoint timestamps as well.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
I noticed these logs on a Crashlytics report, and I'm not sure how they would be possible to create.
My Flutter app assigns a unique number to each network request, and this number is included in the logs.
The implementation is roughly:
The important detail is that the number is a global private variable which is only ever mutated in this one spot.
Yet the logs below from this crashlytics report seem to indicate multiple instances of this code is running!
Result of clicking the "Download .log" button in Crashlytics (somewhat redacted)
Notice how the timestamps from both crashlytics itself and the
package:logging
log output are sequential, yet somehow there are two separate counter sequences (one in the 3600s and one in the 12000s).If this was a bug with how Crashlytics combines logs from different app sessions, you'd expect there to be two sets of disjoint timestamps as well.
Does anyone have any ideas?
Beta Was this translation helpful? Give feedback.
All reactions