question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Module `axios` does not exist in the Haste module map or in these directories

See original GitHub issue

Describe the bug after installing CocoaPod, it is giving me this error when I run command react-native run-ios. earlier it was working fine. To Reproduce Steps to reproduce the behavior: simply run react-native run-ios

Expected behavior it should run without any error

Desktop (please complete the following information):

  • macOS hight Sierra
  • Chrome Browser for debugging

Smartphone (please complete the following information):

  • Simulator: [e.g. iPhoneX]
  • OS: iOS11.4

package.json { “name”: “VikingHealth”, “version”: “0.0.1”, “private”: true, “scripts”: { “start”: “node node_modules/react-native/local-cli/cli.js start”, “test”: “jest” }, “dependencies”: { “aws-amplify”: “^1.0.11”, “aws-amplify-react”: “^2.0.1”, “aws-amplify-react-native”: “^2.0.1”, “aws-appsync”: “^1.7.0”, “aws-appsync-react”: “^1.2.5”, “aws-sdk”: “^2.353.0”, “d3-shape”: “^1.2.2”, “es6-symbol”: “^3.1.1”, “google-libphonenumber”: “^3.1.14”, “graphql-tag”: “^2.10.0”, “i”: “^0.3.6”, “install”: “^0.12.2”, “link”: “^0.1.5”, “lodash”: “^4.17.11”, “mobx”: “^4.8.0”, “mobx-react”: “^5.0.0”, “moment”: “^2.22.2”, “moment-range”: “^4.0.1”, “npm”: “^6.7.0”, “opentok-react-native”: “^0.9.5”, “prop-types”: “^15.6.2”, “react”: “16.5.0”, “react-apollo”: “^2.2.4”, “react-art”: “^16.6.0”, “react-native”: “^0.57.7”, “react-native-chart-kit”: “^1.1.9”, “react-native-circular-progress”: “^1.0.1”, “react-native-easy-toast”: “^1.1.0”, “react-native-elements”: “^1.0.0-beta7”, “react-native-i18n”: “^2.0.15”, “react-native-keyboard-aware-scroll-view”: “^0.7.2”, “react-native-linear-gradient”: “^2.4.2”, “react-native-multiple-picker”: “0.0.21”, “react-native-parallax-header”: “^1.0.6”, “react-native-phone-input”: “^0.2.1”, “react-native-popup-dialog”: “^0.16.3”, “react-native-progress”: “^3.5.0”, “react-native-progress-circle”: “^2.0.1”, “react-native-segmented-control-tab”: “^3.3.1”, “react-native-simple-dialogs”: “^0.4.1”, “react-native-slider”: “^0.11.0”, “react-native-svg”: “^6.4.1”, “react-native-svg-charts”: “^5.2.0”, “react-native-triangle”: “0.0.9”, “react-native-vector-icons”: “^6.1.0”, “react-native-video”: “^4.2.0”, “react-navigation”: “^2.14.2”, “rn-viewpager”: “^1.2.9” }, “devDependencies”: { “@babel/plugin-proposal-decorators”: “^7.1.2”, “@babel/runtime”: “^7.1.2”, “babel-jest”: “23.6.0”, “babel-plugin-transform-remove-console”: “^6.9.4”, “eslint-config-rallycoding”: “^3.2.0”, “jest”: “23.6.0”, “metro-react-native-babel-preset”: “^0.48.3”, “react-test-renderer”: “16.5.0” }, “jest”: { “preset”: “react-native” }, “rnpm”: { “assets”: [ “./assets/fonts/” ] } }

Additional context error: bundling failed: Error: Unable to resolve module axios from /Users/tarun/Desktop/projects/quovantis-projects/Viking-health-Master/VikingHealth/node_modules/@aws-amplify/api/lib/RestClient.js: Module axios does not exist in the Haste module map or in these directories: /Users/tarun/Desktop/projects/quovantis-projects/Viking-health-Master/VikingHealth/node_modules/@aws-amplify/api/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 (/Users/tarun/Desktop/projects/quovantis-projects/Viking-health-Master/VikingHealth/node_modules/metro/src/node-haste/DependencyGraph/ModuleResolution.js:139:15) at ResolutionRequest.resolveDependency (/Users/tarun/Desktop/projects/quovantis-projects/Viking-health-Master/VikingHealth/node_modules/metro/src/node-haste/DependencyGraph/ResolutionRequest.js:49:18) at DependencyGraph.resolveDependency (/Users/tarun/Desktop/projects/quovantis-projects/Viking-health-Master/VikingHealth/node_modules/metro/src/node-haste/DependencyGraph.js:218:16) at Object.resolve (/Users/tarun/Desktop/projects/quovantis-projects/Viking-health-Master/VikingHealth/node_modules/metro/src/lib/transformHelpers.js:141:30) at dependencies.map.result (/Users/tarun/Desktop/projects/quovantis-projects/Viking-health-Master/VikingHealth/node_modules/metro/src/DeltaBundler/traverseDependencies.js:373:31) at Array.map (<anonymous>) at resolveDependencies (/Users/tarun/Desktop/projects/quovantis-projects/Viking-health-Master/VikingHealth/node_modules/metro/src/DeltaBundler/traverseDependencies.js:369:18) at /Users/tarun/Desktop/projects/quovantis-projects/Viking-health-Master/VikingHealth/node_modules/metro/src/DeltaBundler/traverseDependencies.js:188:33 at Generator.next (<anonymous>) at step (/Users/tarun/Desktop/projects/quovantis-projects/Viking-health-Master/VikingHealth/node_modules/metro/src/DeltaBundler/traverseDependencies.js:298:30) BUNDLE [ios, dev] …/…/index.js 24.3% (347/738)::1 - - [28/Jan/2019:02:14:52 +0000] “GET /index.bundle?platform=ios&dev=true&minify=false HTTP/1.1” 200 - “-” “VikingHealth/1 CFNetwork/901.1 Darwin/17.7.0” BUNDLE [ios, dev] …/…/index.js 99.4% (2037/2043)^[[B^[[B

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Reactions:5
  • Comments:16 (1 by maintainers)

github_iconTop GitHub Comments

5reactions
stale[bot]commented, Jun 27, 2019

This issue has been automatically closed because of inactivity. Please open a new issue if are still encountering problems.

2reactions
LuisUrrutiacommented, Mar 11, 2019

I was able to solve it after remove the file rn-cli.js that I created to solve another problem

Read more comments on GitHub >

github_iconTop Results From Across the Web

module does not exist in the haste module map - Stack Overflow
The problem was that events is part of node internal modules which not exist in v8 so I installed this module separately and...
Read more >
unable to resolve module react-native-svg - You.com | The search ...
1. I had the same problem, I fixed that by below steps: 1-> delete node_modules by: rm -rf node_modules. 2-> delte Pods folder...
Read more >
Module not found: Can't resolve 'axios' in React | bobbyhadz
To solve the error "Module not found: Error: Can't resolve 'axios'", make sure to install the axios package by opening your terminal in...
Read more >
react-native 安装eslint启动报错Module `moment` does not ...
如题,vscode安装完插件并配置完成以后,启动服务,报错:Module `moment` does not exist in the Haste module map查了一下代码,moment是有引入的, ...
Read more >
react-native-blob-util - npm
A module provides upload, download, and files access API. ... There are 22 other projects in the npm registry using react-native-blob-util.
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found