Skip to content

Conversation

@kitten
Copy link
Member

@kitten kitten commented Jan 6, 2026

See: https://exponent-internal.slack.com/archives/C017N0N99RA/p1758469493137929
Resolves: expo/expo#40227

Why

Note

There's still a lot of leftover reliance on @expo/config (outdated), @expo/prebuild-config, and some other internals, which are prone to failing and not being updated. A lot of them don't have replacement code paths that are obvious but stood out to @byCedric when implementing some Launch features and replicating/replacing some logic from eas-cli

All invocations of npx are prone to failure and unnecessary:

  • npx expo install is redundant if we can invoke the Expo CLI directly (which forks if needed automatically)
  • npx expo config --json is unreliable, if npx adds additional output to the standard output. It also can fail if there's a global provider of expo, another expo in the npm-resolved PATH, or for various other reasons
  • the same applies to the entitlements call

Additionally, we have a few fallbacks that are invalid. The entitlements fallback doesn't work and replaces the failed npx expo config command with obscure output, failing to also print its Log.warns in some cases, which are confusing.

The @expo/config fallback has to be left in place currently as there's no prerequisite of expo being installed (which there should be) for getExpoConfigInternalAsync to be invokable. The check for isExpoInstalled is also faulty as it doesn't resolve expo but instead checks the package.json, but to keep this PR leaner, this isn't addressed here.

The fallbacks are generally for older versions of the SDK which are now unsupported.

How

  • Replace all npx expo invocations with a direct expo CLI invocation (code already existed for this)
  • Remove entitlements and config error fallbacks, which were confusing

Test Plan

Most of these changes are speculative and untested right now.

@github-actions
Copy link

github-actions bot commented Jan 6, 2026

Subscribed to pull request

File Patterns Mentions
**/* @douglowder

Generated by CodeMention

@kitten kitten changed the title @kitten/refactor/remove npx invoke and deprecated packages refactor(eas-cli): Remove npx expo invocations and config/entitlements fallbacks Jan 6, 2026
@github-actions
Copy link

github-actions bot commented Jan 6, 2026

Size Change: +7.29 kB (+0.01%)

Total Size: 54.9 MB

Filename Size Change
./packages/eas-cli/dist/eas-linux-x64.tar.gz 54.9 MB +7.29 kB (+0.01%)

compressed-size-action

@kitten kitten force-pushed the @kitten/refactor/remove-npx-invoke-and-deprecated-packages branch from 5aa6e80 to bbb8c67 Compare January 6, 2026 14:01
@github-actions
Copy link

github-actions bot commented Jan 6, 2026

✅ Thank you for adding the changelog entry!

@codecov
Copy link

codecov bot commented Jan 6, 2026

Codecov Report

❌ Patch coverage is 33.33333% with 18 lines in your changes missing coverage. Please review.
✅ Project coverage is 51.99%. Comparing base (414ccb9) to head (d9aaede).

Files with missing lines Patch % Lines
packages/eas-cli/src/utils/expoCli.ts 18.19% 9 Missing ⚠️
packages/eas-cli/src/project/ios/entitlements.ts 33.34% 4 Missing ⚠️
packages/eas-cli/src/project/expoConfig.ts 25.00% 3 Missing ⚠️
...ackages/eas-cli/src/commands/project/onboarding.ts 50.00% 1 Missing ⚠️
packages/eas-cli/src/project/ios/target.ts 0.00% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #3282      +/-   ##
==========================================
+ Coverage   51.98%   51.99%   +0.02%     
==========================================
  Files         635      635              
  Lines       25961    25936      -25     
  Branches     5457     5453       -4     
==========================================
- Hits        13492    13482      -10     
+ Misses      11347    11333      -14     
+ Partials     1122     1121       -1     

☔ 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.

Copy link
Contributor

@douglowder douglowder left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for doing this!! I’ll have a look to see if the tests can be improved in a separate PR, and also have a look at removing some of the fallbacks that are no longer needed with the current supported Expo SDK.

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.

The 'expo-modules-autolinking' package has been found, but it seems to be incompatible with '@expo/prebuild-config'

3 participants