Skip to content
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

Streaming chunks fragmented at 2048 bytes #63

Open
RJ opened this issue Oct 17, 2024 · 1 comment
Open

Streaming chunks fragmented at 2048 bytes #63

RJ opened this issue Oct 17, 2024 · 1 comment

Comments

@RJ
Copy link

RJ commented Oct 17, 2024

I'm using streaming, and if i send a chunk larger than 2048, it's truncated.
I get sent a Part which is 2048 long, even if the server sent a larger chunk.
(which then doesn't deserialize properly as it's truncated)

due to hardcoded buffer size here:
https://github.com/emilk/ehttp/blob/master/ehttp/src/streaming/native.rs#L57

i don't think it's possible to know if a received Part was truncated or was simply exactly 2048 long originally.

@RJ
Copy link
Author

RJ commented Oct 17, 2024

not a real fix, but i doubled the size to "fix" my problem, and added a warning

https://github.com/rj/ehttp/blob/chunkier/ehttp/src/streaming/native.rs#L57

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant