Failed to import @angular/core or other modules. Error 500
Failing module
- GitHub: https://github.com/angular/angular
- npm: https://npmjs.com/package/@angular/core
import {Component} from "https://esm.sh/@angular/[email protected]"
@Component({})
export class App {}
Error message
I seem to get lots of random 500 responses from esm.sh. This is reproducable in the ESM.sh playground as well.
Looking at the responses, there are a lot of Cloudflare Bypass / Miss responses as additional context. Not sure if that's related to the issue here.
Loading @angular/core loads rxjs transitively. This package has a lot of individual .mjs files; seemingly the majority of errors always happens on random files of that package. Is this a potential rate limiting?
Facing the same problem. Server issue?
same for GraphiQL https://github.com/graphql/graphiql/issues/4048
Also seeing this for @mui and @emution imports.
seems the server met s3 storage IO limit
update: temporarily added a rate limiting to 200 requests pre 10s pre IP
Awesome, thank you! will this rate limiting be removed in the future? (you mentioned it as being "temporary")
Seeing a ton of these errors for react, react-dom and @mui.
For anyone looking for self-hosting esm-sh on a subpath e.g. /esm/react (to share the same domain/port with the rest of frontend assets).
There is no way to configure esm.sh to listen on the subpath, so we used ast-grep with the transform to convert the code served by our local esm.sh instance.
We faced rate-limiting and it makes https://esm.sh impossible to use for us. It is crucial part for our test infrastructure, so we had to opt into self-hosting.
the temporarily rate limiting have been removed after an hour. i'm working on a cache layer for S3 storage
Thanks for the update.
The rate limits were observed July 7th 10am PT from my end, and from the above comment same day 4am PT. Maybe some other rate limits then?
Just checked and we're not rate-limited anymore.
I don't seem to get these 500 errors anymore, thanks!
On the other hand, I see some QUIC errors and larger files from e.g. @angular/compiler end up being never cached as it seems. All responses have the cf-cache-status: miss header.
E.g.
esm.sh/@angular/[email protected]/X-ZXJ4anM/es2022/compiler.mjs:1 Failed to load resource: net::ERR_QUIC_PROTOCOL_ERROR