Stack: TypeError: undefined: Cannot read property 'message' of undefined
at Function.getWrappedError (/Users/esteban/.vscode/extensions/vsmobile.vscode-react-native-0.5.7/src/common/error/internalError.js:35:16)
at Function.wrapError (/Users/esteban/.vscode/extensions/vsmobile.vscode-react-native-0.5.7/src/common/error/errorHelper.js:18:44)
at __dirname.handleErrors.resultOfCode.done.reason (/Users/esteban/.vscode/extensions/vsmobile.vscode-react-native-0.5.7/src/common/entryPointHandler.js:40:72)
at _rejected (/Users/esteban/.vscode/extensions/vsmobile.vscode-react-native-0.5.7/node_modules/q/q.js:844:24)
at /Users/esteban/.vscode/extensions/vsmobile.vscode-react-native-0.5.7/node_modules/q/q.js:870:30
at Promise.when (/Users/esteban/.vscode/extensions/vsmobile.vscode-react-native-0.5.7/node_modules/q/q.js:1122:31)
at Promise.__dirname.Promise.promise.promiseDispatch (/Users/esteban/.vscode/extensions/vsmobile.vscode-react-native-0.5.7/node_modules/q/q.js:788:41)
at /Users/esteban/.vscode/extensions/vsmobile.vscode-react-native-0.5.7/node_modules/q/q.js:604:44
at runSingle (/Users/esteban/.vscode/extensions/vsmobile.vscode-react-native-0.5.7/node_modules/q/q.js:137:13)
at flush (/Users/esteban/.vscode/extensions/vsmobile.vscode-react-native-0.5.7/node_modules/q/q.js:125:13)```
Are you following the Debugging Expo applications instructions? You should, I think, be executing Debug in Exponent to debug the app
No matter what I do if I use "Attach to packager" one or "Debug in Exponent" the message is the same.. In both cases the output in the terminal is blank and VS Code spawn an alert "Debug adapter process has terminated unexpectedly".
Hi @garciawarneckee
Is it CRAN or exp init project?
I've tried falta-uno-app from your Github and it works great for me
CRAN is for create-react-native-app ? I'm using nvm to set node.js version Idk if it's useful data...
Yes, I meant create-react-native-app.
Could you please check outputs one more time and paste here if not empty
* Output of the Debug Console (View -> Toggle Debug Console)
* Output of the React-Native output channel (View -> Toggle Output -> Select React-Native in ListBox)
* Output of the React-Native: Android output channel (View -> Toggle Output -> Select React-Native: Android in ListBox)
* Output of the Developer Tools console (Help -> Toggle Developer Tools -> Select Console tab)
Also if it possible, could you please create a little project to repro
Hi @garciawarneckee, just a friendly ping, please let me know if the issue still has place for you and if you have a chance to take a look at the message above.
Trying to run on Android gives me the same error message.
Command Pallette -> Run Android on Simulator
[Error] Failed to run the application in Android
Stack: TypeError: Failed to run the application in Android: Cannot read property 'message' of undefined
at Function.getWrappedError (C:\Users\joaopaulo\.vscode\extensions\vsmobile.vscode-react-native-0.5.7\src\common\error\internalError.js:35:16)
at Function.wrapError (C:\Users\joaopaulo\.vscode\extensions\vsmobile.vscode-react-native-0.5.7\src\common\error\errorHelper.js:18:44)
at resultOfCode.done.reason (C:\Users\joaopaulo\.vscode\extensions\vsmobile.vscode-react-native-0.5.7\src\common\entryPointHandler.js:40:72)
at _rejected (C:\Users\joaopaulo\.vscode\extensions\vsmobile.vscode-react-native-0.5.7\node_modules\q\q.js:844:24)
at C:\Users\joaopaulo\.vscode\extensions\vsmobile.vscode-react-native-0.5.7\node_modules\q\q.js:870:30
at Promise.when (C:\Users\joaopaulo\.vscode\extensions\vsmobile.vscode-react-native-0.5.7\node_modules\q\q.js:1122:31)
at Promise.promise.promiseDispatch (C:\Users\joaopaulo\.vscode\extensions\vsmobile.vscode-react-native-0.5.7\node_modules\q\q.js:788:41)
at C:\Users\joaopaulo\.vscode\extensions\vsmobile.vscode-react-native-0.5.7\node_modules\q\q.js:604:44
at runSingle (C:\Users\joaopaulo\.vscode\extensions\vsmobile.vscode-react-native-0.5.7\node_modules\q\q.js:137:13)
at flush (C:\Users\joaopaulo\.vscode\extensions\vsmobile.vscode-react-native-0.5.7\node_modules\q\q.js:125:13)
at _combinedTickCallback (internal/process/next_tick.js:73:7)
at process._tickDomainCallback (internal/process/next_tick.js:128:9)
When trying to Debug -> Debug Android it gives me another error.
I have noticed the launchReactNative.js is not being generated when I open the project (CRAN) from the CLI, Open Folder or Open With VSCode from explorer.
package.json
{
"name": "test",
"version": "0.1.0",
"private": true,
"devDependencies": {
"jest-expo": "25.0.0",
"react-native-scripts": "1.11.1",
"react-test-renderer": "16.2.0"
},
"main": "./node_modules/react-native-scripts/build/bin/crna-entry.js",
"scripts": {
"start": "react-native-scripts start",
"eject": "react-native-scripts eject",
"android": "react-native-scripts android",
"ios": "react-native-scripts ios",
"test": "node node_modules/jest/bin/jest.js"
},
"jest": {
"preset": "jest-expo"
},
"dependencies": {
"@expo/vector-icons": "^6.2.2",
"expo": "^25.0.0",
"native-base": "^2.3.7",
"react": "16.2.0",
"react-native": "0.52.0"
}
}
If I'm missing some configuration step, let me know :)
@sergey-akhalkov I could track down what was the problem in my case. I was missing react-native-cli from my global modules.
So what I had to do was npm install -g react-native-cli and it got the packager to start.
Also to be noted: the extension is still not generating the launchReactNative.js file for me.
@garciawarneckee, I'm closing this for now, please feel free to reopen or create new one if you have any updates.
@jpsouzasilva, sorry for the delayed response, I'm closing this issue, so could you please create new one if the issue still has place for you and share your problem and environment there?
Even I get the same problem. I am using a Macbook.
[Error] Failed to start the React Native packager
Stack: TypeError: Failed to start the React Native packager: Cannot read property 'message' of undefined
at Function.getWrappedError (/Users/kashishgrover/.vscode/extensions/vsmobile.vscode-react-native-0.6.6/src/common/error/internalError.js:35:16)
at Function.wrapError (/Users/kashishgrover/.vscode/extensions/vsmobile.vscode-react-native-0.6.6/src/common/error/errorHelper.js:18:44)
at resultOfCode.done.reason (/Users/kashishgrover/.vscode/extensions/vsmobile.vscode-react-native-0.6.6/src/common/entryPointHandler.js:40:72)
at _rejected (/Users/kashishgrover/.vscode/extensions/vsmobile.vscode-react-native-0.6.6/node_modules/q/q.js:844:24)
at /Users/kashishgrover/.vscode/extensions/vsmobile.vscode-react-native-0.6.6/node_modules/q/q.js:870:30
at Promise.when (/Users/kashishgrover/.vscode/extensions/vsmobile.vscode-react-native-0.6.6/node_modules/q/q.js:1122:31)
at Promise.promise.promiseDispatch (/Users/kashishgrover/.vscode/extensions/vsmobile.vscode-react-native-0.6.6/node_modules/q/q.js:788:41)
at /Users/kashishgrover/.vscode/extensions/vsmobile.vscode-react-native-0.6.6/node_modules/q/q.js:604:44
at runSingle (/Users/kashishgrover/.vscode/extensions/vsmobile.vscode-react-native-0.6.6/node_modules/q/q.js:137:13)
at flush (/Users/kashishgrover/.vscode/extensions/vsmobile.vscode-react-native-0.6.6/node_modules/q/q.js:125:13)
at _combinedTickCallback (internal/process/next_tick.js:73:7)
at process._tickDomainCallback (internal/process/next_tick.js:128:9)
Hi @kashishgrover please double-check whether you open React Native based project not the directory on the upper/lower level of it.
@ruslan-bikkinin oh shit thank you so much. We use a Monorepo structure and I never thought that could be the issue. It works flawlessly now. 馃槃
Most helpful comment
Hi @kashishgrover please double-check whether you open React Native based project not the directory on the upper/lower level of it.