react-native-router-flux v3.38.1
react-native v0.42.3
yarn install is causing react-native v0.42.3 and react-native v0.41.1 to be installed
Should react and react-native be installed as a peerDependency for react-native-router-flux?
To repro:
react-native init {projectName} --version=0.42.3
cd {projectName}
yarn add react-native-router-flux
npm start
You should see
Failed to build DependencyGraph: @providesModule naming collision:
Duplicate module name: react-animated
Paths: /Users/bdewitt/sandbox/break/node_modules/react-native-router-flux/node_modules/react-native/Libraries/Animated/release/package.json collides with /Users/bdewitt/sandbox/break/node_modules/react-native/Libraries/Animated/release/package.json
This error is caused by a @providesModule declaration with the same name across two different files.
Error: @providesModule naming collision:
Duplicate module name: react-animated
Paths: /Users/bdewitt/sandbox/break/node_modules/react-native-router-flux/node_modules/react-native/Libraries/Animated/release/package.json collides with /Users/bdewitt/sandbox/break/node_modules/react-native/Libraries/Animated/release/package.json
This error is caused by a @providesModule declaration with the same name across two different files.
at HasteMap._updateHasteMap (/Users/bdewitt/sandbox/break/node_modules/react-native/packager/src/node-haste/DependencyGraph/HasteMap.js:158:13)
at p.getName.then.name (/Users/bdewitt/sandbox/break/node_modules/react-native/packager/src/node-haste/DependencyGraph/HasteMap.js:133:31)
yarn add [email protected]
Should succeed
Came here to post the same issue, looks like it was accidentally added to the dependencies in this commit: https://github.com/aksonov/react-native-router-flux/commit/34e2d7ac7eb09489c2fd7f19844bd38e27e969fc
I believe It should be listed as a peerDependency instead
I've been tearing my hair out over this issue, glad to come across the root of the problem
jest-haste-map: @providesModule naming collision:
Duplicate module name: react-native
Paths: /Users/${username}/Desktop/${appName}/node_modules/react-native-router-flux/node_modules/react-native/package.json collides with /Users/${username}/Desktop/${appName}/node_modules/react-native/package.json
This warning is caused by a @providesModule declaration with the same name across two different files.
Failed to build DependencyGraph: @providesModule naming collision:
Duplicate module name: react-native-vector-icons
Paths: /Users/${username}/Desktop/${appName}/node_modules/react-native/local-cli/core/__fixtures__/files/package.json collides with /Users/${username}/Desktop/${appName}/node_modules/react-native-router-flux/node_modules/react-native/local-cli/core/__fixtures__/files/package.json
This error is caused by a @providesModule declaration with the same name across two different files.
Error: @providesModule naming collision:
Duplicate module name: react-native-vector-icons
Paths: /Users/${username}/Desktop/${appName}/node_modules/react-native/local-cli/core/__fixtures__/files/package.json collides with /Users/${username}/Desktop/${appName}/node_modules/react-native-router-flux/node_modules/react-native/local-cli/core/__fixtures__/files/package.json
This error is caused by a @providesModule declaration with the same name across two different files.
at HasteMap._updateHasteMap (/Users/${username}/Desktop/${appName}/node_modules/react-native/packager/src/node-haste/DependencyGraph/HasteMap.js:158:13)
at p.getName.then.name (/Users/${username}/Desktop/${appName}/node_modules/react-native/packager/src/node-haste/DependencyGraph/HasteMap.js:133:31)
Removing react-native-router-flux
from my package.json and reinstalling node_modules causes no errors so it's definitely react-native-router-flux
.
Same issue
Same here, please update the package
yeah this has been destroying my day as well. as a quick work around, you can just go delete the dupe of react-native out of the node_modules folder within react-native-router-flux. Ugly, but will at least get you up and running for the time being
+1
reinstall 3.38.0 for now
npm install --save [email protected]
It's not related to yarn I believe. Because even if I install it with npm I get the same issue. I deleted my node_modules folder and cleared the npm cache, but the issue was persistent. Currently, I went ahead with a workaround which I read on a GitHub issue where I have to delete the node_modules/react-native-router-flux/node_modules/react-native package. I hope they fix this issue soon.
same here
Waiting for the fix I rollback to [email protected]
same here
Got wrecked by this too. Fixed with the rollback to 3.38.0
watchman watch-del-all
rm -rf node_modules && npm install
npm uninstall react-native-router-flux
npm install --save [email protected]
rm -fr $TMPDIR/react-*
npm cache clean
npm start -- --reset-cache
Same by me, had to remove the react-native directory inside react-native-router-flux manually to make things work.
yep, either rollback or remove the folder manually, thanks for the workarounds
Hope the problem is resolved in next release.
same issue, please help to fix
Rolling back to 3.38.0 fixed the issue for me, thanks a lot guys!
Same here, back to 3.38.0 fixed it. Thank you!
+1
thanks!
I'll get the champagne ready!
Same issue, solved rolling back to 3.38.0
Rolling back to v0.38.0 or just deleting the react-native folder inside react-native-router-flux/node_modules/ and also delete symlink to react-native inside react-native-router-flux/node_modules/.bin/ will work for now.
Posting the above for convenience copy & paste 😄
watchman watch-del-all && rm -rf node_modules && npm install && npm uninstall react-native-router-flux && npm install --save [email protected] && rm -fr $TMPDIR/react-* && npm cache clean && npm start -- --reset-cache
stuck just now,thanks
+1
What worked for me was this sequence:
watchman watch-del-all
rm -rf node_modules && npm install
npm uninstall react-native-router-flux
npm install --save [email protected]
rm -fr $TMPDIR/react-*
npm cache clean
npm install --save [email protected]
npm start -- --reset-cache
Tried all the above steps and the errors went away but the router doesnt and scenes donot render the components. Double checked if they are being fetched properly and they are . Not sure why
Tried command line's fix and this worked to get my build working without errors but when i run my unit tests with jest its complaining it can not find the node_module folders in the react-native-router-flux folder. Looks like jest is still getting a reference to these folders :(
Does anyone know where Jest reference's this from ?
ENOENT: no such file or directory, stat '/{projectDirectory}/node_modules/react-native-router-flux/node_modules/react-native/Libraries/Core/ErrorUtils.js
@geecurve got the same error and nothing npm cache clean
, yarn cache clean
, even rm -rf node_modules
got it working. What I find out that original project directory was dead so created new one with small case. Executed yarn install
and project was ready to build and test.
@prtkkmrsngh did you delete the react-native folder inside of /node_modules/react-native-router-flux? Or revert to react-native-router-flux 3.38.0
?
@MattyK14 revert to 3.38.0 and upgraded RN to 0.44
Please guys,
how to a can resolver this error?
[email protected]
├── lodash.[email protected]
├── UNMET PEER DEPENDENCY [email protected]
├── [email protected]
├─┬ [email protected]
│ └── [email protected]
├─┬ [email protected]
│ └─┬ [email protected]
│ ├─┬ [email protected]
│ │ └── [email protected]
│ └── [email protected]
├─┬ [email protected]
│ └── [email protected]
└── [email protected]
@nazaslater fix your version to "react-native-router-flux": "3.38.0", you have 3.38.1
Thanks @Tonacatecuhtli
Its been a month, any chance of making the tiny fix that can end this bug?
@aksonov please fix issue. 3.39.2
😥
@abdurrahmanekr @asokol Can we publish this into npm its still showing 3.39.1 as the latest https://www.npmjs.com/package/react-native-router-flux
it's 3.39.2 now
Most helpful comment
Got wrecked by this too. Fixed with the rollback to 3.38.0