Skip to content

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

Closed
@Bradzer

Description

@Bradzer

🐛 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

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions