Skip to content

eas build:dev "fails" if dev server is already running #3317

@chrisforerunner

Description

@chrisforerunner

Build/Submit details page URL

No response

Summary

eas build:dev works great, but if you're already running a copy of the dev server, the build "fails" because the final build step is to startDevServerAsync unconditionally.

Example output:

❯ eas build:dev --platform android
Environment variables with visibility "Plain text" and "Sensitive" loaded from the "development" environment on EAS: ****
Environment variables loaded from the "development-simulator" build profile "env" configuration: ****

✔ Computed project fingerprint
✨ Calculated fingerprint hash: ****

✔ 🎯 Found successful build with matching fingerprint on EAS servers. Running it...

Using cached app...

Using open emulator: Medium_Phone_API_36

Installing your app...
✔ Successfully installed your app!

Starting your app...
✔ Successfully started your app!

Starting development server: npx expo start --dev-client --android
[expo-cli] env: load .env.development.local .env
[expo-cli] env: export EXPO_PUBLIC_****
[expo-cli] Starting project at /path/to/app
[expo-cli] › Port 8081 is running this app in another window
[expo-cli]   /path/to/app (pid 49209)
[expo-cli] Input is required, but 'npx expo' is in non-interactive mode.
[expo-cli] Required input:
[expo-cli] > Use port 8082 instead?
[expo-cli] › Skipping dev server
/path/to/app/node_modules/expo/bin/cli start --dev-client --android exited with non-zero code: 1
    Error: build:dev command failed.

Despite this error, the build does install and run just fine.

Perhaps the script should assume the running metro instance is okay to use and not fail. Or the command could take a new flag like the expo CLI does: --no-bundler.

Managed or bare?

Bare, though I think this doesn't matter

Environment

expo-env-info 2.0.8 environment info:
System:
OS: macOS 15.7.1
Shell: 5.9 - /bin/zsh
Binaries:
Node: 22.14.0 - ~/.local/state/fnm_multishells/21334_1768454354344/bin/node
Yarn: 4.10.3 - ~/.local/state/fnm_multishells/21334_1768454354344/bin/yarn
npm: 10.9.2 - ~/.local/state/fnm_multishells/21334_1768454354344/bin/npm
Watchman: 2025.03.10.00 - /opt/homebrew/bin/watchman
Managers:
CocoaPods: 1.16.2 - /Users/chris/.rbenv/shims/pod
SDKs:
iOS SDK:
Platforms: DriverKit 25.0, iOS 26.0, macOS 26.0, tvOS 26.0, visionOS 26.0, watchOS 26.0
IDEs:
Android Studio: 2025.1 AI-251.26094.121.2513.14007798
Xcode: 26.0.1/17A400 - /usr/bin/xcodebuild
npmPackages:
babel-preset-expo: ~54.0.0 => 54.0.3
expo: ~54.0.0 => 54.0.12
react: 19.1.0 => 19.1.0
react-native: 0.81.4 => 0.81.4
npmGlobalPackages:
eas-cli: 16.28.0
Expo Workflow: bare

Error output

No response

Reproducible demo or steps to reproduce from a blank project

  1. Run metro via expo start
  2. In another terminal kick off an EAS dev build: eas build:dev --platform android
  3. Once the build is successful, note the "failed" output and exit code

Metadata

Metadata

Assignees

No one assigned

    Labels

    needs reviewIssue is ready to be reviewed by a maintainer

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions