Skip to content

fix(engineio): fix Noop packet emission when upgrading transport #554

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

Merged
merged 7 commits into from
Aug 6, 2025

Conversation

Totodore
Copy link
Owner

@Totodore Totodore commented Aug 3, 2025

Motivation

Until now the Noop packet was sent only one time on the connection and through the internal buffer channel between transports and the engine.io socket. This led to a bug in the upgrade mechanism because the client could send multiple polling requests during the upgrade process.

Solution

Per the official socket.io implementation in JS, the Noop packet should be sent only from the HTTP handler for the polling request in the socket is in an "upgrading" state. With this solution, every polling call are immediately closed during the upgrade mechanism.

Fixes #497

@Totodore Totodore added C-Bug Something isn't working A-engineioxide Area related to engineioxide P-High High priority labels Aug 3, 2025
@Totodore Totodore force-pushed the fix-upgrade-process branch from dacad0f to 2b70ab4 Compare August 3, 2025 16:52
@Totodore Totodore merged commit 0757cda into main Aug 6, 2025
15 checks passed
@Totodore Totodore deleted the fix-upgrade-process branch August 6, 2025 21:28
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-engineioxide Area related to engineioxide C-Bug Something isn't working P-High High priority
Projects
None yet
Development

Successfully merging this pull request may close these issues.

ws stream closed before upgrade
1 participant