-
Notifications
You must be signed in to change notification settings - Fork 180
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
debug flag ignored - errors logged #874
Comments
@ammarlakho @adamcclifton this is very weird. Thanks for the detailed report! The code that actually enables/disables through the Are you seeing this in device or in the simulator? Could you share your client config settings? Where do you instantiate your client? |
@oscb i figured out the reason why the logs were not stopping even when logger was disabled. We're using a DestinationPlugin (Moengage) and removing that makes the logs disappear too... No idea why that happens though lol |
@ammarlakho I'm very curious. Is this destination plugin for Moengage a custom one? |
@oscb The latest version for that library has fixed the issue (by letting us set a log level) though so we'll be upgrading soon |
Hi thanks for checking that out. I cant seem to reproduce in the same way now, with the visible error, but i can see where the problem is now. This does lead to more confusion tho, as on production that means all logs would be disabled, and we would want to report errors to bugsnag. But then again, "failed to send x events" is also an error, and we don't want that to go to bugsnag (the original issue). It feels like that should be more of a warning than an error, but that's probably up for debate. |
When
debug
is disabled in the config, debug errors and warnings are still firing.Primarily the "Failed to send # events." error.
I understand that this is not a problem for analytics, as these events are stored and sent later. But these errors are spamming our stability monitoring in production and cannot be disabled.
It seems like this problem was fixed in version 2.10.0 according to this issue:
#704
And if I roll back to version 2.10.0 things work as expected, the errors only appear if
debug: true
.So maybe there has been a regression in later releases?
analytics-react-native
version: 2.16.0 (and 2.15.0 at least)Steps to reproduce
debug: true
and wifi enabled.debug: false
and relaunch the app.debug
is disabled.Expected behavior
The "Failed to send # events." error does not appear when
debug
is set tofalse
Actual behavior
The "Failed to send # events." error is appearing when
debug
is set tofalse
The text was updated successfully, but these errors were encountered: