Skip to content

[eas-cli] Fix usage warning bug in eas:build#3260

Merged
mackenco merged 4 commits intomainfrom
cm/overages-bug
Nov 20, 2025
Merged

[eas-cli] Fix usage warning bug in eas:build#3260
mackenco merged 4 commits intomainfrom
cm/overages-bug

Conversation

@mackenco
Copy link
Copy Markdown
Contributor

Why

Received a bug report that the eas:build command was failing on latest. We were checking the project config too early.

How

Moved the maybeWarnAboutUsageOveragesAsync call later into the command; now it's called in prepareAndStartBuildAsync, after we know we have a config. I put it early in this function because 1) I wanted to warn before we start the build 2) I wanted it to come before most of the other info logged by the command but 3) after createBuildContextAsync is run, since this grabs the accountId.

Test Plan

I overrode the logic in maybeWarnAboutUsageOveragesAsync to always warn locally. I think it's a little odd that it comes after the incremented log, but felt like a logical place in the code for this to live.
Multiple builds:
Multi build

Single build:
Screenshot 2025-11-17 at 1 39 46 PM

env,
});

if (!hasWarnedAboutUsageOverages && !flags.localBuildOptions.localBuildMode) {
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

This this function could run multiple times (per build profile), we want to track if we've warned and only do it once.

@mackenco mackenco requested a review from douglowder November 17, 2025 19:55
@mackenco mackenco marked this pull request as ready for review November 17, 2025 19:55
@github-actions
Copy link
Copy Markdown

Subscribed to pull request

File Patterns Mentions
**/* @douglowder
packages/eas-cli/src/commands/build/** @sjchmiela
packages/eas-cli/src/build/** @sjchmiela

Generated by CodeMention

@github-actions
Copy link
Copy Markdown

github-actions bot commented Nov 17, 2025

Size Change: +37 B (0%)

Total Size: 54.9 MB

Filename Size Change
./packages/eas-cli/dist/eas-linux-x64.tar.gz 54.9 MB +37 B (0%)

compressed-size-action

@github-actions
Copy link
Copy Markdown

✅ Thank you for adding the changelog entry!

@codecov
Copy link
Copy Markdown

codecov bot commented Nov 17, 2025

Codecov Report

❌ Patch coverage is 25.00000% with 6 lines in your changes missing coverage. Please review.
✅ Project coverage is 51.88%. Comparing base (dead119) to head (d5ecd53).
⚠️ Report is 3 commits behind head on main.

Files with missing lines Patch % Lines
packages/eas-cli/src/build/runBuildAndSubmit.ts 25.00% 5 Missing and 1 partial ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #3260      +/-   ##
==========================================
- Coverage   51.89%   51.88%   -0.00%     
==========================================
  Files         631      631              
  Lines       25860    25862       +2     
  Branches     5435     5437       +2     
==========================================
- Hits        13418    13417       -1     
- Misses      11323    11325       +2     
- Partials     1119     1120       +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.

@mackenco mackenco merged commit aa7fecb into main Nov 20, 2025
10 checks passed
@mackenco mackenco deleted the cm/overages-bug branch November 20, 2025 19:24
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