You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
So I got bundlephobia running locally, and realized that 95% of these sporadic build errors are caused by the timeout being way too aggressive when trying to install the package(s).
For instance, locally this takes anywhere from 24s to 40s:
^ this command is generated from the accompanying project's worker in package-build-stats.
So even locally with a 1GB connection and no additional traffic, this timeout fails about 50% of the time. If the package can't install, then getAllPackageExports and getPackageExportSizes can't run.
Please describe the feature/suggestion
Increase the default getPackageStats timeout from 30s to 120s.
This PR #596 by @n10l appears to already solve the issue.
As far as I can tell looking through the existing issues in this repo, this timeout is affecting dozens of mid-to-large-sized NPM packages. Since it's a relatively straightforward fix, I'm hoping the upsides outweigh any potential downsides.
Note: if this fix is implemented, we may need to update the API timeout(s) in a few other places of the codebase. Happy to submit a subsequent PR in this case.
The text was updated successfully, but these errors were encountered:
Up front, I just want to say that I ❤️ Bundlephobia.
Context
As a library author, I keep getting sporadic build errors with https://bundlephobia.com/package/[email protected], and then I noticed that there are dozens of similar issues in this repo.
So I got
bundlephobia
running locally, and realized that 95% of these sporadic build errors are caused by the timeout being way too aggressive when trying to install the package(s).For instance, locally this takes anywhere from 24s to 40s:
^ this command is generated from the accompanying project's worker in package-build-stats.
So even locally with a 1GB connection and no additional traffic, this timeout fails about 50% of the time. If the package can't install, then
getAllPackageExports
andgetPackageExportSizes
can't run.Please describe the feature/suggestion
Increase the default
getPackageStats
timeout from 30s to 120s.This PR #596 by @n10l appears to already solve the issue.
As far as I can tell looking through the existing issues in this repo, this timeout is affecting dozens of mid-to-large-sized NPM packages. Since it's a relatively straightforward fix, I'm hoping the upsides outweigh any potential downsides.
Note: if this fix is implemented, we may need to update the API timeout(s) in a few other places of the codebase. Happy to submit a subsequent PR in this case.
The text was updated successfully, but these errors were encountered: