Closed
Description
Hi community !
🐛 Bug Report (?)
On a very recent react-native project, i've an Java exception
that (apparently) create an classic error 500 type InternalError
with metro bundler.
This error is with android-run
With classic npm start
, the error is other :
Loading dependency graph...(node:1363) UnhandledPromiseRejectionWarning: Error: jest-haste-map: @providesModule naming collision:
Duplicate module name: react-animated
Paths: /app/.cache/yarn/v4/npm-react-native-0.57.8-1a840fbe144cd3902cc14313a783ce28efc48cb9/node_modules/react-native/Libraries/Animated/release/package.json collides with /app/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 setModule (/app/node_modules/metro/node_modules/jest-haste-map/build/index.js:462:17)
at workerReply (/app/node_modules/metro/node_modules/jest-haste-map/build/index.js:512:9)
at process._tickCallback (internal/process/next_tick.js:68:7)
(node:1363) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 2)
(node:1363) [DEP0018] DeprecationWarning: Unhandled promise rejections are deprecated. In the future, promise rejections that are not handled will terminate the Node.js process with a non-zero exit code.
(node:1363) UnhandledPromiseRejectionWarning: Error: jest-haste-map: @providesModule naming collision:
Duplicate module name: react-animated
Paths: /app/.cache/yarn/v4/npm-react-native-0.57.8-1a840fbe144cd3902cc14313a783ce28efc48cb9/node_modules/react-native/Libraries/Animated/release/package.json collides with /app/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 setModule (/app/node_modules/metro/node_modules/jest-haste-map/build/index.js:462:17)
at workerReply (/app/node_modules/metro/node_modules/jest-haste-map/build/index.js:512:9)
at process._tickCallback (internal/process/next_tick.js:68:7)
(node:1363) UnhandledPromiseRejectionWarning: Unhandled promise rejection. This error originated either by throwing inside of an async function without a catch block, or by rejecting a promise which was not handled with .catch(). (rejection id: 3)
Environment
From Docker container :
React Native Environment Info:
System:
OS: Linux 4.15 Debian GNU/Linux 9 (stretch) 9 (stretch)
CPU: (12) x64 Intel(R) Core(TM) i7-8750H CPU @ 2.20GHz
Memory: 6.18 GB / 15.37 GB
Shell: 4.4.12 - /bin/bash
Binaries:
Node: 10.15.1 - /usr/bin/node
Yarn: 1.13.0 - /usr/bin/yarn
npm: 6.4.1 - /usr/bin/npm
SDKs:
Android SDK:
API Levels: 26, 27
Build Tools: 27.0.3
Has anyone ever had the problem ?
Thank you community !