If Pachli Current crashes it normally allows you to e-mail a crash report to [email protected] which can help troubleshoot the problem. Sometimes that might not work. In this case you can retrieve and e-mail the log yourself. This document explains how.
Before reading this document you should:
- Be comfortable installing and running command line tools.
- Have a computer running Linux, Windows, or OS X.
- (optional) Have a USB cable to connect your Android device to your computer. Some devices can connect wirelessly.
After reading this document you will know how to:
- Download the official
adbtool, which can read the logs from your device. - Allow
adbto connect to your device. - Run
adband collect logs from Pachli Current.
This is a summary of more detailed information at Android Debug Bridge (adb) | Android Studio | Android Developers
adb (Android Debug Bridge) is a command line tool that can connect to your Android device and perform various operations. It is typically used by application developers.
To install adb:
- Go to SDK Platform Tools release notes
- Download the appropriate "SDK Platform-Tools" for your computer.
- Extract the files from the archive.
Step 3 creates platform-tools/adb wherever you extracted the archive. There is no "install" step, the command can be run from the directory it was extracted to.
You must enable "Developer mode" on your device before adb will connect. In general this involves finding your device's Developer options screen and enabling "Developer mode".
How to do this varies from device to device.
Enable developer options explains how to do this for a range of devices.
After enabling "Developer mode" you must also enable "USB Debugging" on your device.
How to do this varies from device to device.
Enable debugging on your device explains how to do this for a range of devices.
Plug your device into your computer using a USB cable.
Your device will probably display a dialog asking if you trust the device you have connected to. Confirm this.
- Change to the directory that contains
adb, extracted at the "Downloadingadb" step. This is probably calledplatform-tools. - Run
adb devices(possibly./adb devicesif the current directory is not in yourPATH)
You should see output similar to this:
List of devices attached
4C181JEKB16142 deviceThis confirms that adb can connect to your device.
Run adb logcat.
You should see tens or hundreds of lines scroll up the screen.
Press Ctrl-C to stop viewing the log.
If Pachli Current is running on your device, stop it.
- Open "Recent applications". Depending on your device you might press the "square" button on the bottom bar, or swipe up from the bottom of the screen.
- Find Pachli Current in the list of recent applications.
- Close Pachli Current. Depending on your device you might have to swipe it away, or press an X button.
Run the following command
adb shell 'am start -W -n app.pachli.current/app.pachli.feature.intentrouter.IntentRouterActivity; logcat --pid=$(pidof app.pachli.current)'Note: That is a single line. The single quotes (
') befoream startand at the end are important. Do not use double quotes (").
Pachli Current should start, and you should see log entries appearing on screen.
Note: The command:
- Connects to your device (
am shell)- Starts Pachli Current, and waits for it to start (
am start -W -n app.pachli.current/app.pachli.feature.intentrouter.IntentRouterActivity)- Displays just the logs from the Pachli Current process (
logcat --pid=$(pidof app.pachli.current))
Press Ctrl-C to cancel capturing the logs.
Note: In my testing this sometimes leaves the terminal in an inconsistent state. If that happens to you run
stty saneto fix it.
Exactly as before.
Run the following command:
adb shell 'am start -W -n app.pachli.current/app.pachli.feature.intentrouter.IntentRouterActivity; logcat --pid=$(pidof app.pachli.current)' > pachli-current.logWait for Pachli Current to crash, then press Ctrl-C to cancel capturing the logs.
Compress the pachli-current.log file you just created (e.g., as a zip file), and e-mail the file to [email protected]
Open your device's settings, find the "USB Debugging" option you enabled earlier, and disable it.