-
Notifications
You must be signed in to change notification settings - Fork 2
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
Streams error in deno_web
#495
Comments
When Lassie discovers a verification problem after it already started streaming the CAR response body, it needs to let the client know about the problem. The current solution is to abort the stream in a way that breaks the HTTP/1.1 protocol. The error message seems to describe this error condition.
I see two ways forward:
|
As part of Zinnia-Lassie integration, we can detect this error condition and wrap or annotate the error instance with a code that will make it easier for Station modules to detect this particular error. Either way, we need to modify Spark Checker node to detect & handle this error in a special way. I propose introducing a new "retrieval result" value - "verification failed". IIRC, we don't have any existing "measurement" field to accommodate this new flag/status. We need to think a bit more about this. |
Do you know how we can catch this error? I agree that if we continue using Lassie, wrapping this error message is the way to go, to give the user more useful context. This is also happening with Voyager btw (and this particular error message is from Voyager), which doesn't use Zinnia's Lassie integration |
I would expect something like this to work: try {
await fetch(/*...*/);
} catch (err) {
if (err.message === 'request or response body error: error reading a body from connection: unexpected end of file') {
// this error was triggered
} else {
throw err;
}
}
Interesting! Doesn't Saturn L1 use Lassie under the hood to retrieve the content from the upstream provider? |
Unfortunately the stack trace doesn't contain more information. Do you happen to know more about this error?
The text was updated successfully, but these errors were encountered: