react-native: [0.55.0] Metro Bundler can't listen on port undefined
- I have reviewed the documentation
- I am using the latest React Native version
- I have searched existing issues
I am following up on closed issue #18673. This still seems to be an issue. Here’s a screenshot of what I’m experiencing. Is there something I am missing?

Environment
OS: macOS High Sierra 10.13.3 Node: 7.9.0 Yarn: Not Found npm: 4.2.0 Watchman: 4.9.0 Xcode: Xcode 9.3 Build version 9E145 Android Studio: 3.1 AI-173.4670197
Packages: (wanted => installed) react: 16.3.0 => 16.3.0 react-native: 0.55.0 => 0.55.0
Steps to Reproduce
react-native init AwesomeProject
cd AwesomeProject
react-native run-ios
Expected Behavior
Build Successful!
Actual Behavior
Metro Bundler can’t listen on port undefined
About this issue
- Original URL
- State: closed
- Created 6 years ago
- Reactions: 22
- Comments: 29 (10 by maintainers)
Commits related to this issue
- Fixes runIOS regressions #18681 — committed to facebook/react-native by grabbou 6 years ago
- Fix: "Metro listenting on port undefined" Summary: Regression introduced in https://github.com/facebook/react-native/commit/2ad34075f1d048bebb08ef30799ac0d081073150. Fixes https://github.com/faceboo... — committed to exozet/react-native by grabbou 6 years ago
- Fix: "Metro listenting on port undefined" Summary: Regression introduced in https://github.com/facebook/react-native/commit/2ad34075f1d048bebb08ef30799ac0d081073150. Fixes https://github.com/faceboo... — committed to macdoum1/react-native by grabbou 6 years ago
- Fix: "Metro listenting on port undefined" Summary: Regression introduced in https://github.com/facebook/react-native/commit/2ad34075f1d048bebb08ef30799ac0d081073150. Fixes https://github.com/faceboo... — committed to react-native-community/cli by grabbou 6 years ago
Apparently this is related to #18525, that issue fixes device but simulator is still broken, because
portis not passed intobuildProject.https://github.com/facebook/react-native/blob/master/local-cli/runIOS/runIOS.js#L130
Adding
args.portas the last argument to this function call should temporarily fix the issueFirst off, PLEASE don’t pollute the issue with useless ‘same issue’ comments.
There are the reactions for indicating that this issue is present.
That said, please don’t use 0.55.0 because it ships with the wrong version of React. We are going to release soon a new version.
I have to say the release process has been very carelessly, recently.
Each major release has flaws that makes it unusable. Especially with 0.54 and 0.55. I always have postinstall script setup to fix react-native. Feel like it’s SEV worthy and time to revise the process
This is happening to me too, 0.52.2 with React 16.2.0 fixed it.
Can confirm that using react-native: 0.52.2 fixed this issue for me.
Here’s PR: https://github.com/facebook/react-native/pull/18721. I’ll probably merge it today and once 0.55 is out, make a PR back to
masterto make sure it has all the fixes.Here’s my proposed fix: https://github.com/facebook/react-native/commit/2ad34075f1d048bebb08ef30799ac0d081073150#r28448345 Waiting for feedback and will release a patch.
I am really sorry for all the inconvenience issues with the command line tools caused for you. For the future, we will make sure to pay even more attention to commits affecting the CLI.
On Fri, 6 Apr 2018 at 09:10 Welly notifications@github.com wrote:
Interesting. I had it already launched (you can turn it on by pressing CMD Space and typing simulator).
I’ll take a closer look at the full run ios diff, that’s alarming if this feature doesn’t work either.
On Fri, Apr 6, 2018, 6:26 AM Welly notifications@github.com wrote: