-
Notifications
You must be signed in to change notification settings - Fork 93
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[eas-cli] Raise threshold for "big tarball" warning #2878
Conversation
Subscribed to pull request
Generated by CodeMention |
Size Change: +1.4 kB (0%) Total Size: 53.4 MB
|
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #2878 +/- ##
==========================================
+ Coverage 52.41% 52.41% +0.01%
==========================================
Files 588 588
Lines 23164 23169 +5
Branches 4853 4851 -2
==========================================
+ Hits 12139 12142 +3
- Misses 10049 10053 +4
+ Partials 976 974 -2 ☔ View full report in Codecov by Sentry. |
if (projectTarball.size > 2 * 1024 * 1024 * 1024) { | ||
throw new Error('Project archive is too big. Maximum allowed size is 2GB.'); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
do we want to move it as well to separate function?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍
eas-cli/packages/eas-cli/src/build/utils/repository.ts
Lines 186 to 198 in 242f949
const MAX_ALLOWED_PROJECT_TARBALL_SIZE = | |
2 /* GiB */ * 1024 /* MiB */ * 1024 /* KiB */ * 1024; /* B */ | |
export function assertProjectTarballSizeDoesNotExceedLimit(size: number): void { | |
if (size <= MAX_ALLOWED_PROJECT_TARBALL_SIZE) { | |
return; | |
} | |
throw new Error( | |
`Project archive is too big. Maximum allowed size is ${formatBytes( | |
MAX_ALLOWED_PROJECT_TARBALL_SIZE | |
)}.` | |
); | |
} |
4968bc1
to
242f949
Compare
⏩ The changelog entry check has been skipped since the "no changelog" label is present. |
Why
Adding
.git
directory to the tarball makes it bigger. Users notice this warning and want it to be actionable, but currently adding.git
to.easignore
does nothing.How
For now, raise threshold for warning from 100 MiB to 150 MiB. In the next pull request I'm going to fix
.git
exclusion via.easignore
.Test Plan
CI should pass.