Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

error: bundling failed: Error: Unable to resolve module react-timer-mixin #23351

Closed
Bradzer opened this issue Feb 9, 2019 · 1 comment
Closed
Labels
Bug Resolution: Locked This issue was locked by the bot.

Comments

@Bradzer
Copy link

Bradzer commented Feb 9, 2019

🐛 Bug Report

I was just coding then I saved the changes and lauched the app.
And I got this error stack :

error: bundling failed: Error: Unable to resolve module `react-timer-mixin` from `<project_directory>/node_modules/native-base/dist/src/basic/Tabs/index.js`:Module `react-timer-mixin` does not exist in the Haste module map or in these directories:
  <home_dir>/Documents/node_modules

This might be related to https://github.com/facebook/react-native/issues/4968
To resolve try the following:
  1. Clear watchman watches: `watchman watch-del-all`.
  2. Delete the `node_modules` folder: `rm -rf node_modules && npm install`.
  3. Reset Metro Bundler cache: `rm -rf /tmp/metro-bundler-cache-*` or `npm start -- --reset-cache`.
  4. Remove haste cache: `rm -rf /tmp/haste-map-react-native-packager-*`.
    at ModuleResolver.resolveDependency (<project_directory>/node_modules/metro/src/node-haste/DependencyGraph/ModuleResolution.js:183:15)
    at ResolutionRequest.resolveDependency (<project_directory>/node_modules/metro/src/node-haste/DependencyGraph/ResolutionRequest.js:52:18)
    at DependencyGraph.resolveDependency (<project_directory>/node_modules/metro/src/node-haste/DependencyGraph.js:273:16)
    at Object.resolve (<project_directory>/node_modules/metro/src/lib/transformHelpers.js:261:42)
    at dependencies.map.result (<project_directory>/node_modules/metro/src/DeltaBundler/traverseDependencies.js:391:31)
    at Array.map (<anonymous>)
    at resolveDependencies (<project_directory>/node_modules/metro/src/DeltaBundler/traverseDependencies.js:388:18)
    at <project_directory>/node_modules/metro/src/DeltaBundler/traverseDependencies.js:261:33
    at Generator.next (<anonymous>)
    at asyncGeneratorStep (<project_directory>/node_modules/metro/src/DeltaBundler/traverseDependencies.js:87:24)
 DELTA  [android, dev] ./index.js ▓░░░░░░░░░░░░░░░ 8.6% (291/993), failed.

It wasn't my first lauch though. Previous launches were successful. Don't know what got suddenly wrong.
Tried to delete watchman stuff, metro cache and haste cache but still facing the building error.

To Reproduce

npm start -> react-native run-android

Expected Behavior

I expected the app to lauch without building error

Environment

React Native Environment Info:
System:
OS: Linux 4.15 Linux Mint 19.1 (Tessa)
CPU: (4) x64 Intel(R) Core(TM) i5-3340M CPU @ 2.70GHz
Memory: 268.93 MB / 7.66 GB
Shell: 4.4.19 - /bin/bash
Binaries:
Node: 10.15.0 - ~/Documents/nodejs/bin/node
npm: 6.7.0 - ~/Documents/nodejs/bin/npm
Watchman: 4.9.0 - /usr/local/bin/watchman
SDKs:
Android SDK:
API Levels: 23, 24, 25, 26, 27, 28
Build Tools: 27.0.3, 28.0.2, 28.0.3
System Images: android-23 | Intel x86 Atom_64, android-23 | Google APIs Intel x86 Atom_64, android-24 | Google APIs Intel x86 Atom_64, android-25 | Google APIs Intel x86 Atom_64, android-26 | Google APIs Intel x86 Atom_64, android-27 | Intel x86 Atom_64, android-28 | Google APIs Intel x86 Atom_64
npmPackages:
react: 16.6.3 => 16.6.3
react-native: 0.58.3 => 0.58.3
npmGlobalPackages:
apsl-react-native-button: 3.1.1
react-native-button-component: 0.2.28
react-native-cli: 2.0.1
react-native-elements: 0.19.1
react-native-vector-icons: 6.1.0

@Bradzer
Copy link
Author

Bradzer commented Feb 9, 2019

I don't know how an import { Toast } from 'native-base' got in my code.
That's what was messing up with everything.
I'm closing the issue.

@Bradzer Bradzer closed this as completed Feb 9, 2019
@facebook facebook locked as resolved and limited conversation to collaborators Feb 9, 2020
@react-native-bot react-native-bot added the Resolution: Locked This issue was locked by the bot. label Feb 9, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Bug Resolution: Locked This issue was locked by the bot.
Projects
None yet
Development

No branches or pull requests

2 participants