diff --git a/doc/debugging.md b/doc/debugging.md index de23494159..c8ad669244 100644 --- a/doc/debugging.md +++ b/doc/debugging.md @@ -45,6 +45,42 @@ To do this: ![geth.log path](images/debugging/geth-path.png) +## Inspecting database content + +Encrypted database can be found using commands: +``` +cd ~/Library/Developer/CoreSimulator/Devices +find ./ -name accounts.sql +``` + +To get unencrypted database you need to export it first: +- open the status app in simulator +- on login screen enter the correct password without logging in +- using repl execute statement to export db: + ``` + (re-frame.core/dispatch [:multiaccounts.login.ui/export-db-submitted]) + ``` +- save generated `export.db` file + +Now you can locate the `export.db` and open it with preferred db viewer. + +**Android:** + +```sh +adb root +adb pull /storage/emulated/0/Android/data/im.status.ethereum.debug/files/Download/export.db /path/to/store/export.db +``` + +If you're using a release build, change the path to `/storage/emulated/0/Android/data/im.status.ethereum/files/Download` + +**iOS** + +``` +cd ~/Library/Developer/CoreSimulator/Devices +find ./ -name export.db +``` + + ## Tips ### From @ilmotta: @@ -62,3 +98,4 @@ Also to inspect logs in a more flexible manner, instead of the strict output fro ``` adb logcat | grep 'ReactNativeJS\|StatusModule\|GoLog' ``` +