profile
viewpoint

Ask questionsError while executing command 'react-native.cmd run-android --no-packager': Error while executing command 'react-native.cmd run-android --no-packager' (error code 101)

Actual Behavior

  1. Error while executing command 'react-native.cmd run-android --no-packager': Error while executing command 'react-native.cmd run-android --no-packager' (error code 101)

Expected Behavior

  1. Start Debugging

Software versions

  • VSCode version: 1.33.1
  • OS platform and version: Windows_NT x64 10.0.17763
  • NodeJS version: 10.2.0
  • react-native-cli: 2.0.1 -react-native: 0.61.2

Outputs (Include if relevant)

  • Output of the Debug Console (View -> Toggle Debug Console): OS: win32 x64 Adapter node: v10.2.0 x64 vscode-chrome-debug-core: 6.8.2 Could not debug. Error while executing command 'react-native.cmd run-android --no-packager': Error while executing command 'react-native.cmd run-android --no-packager' (error code 101)
PASTE OUTPUT HERE
  • Output of the React-Native output channel (View -> Toggle Output -> Select React-Native in ListBox): [Warning] Target simulator is not supported for Android platform. If you want to use particular device or simulator for launching Android app, please specify device id (as in 'adb devices' output) instead.

[Info] local.properties file doesn't exist. Using Android SDK location from PATH.

[Info] Starting React Native Packager.

error Unrecognized command "run-android". info Run "react-native --help" to see a list of all available commands.

PASTE OUTPUT HERE
  • Output of the Developer Tools console (Help -> Toggle Developer Tools -> Select Console tab): [Extension Host] debugger listening on port 26104 console.ts:134 [Extension Host] (node:58948) [DEP0005] DeprecationWarning: Buffer() is deprecated due to security and usability issues. Please use the Buffer.alloc(), Buffer.allocUnsafe(), or Buffer.from() methods instead. t.log @ console.ts:134 extensionHost.ts:215 Extension Host extensionHost.ts:216 Debugger attached.

console.ts:134 [Extension Host] (node:58948) [DEP0022] DeprecationWarning: os.tmpDir() is deprecated. Use os.tmpdir() instead.

PASTE OUTPUT HERE
microsoft/vscode-react-native

Answer questions SounD120

@galla-devlop

  1. With respect to errors in a freshly created app, I'd recommend to clear your Gradle caches with the following commands and then try to build an application:
gradle clean --refresh-dependencies
RD /Q /S %USERPROFILE%\.gradle\caches
  1. With respect to SmapleApp application error I'd recommend you to reinstall node_modules and then try to run Debug Android. To do that you can use the following commands from your SmapleApp project root:
RD /Q /S node_modules
npm install

Could you please try that recommendations and let us know about the results?

useful!

Related questions

[Error] TypeError: ConfigUtils(...).configFilenameAsync is not a function hot 134
Can't attach packager for debugging hot 106
Error while executing command 'react-native.cmd run-android --no-packager' (error code 101) hot 99
/bin/sh: 1: adb: not found on Linux hot 55
Cannot bind listener: operation not permitted hot 49
Error while executing command 'react-native run-ios --simulator --no-packager' hot 39
Cannot read property 'getCurrentUserAsync' of undefined hot 26
Cannot bind listener: operation not permitted hot 23
Current workspace does not contain React Native projects hot 22
Unable to resolve module `../Components/AccessibilityInfo/AccessibilityInfo` message hot 21
Version 0.13 breaks running packager from VS Code from different folder hot 15
Could not debug - error code 604 hot 13
Not all success patterns were matched. (error code 712) hot 12
Current workspace does not contain React Native projects hot 11
Expo app doesn't connect to packager hot 10
Github User Rank List