react-native-qrcode icon indicating copy to clipboard operation
react-native-qrcode copied to clipboard

Error: EISDIR: illegal operation on a directory, read

Open hejunbinlan opened this issue 7 years ago • 9 comments

Error: EISDIR: illegal operation on a directory, read at Object.fs.readSync (fs.js:681:18) at Object.readSync (/Users/xxxx/workspace-js/ReactNative/HotCode/node_modules/graceful-fs/polyfills.js:138:28) at tryReadSync (fs.js:542:20) at Object.fs.readFileSync (fs.js:585:19) at Module._readSourceCode (/Users/xxxx/workspace-js/ReactNative/HotCode/node_modules/metro-bundler/build/node-haste/Module.js:205:29) at Module._getCacheProps (/Users/xxxx/workspace-js/ReactNative/HotCode/node_modules/metro-bundler/build/node-haste/Module.js:395:29) at Module._readFromTransformCache (/Users/xxxx/workspace-js/ReactNative/HotCode/node_modules/metro-bundler/build/node-haste/Module.js:345:29) at Module.readCached (/Users/xxxx/workspace-js/ReactNative/HotCode/node_modules/metro-bundler/build/node-haste/Module.js:332:19) at ResolutionRequest.preprocessModule (/Users/xxxx/workspace-js/ReactNative/HotCode/node_modules/metro-bundler/build/node-haste/DependencyGraph/ResolutionRequest.js:380:27) at ResolutionRequest._preprocessPotentialDependencies (/Users/xxxx/workspace-js/ReactNative/HotCode/node_modules/metro-bundler/build/node-haste/DependencyGraph/ResolutionRequest.js:364:27)

hejunbinlan avatar Aug 07 '17 01:08 hejunbinlan

I run into the same issue. Maybe the QR component does not match the later RN version? In my project, the RN version is 0.47 or later.

DeforeChen avatar Sep 06 '17 02:09 DeforeChen

I encountered the same issue too, my project's RN version is 0.47


But this problem fixed after I reinstalled npm modules.Try It

zeroceus avatar Sep 08 '17 09:09 zeroceus

I encountered the same issue too, my project's RN version is 0.51

fastalks avatar Jan 15 '18 03:01 fastalks

same here, RN version 0.52, HELP!!!

holasebas avatar Jan 17 '18 18:01 holasebas

I was able to get past the error by running npm install graceful-fs explicitly within my project. Hope it helps!

elijahmurray avatar Feb 07 '18 00:02 elijahmurray

Try end the project process on the device and restart(react-native run-android)

wkchen66 avatar Apr 26 '18 03:04 wkchen66

This happened when I moved the index.js file from the root of the project and it was resolved once I placed it back

buddudevelopers avatar Feb 18 '21 11:02 buddudevelopers

it works for me, https://stackoverflow.com/questions/66771543/metro-bundler-error-eisdir-illegal-operation-on-a-directory-read

anggihseptiawan avatar May 17 '21 16:05 anggihseptiawan

This can happen when running from a non-ejected expo repository

maxhudson avatar Jun 24 '21 23:06 maxhudson