Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Unable to see Android logs in react-native app using adb logcat: no matches found: *:S

Tags:

react-native

According to the official doc, typing adb logcat *:S ReactNative:V ReactNativeJS:V in the terminal will display all the Android Logs, however when I do so I get the following error message: no matches found: *:S. I have put Log statements in my custom native modules like so : Log.e(TAG, "Unsupported media type:" + type);.I searched for this problem online and found no solution(No one has had the same error as me, apparently).

I would like to add that the code is working fine.

like image 703
Frosty619 Avatar asked Apr 22 '16 19:04

Frosty619


People also ask

How do I view android logs in adb?

Navigate to device settings and enable Developer Options (see section for ADB logs) Navigate to Developer Options and tap on Take/Submit Bug Report. Select Full Report when prompted to get the full device info along with the logs.

How do you see logs in React Native?

Note that as of React Native 0.29 and later, you can get logs without running the debugger. Just run react-native log-ios or react-native log-android on the command line inside your project folder. And when you open the Remote JS Debugging, you have to press option+command+i and check the console.

Why is my Logcat not showing anything in Android?

Solution 1: Restarting your Android StudioIn your IDE Go to File > Invalidate Caches and Restart > Invalidate and Restart. This Solution will clear all the caches of Android studio IDE and restart it automatically, By the method, there are 80% change that Logcat will start work as before.


2 Answers

Try using:

adb logcat -s ReactNative:V ReactNativeJS:V

Source: https://developer.android.com/studio/command-line/logcat.html

like image 172
Luke Grayland Avatar answered Sep 23 '22 00:09

Luke Grayland


I am assuming that you are using zsh for the terminal. Try using it like this

adb logcat '*:S' ReactNative:V ReactNativeJS:V

Hope this will help.

like image 24
FaISalBLiNK Avatar answered Sep 22 '22 00:09

FaISalBLiNK