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
Incomplete message parsing #113
Comments
Could it be that #108 (released in 1.0.6) introduced a regression? Contributors: I think we need to add some fuzz testing. |
We're using 1.0.5 so that wouldn't have caused our problem. |
Could you try upgrading to 1.0.6? |
Upgrading to 1.0.6 has the same issue. I can also see that a random message comes in before the properly formed one I am waiting for, and that is the exact character length of that characters missing. Could this be an issue with character chunking/content length?
|
This looks like chunked transfer encoding. We should have a look at handling this |
Actually, node automatically decodes chunked transfers, so this shouldn't be the case. Does this happen often enough that you could try replicating it in the browser with the native EventSource API? Could you get hold of the response stream from something like curl? |
Closing this issue - I don't think it is being caused by EventSource. Just found that we are seeing two octets for a message, I imagine one is the octet meant for the following message and causing the first to be cutoff:
This explains why we see:
|
We are thinking this might be a ServiceStack related bug, or some C# layer responsible for the chunked encoding. |
I have a message body where the last couple of characters are being cut off. Our application using this library sees a
Parse Error
and the message is lost.We are using v1.0.5 along with the C# Service Stack Server-Events library to send messages to this. The message we are sending is below:
Here is what is being parsed by the EventSource node library:
This does not happen all the time, but it does happen frequently. Have any others seen this issue?
The text was updated successfully, but these errors were encountered: