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

[master iOS]Metro Bundler has encountered an internal error, please check your terminal error output for more details #19478

Closed
ShiYongjieGitHub opened this issue May 29, 2018 · 6 comments
Labels
Platform: iOS iOS applications. Resolution: Locked This issue was locked by the bot.

Comments

@ShiYongjieGitHub
Copy link

ShiYongjieGitHub commented May 29, 2018

This is all the relevant information of the terminal error:
Looking for JS files in
/Users/shiyongjie/Desktop/Git/Facebook/react-native

Metro Bundler ready.

Loading dependency graph, done.
error: bundling failed: ReferenceError: SHA-1 for file /Users/shiyongjie/Desktop/Git/Facebook/react-native/node_modules/react/index.js is not computed
at DependencyGraph.getSha1 (/Users/shiyongjie/Desktop/Git/Facebook/react-native/node_modules/metro/src/node-haste/DependencyGraph.js:224:3541)
at /Users/shiyongjie/Desktop/Git/Facebook/react-native/node_modules/metro/src/Bundler.js:263:56
at Generator.next ()
at step (/Users/shiyongjie/Desktop/Git/Facebook/react-native/node_modules/metro/src/Bundler.js:11:657)
at /Users/shiyongjie/Desktop/Git/Facebook/react-native/node_modules/metro/src/Bundler.js:11:817
at
at process._tickCallback (internal/process/next_tick.js:169:7)
BUNDLE [ios, dev] RNTester/js/RNTesterApp.ios.js ░░░░░░░░░░░░░░░░ 0.0% (0/2), failed.

And this is all all the relevant information of device red screen showing:
Metro Bundler has encountered an internal error, please check your terminal error output for more details

RCTFatal
__28-[RCTCxxBridge handleError:]_block_invoke
_dispatch_call_block_and_release
_dispatch_client_callout
_dispatch_main_queue_callback_4CF


CFRunLoopRunSpecific
GSEventRunModal
UIApplicationMain
main
# #

@ShiYongjieGitHub
Copy link
Author

I run the RNTester project, and encounter this problem.

@react-native-bot
Copy link
Collaborator

It looks like your issue may be incomplete. Are all the fields required by the Issue Template filled out?

If you believe your issue contains all the relevant information, let us know in order to have a maintainer remove the No Template label.

@ShiYongjieGitHub ShiYongjieGitHub changed the title Metro Bundler has encountered an internal error, please check your terminal error output for more details [master iOS]Metro Bundler has encountered an internal error, please check your terminal error output for more details May 29, 2018
@react-native-bot react-native-bot added the Platform: iOS iOS applications. label May 29, 2018
@react-native-bot
Copy link
Collaborator

Potential fix is at jestjs/jest#6264

Closing as this issue belongs in https://github.com/facebook/metro

@handeglc
Copy link

I removed node_modules and run npm install then restarted my computer, now it works

@HarshitMadhav
Copy link

HarshitMadhav commented Feb 6, 2019

@handeglc thanks only npm install worked for me

@rrrhys
Copy link

rrrhys commented Feb 6, 2019

Possible solution for typescript projects; check in rn-cli.config.js that js is included as a sourceExt.

E.g.:

module.exports = {
    resolver: {
        sourceExts: ['tsx', 'ts', 'js'] //in a typescript project, make sure js is still listed here.
    },
    transformer: {
        babelTransformerPath: require.resolve("react-native-typescript-transformer")
    }
};

@facebook facebook locked as resolved and limited conversation to collaborators May 29, 2019
@react-native-bot react-native-bot added the Resolution: Locked This issue was locked by the bot. label May 29, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Platform: iOS iOS applications. Resolution: Locked This issue was locked by the bot.
Projects
None yet
Development

No branches or pull requests

5 participants