2 Commits

Author SHA1 Message Date
Benoit Pierre
dad71c5ca4 tools/logcat: improve handling of input encoding (#14629)
For example, avoid a decoding exception on this line:
```
20:58:28.534 14160            reader.launche  F  thread.cc:1326] Check failed: FindStackTop() > reinterpret_cast<void*>(tlsPtr_.stack_end) (FindStackTop()=X���`���X���, reinterpret_cast<void*>(tlsPtr_.stack_end)=0xbe10c000)
```
2025-11-15 22:56:56 +01:00
Benoit Pierre
6e7ccf2320 android: add custom adb logcat formatter (#12385)
- standalone: no other dependencies than Python (>= 3.7) and adb
  (Android >= 4.3 [Jelly Bean])
- filter KOReader's traces, and other processes chatter about KOReader
  (e.g. mentions of its application ID or PID)
- show time, PID, TID (when different), tag, priority, and message
- only parse the log (don't rely on `adb shell` commands)
- can be used as a filter, including on its own (uncolored) output
- we can simplify instructions to users when asking for detailed logs

Why not use pidcat?
- project is unmaintained
- does not support Python 3 (need at least one extra patch)
- mangle long lines by wrapping them, even when not outputting to a terminal,
  which is a big no-no, IMHO (as it break searching, copy pasting, etc…)
2024-08-25 23:41:25 +02:00