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
The module fallback service given code that contains a syntax error returns an error response saying that the requested module could not be found, instead of clearly saying that a compilation error occurred, while using the service I encountered this causing me confusion and making me question if my code was failing to correctly fetch the module, so I think it would be great if this could be improved.
KJ_LOG(ERROR, "Fallback service failed to fetch module", exception, spec);
return kj::none;
}
I'm guessing that in order to catch syntax errors (or any possible errors?) and surface them correctly to the user we should try-catch this piece of code?
The module fallback service given code that contains a syntax error returns an error response saying that the requested module could not be found, instead of clearly saying that a compilation error occurred, while using the service I encountered this causing me confusion and making me question if my code was failing to correctly fetch the module, so I think it would be great if this could be improved.
minimal reproduction made by using miniflare
I think that the main issue is the fact that here on errors we simply only return a failed-to-fetch-module error:
workerd/src/workerd/server/server.c++
Lines 2872 to 2876 in 1a99c34
I'm guessing that in order to catch syntax errors (or any possible errors?) and surface them correctly to the user we should try-catch this piece of code?
workerd/src/workerd/server/server.c++
Line 2866 in 1a99c34
The text was updated successfully, but these errors were encountered: