http: PRI upgrade should return PAUSED_H2_UPGRADE#95
Closed
Conversation
`PAUSED_UPGRADE` is a recoverable error and should not be returned when parsing HTTP/2 `PRI /...` preambule, which is the last message that can be parsed on the stream.
dnlup
approved these changes
Apr 6, 2021
Contributor
dnlup
left a comment
There was a problem hiding this comment.
So, if I understood these changes correctly, ERROR.PAUSED_H2_UPGRADE is returned instead of ERROR.PAUSED_UPGRADE in http2, which is not a recoverable error. ERROR.PAUSED_UPGRADE behavior is unchanged in http/1.1. Thanks for the heads up
jasnell
approved these changes
Apr 6, 2021
indutny
added a commit
that referenced
this pull request
Apr 6, 2021
`PAUSED_UPGRADE` is a recoverable error and should not be returned when parsing HTTP/2 `PRI /...` preambule, which is the last message that can be parsed on the stream. PR-URL: #95 Reviewed-By: Daniele Belardi <[email protected]> Reviewed-By: Matteo Collina <[email protected]> Reviewed-By: James M Snell <[email protected]>
Member
Author
|
Landed in 374434d, thank you. |
indutny
added a commit
that referenced
this pull request
Apr 6, 2021
`PAUSED_UPGRADE` is a recoverable error and should not be returned when parsing HTTP/2 `PRI /...` preambule, which is the last message that can be parsed on the stream. PR-URL: #95 Reviewed-By: Daniele Belardi <[email protected]> Reviewed-By: Matteo Collina <[email protected]> Reviewed-By: James M Snell <[email protected]>
Member
Author
|
Released v4.1.0 and v5.1.0 |
Contributor
|
Sorry I missed this, LGTM as well |
elijah-charbel
added a commit
to elijah-charbel/llhttp
that referenced
this pull request
Jul 29, 2025
`PAUSED_UPGRADE` is a recoverable error and should not be returned when parsing HTTP/2 `PRI /...` preambule, which is the last message that can be parsed on the stream. PR-URL: nodejs/llhttp#95 Reviewed-By: Daniele Belardi <[email protected]> Reviewed-By: Matteo Collina <[email protected]> Reviewed-By: James M Snell <[email protected]>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
PAUSED_UPGRADEis a recoverable error and should not be returned whenparsing HTTP/2
PRI /...preambule, which is the last message that canbe parsed on the stream.
@pallas could you give this a quick review when you'll get a chance? I've tried updating llhttp in Node.js and quickly ran into this issue. Basically, our documentation says that
llhttp_resume_after_upgradeshould be called afterPAUSED_UPGRADE, and it resets the.errorto0, but in reality the parser is in non-recoverable state! This is a breaking change, but I'm going to treat it as a bugfix and do a minor release for all branches once landed.cc @nodejs/http @nodejs/http2 as well