# debug-native-android.mo

## Owner: [Yann Leflour](https://github.com/yleflour)

## Debug Android code

### Prerequisites

* [ ] Have [Android Studio](https://developer.android.com/studio/index.html) installed

  **Steps**
* [ ] Open **Android Studio**
* [ ] Click on *File > Open*
* [ ] Navigate to and open */android*
* [ ] Run in debug mode from **Android Studio**

## Log Android Errors

### Prerequisites

* [ ] Have [Pidcat](https://github.com/JakeWharton/pidcat) installed

## Steps

* Connect the Android phone to your computer
* Make sure that the phone is available from your computer: `adb devices`
* Run: `pidcat <GRADLE_APP_IDENTIFIER>`
* See all the logs related to your app, requests, native and javascript logs and errors, etc.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://bamtech.gitbook.io/dev-standards/react-native/debugging/debug-native-android.mo.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
