yashovardhan99 / HealersDiary

Healers Diary - an android app for healers to keep track of their patients and help in instant billing. The app is currently in development.
https://play.google.com/store/apps/details?id=com.yashovardhan99.healersdiary&utm_source=github&utm_campaign=github&pcampaignid=MKT-Other-global-all-co-prtnr-py-PartBadge-Mar2515-1
Apache License 2.0
8 stars 0 forks source link

Evolving idea - Storing logs in local cache for sending #74

Open yashovardhan99 opened 2 years ago

yashovardhan99 commented 2 years ago

Is your feature request related to a problem? Please describe. Currently, all logs are captured using Timber's DebugTree which only writes to the logcat. For production builds, a better solution will be writing the logs to a local file which can be shared for debugging.

Describe the solution you'd like This can be easily implemented using a Timber tree for release builds. Every time an exception is to be logged, we append it to a log file. The file is cleared on app start.

Describe alternatives you've considered Using crash handling libraries like Crashalytics can be expensive and requires internet; This solution works completely offline and the user can be presented with an option to send the logs via email.

Additional context When an uncaught exception occurs, we can prompt the user to send the logs captured via email. UI for this should ideally reside in a new activity. New activity can be started from Application class using FLAG_ACTIVITY_NEW_TASK.

Related SO answer

This will be in relation to commit 3045d78

stale[bot] commented 1 year ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.

stale[bot] commented 1 year ago

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.