Skip to content

[eas-cli] Remove client side project setup on expo go command#3657

Draft
gwdp wants to merge 18 commits intomainfrom
gwdp/eas-go-v2-mutation
Draft

[eas-cli] Remove client side project setup on expo go command#3657
gwdp wants to merge 18 commits intomainfrom
gwdp/eas-go-v2-mutation

Conversation

@gwdp
Copy link
Copy Markdown
Contributor

@gwdp gwdp commented Apr 30, 2026

Why:

Remove local project setup and npm install from eas go, enable multiple Expo Go SDK versions server-side, and reduce surface area in the CLI.

How:

  • Calls expoGoRepackPreflight to get server-synthesized project files per SDK version
  • Packs them in-memory into a tar.gz and uploads tarball + eas.json + package.json to GCS
  • Calls createExpoGoRepackWorkflowRun with bucket keys + optional sdkVersion
  • Adds --sdk-version flag to select the Expo Go SDK version (defaults to latest)

Test Plan:

  • yarn typecheck and yarn lint pass
  • Manual end-to-end with EXPO_LOCAL=1 yarn eas go

Base: #3514
x-ref: https://github.com/expo/universe/pull/27053 (blocked by)

tchayen and others added 4 commits April 28, 2026 12:16
The `go` command previously created a full local project in /tmp
(app.json, eas.json, package.json, npm install, git init) to satisfy
credentials setup and workflow upload. This was unnecessary because:

- Credential setup (SetUpBuildCredentials, SetUpAscApiKey, SetUpPushKey)
  operates entirely through GraphQL/Apple APIs and never reads from disk
- CredentialsContext only needs an in-memory ExpoConfig and projectId
- The workflow can generate its own project independently

Now the command:
- Constructs ExpoConfig in-memory instead of writing/reading app.json
- Passes a no-op VcsClient since credential actions don't use it
- No longer runs npm install or git init
- Creates minimal temp files only for the workflow upload tarball
- No longer changes process.cwd() or preserves/cleans up project dirs
SetUpBuildCredentials can trigger interactive prompts (e.g. certificate
revocation selection when Apple's cert limit is hit). Wrapping it in
withSuppressedOutputAsync hid these prompts, causing an invisible prompt
that led to an infinite retry loop.
Universe's V2 mutation now synthesizes the project files server-side
from per-SDK targets, so the CLI no longer needs to write project files
to disk, tarball them, or upload them to GCS. go.ts shrinks to:
build the in-memory ExpoConfig for credentials setup, run
setupCredentialsAsync (unchanged — Apple auth stays interactive),
dispatch V2 with appId + ascAppId.

Removed: tar, uuid, fs-extra, path, getTmpDirectory, file synthesis,
GCS upload helpers, EXPO_GO_APP_VERSION, EXPO_GO_BUILD_NUMBER (the
server now owns those per-SDK).

Kept: setupCredentialsAsync (Apple auth + ASC API key + push key are
all interactive), ensureEasProjectAsync, monitorWorkflowJobsAsync.

WorkflowRunMutation: createExpoGoRepackWorkflowRunV2Async client.
graphql/template-strings is eslint-disabled until staging codegen
picks up the new ExpoGoRepackInput type.

Net: ~120 LOC removed, ~30 added in go.ts.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Send full semver matching EXPO_GO_SDK_VERSION so the API targets the intended SDK without relying on server defaults. Remove redundant comments around the Expo Go workflow path.
@codecov
Copy link
Copy Markdown

codecov Bot commented Apr 30, 2026

Codecov Report

❌ Patch coverage is 38.96104% with 47 lines in your changes missing coverage. Please review.
✅ Project coverage is 56.41%. Comparing base (1122a7f) to head (b191984).
⚠️ Report is 29 commits behind head on main.

Files with missing lines Patch % Lines
packages/eas-cli/src/commands/go.ts 8.70% 42 Missing ⚠️
...es/eas-cli/src/graphql/queries/WorkflowRunQuery.ts 0.00% 3 Missing ⚠️
...s-cli/src/graphql/mutations/WorkflowRunMutation.ts 33.34% 2 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #3657      +/-   ##
==========================================
+ Coverage   55.49%   56.41%   +0.92%     
==========================================
  Files         857      881      +24     
  Lines       36832    38024    +1192     
  Branches     7684     7912     +228     
==========================================
+ Hits        20435    21446    +1011     
- Misses      14965    16480    +1515     
+ Partials     1432       98    -1334     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@github-actions
Copy link
Copy Markdown

github-actions Bot commented May 4, 2026

✅ Thank you for adding the changelog entry!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants