osfans / trime

同文安卓輸入法平臺3.x/Android-rime/Rime Input Method Engine for Android
http://osfans.github.io/trime/
GNU General Public License v3.0
3.09k stars 372 forks source link

引导用户应该如何捕捉错误日志 #646

Closed tumuyan closed 6 months ago

tumuyan commented 2 years ago

Is your feature request related to a problem? Please describe. 目前普通用户难以捕捉错误日志,导致无法有效反馈问题。

Describe the solution you'd like

  1. 在同文内增加错误日志收集、保存和上传的功能
  2. 引导用户使用一些工具采集错误日志 a. 使用adb工具采集日志。 b. 使用Android端能够过滤、保存日志的工具 我推荐这个 https://f-droid.org/zh_Hans/packages/com.tananaev.logcat/ <-我推荐这个做法,希望可以在wiki和“寻求帮助”页面增加指向这个工具的链接

Describe alternatives you've considered A clear and concise description of any alternative solutions or features you've considered.

Additional context Add any other context or screenshots about the feature request here.

rainhear commented 2 years ago

在同文内增加错误日志收集、保存和上传的功能

這項功能確實有很有用,無障礙版也有日誌記錄功能。

starriddle commented 2 years ago

啊,刚提了个bug,不知道怎么找日志。

建议内置日志功能,然后在设置里增加开关,有心的用户发现bug后,可以临时开启日志,复现bug并收集日志后来提交,平时就没必要一直记录了

tumuyan commented 2 years ago

实际上lig包含两部分:

  1. trime adb log (timber/Log)
  2. rime log file (glog)

针对后者,目前理论上应该是输出到tmp分区的,无法直接读取. 我们是否有应该输出到用户目录的log文件夹?或者增加一个选项,控制是否输出? @Bambooin

需要修改jni https://github.com/osfans/trime/blob/develop/app/src/main/jni/librime_jni/rime.cc#L48 初始化glig改为另一个方法 https://github.com/rime/librime/blob/99e269c8eb251deddbad9b0d2c4d965b228f8006/src/rime/setup.cc#L69

Bambooin commented 2 years ago

Can we borrow this project: https://github.com/TeamAmaze/AmazeFileManager

It's will show UI for error of app, and user can report to Github or email to developer.

tumuyan commented 2 years ago

It's will show UI for error of app, and user can report to Github or email to developer.

But errors are not always fatal. If popup or report frequency, users will increase their pressure and useless. Since librime already has a log system, why not show it to power users?

sharp-tasting commented 1 year ago

现在的版本虽然有了导出日志的功能,但是这个功能总是导出过量的日志(例如 https://github.com/osfans/trime/issues/844#issuecomment-1574441518 ),无法有效地进行分析。