System:
OS: Windows 10
CPU: x64 Intel(R) Core(TM) i7-8650U CPU @ 1.90GHz
Memory: 5.89 GB / 15.84 GB
Binaries:
npm: 5.6.0 - C:\Program Files\nodejs\npm.CMD
Watchman: 4.9.4 - C:\Users\User\watchman\watchman.EXE
IDEs:
Android Studio: Version 3.1.0.0 AI-173.4907809
When I try to upgrade my version from 0.56 to 0.57, I am getting some kind of error with the babel-preset-react native:
git-upgrade ERR! An error occurred during upgrade:
git-upgrade ERR! Error: Plugin 0 specified in "C:\\Users\\User\\Documents\\Test\\node_modules\\babel-preset-react-native\\index.js" provided an invalid property of "default" (While processing preset: "C:\\Users\\User\\Documents\\Test\\node_modules\\babel-preset-react-native\\index.js")
at Plugin.init (C:\Users\User\AppData\Roaming\npm\node_modules\react-native-git-upgrade\node_modules\babel-core\lib\transformation\plugin.js:131:13)
at Function.normalisePlugin (C:\Users\User\AppData\Roaming\npm\node_modules\react-native-git-upgrade\node_modules\babel-core\lib\transformation\file\options\option-manager.js:152:12)
at C:\Users\User\AppData\Roaming\npm\node_modules\react-native-git-upgrade\node_modules\babel-core\lib\transformation\file\options\option-manager.js:184:30
at Array.map (<anonymous>)
at Function.normalisePlugins (C:\Users\User\AppData\Roaming\npm\node_modules\react-native-git-upgrade\node_modules\babel-core\lib\transformation\file\options\option-manager.js:158:20)
at OptionManager.mergeOptions (C:\Users\User\AppData\Roaming\npm\node_modules\react-native-git-upgrade\node_modules\babel-core\lib\transformation\file\options\option-manager.js:234:36)
at C:\Users\User\AppData\Roaming\npm\node_modules\react-native-git-upgrade\node_modules\babel-core\lib\transformation\file\options\option-manager.js:265:14
at C:\Users\User\AppData\Roaming\npm\node_modules\react-native-git-upgrade\node_modules\babel-core\lib\transformation\file\options\option-manager.js:323:22
at Array.map (<anonymous>)
at OptionManager.resolvePresets (C:\Users\User\AppData\Roaming\npm\node_modules\react-native-git-upgrade\node_modules\babel-core\lib\transformation\file\options\option-manager.js:275:20)
git-upgrade ERR! Restore initial sources
Note: checking out 'project-snapshot'.
You are in 'detached HEAD' state. You can look around, make experimental
changes and commit them, and you can discard any commits you make in this
state without impacting any branches by performing another checkout.
If you want to create a new branch to retain commits you create, you may
do so (now or later) by using -b with the checkout command again. Example:
git checkout -b <new-branch-name>
HEAD is now at 43d94ce Project snapshot
react-native init Test
cd Test
react-native-git-upgrade
Can you run react-native info and edit your issue to include these results under the Environment section?
If you believe this information is irrelevant to the reported issue, you may write [skip envinfo] under Environment to let us know.
@ferily7 In my case reverting babel-preset-react-native fixed the issue.
Run
npm install [email protected] --save-dev
And check whether that fixes this particular issue.
@ferily7 In my case reverting
babel-preset-react-nativefixed the issue.Run
npm install [email protected] --save-devAnd check whether that fixes this particular issue.
It worked for me.
Most helpful comment
@ferily7 In my case reverting
babel-preset-react-nativefixed the issue.Run
And check whether that fixes this particular issue.