Skip to content

Commit 9337fb3

Browse files
Fix bump llhttp to v8.1.1 (#7367) (#7377)
(cherry picked from commit 41e2c4c)
1 parent f07e9b4 commit 9337fb3

File tree

5 files changed

+28
-2
lines changed

5 files changed

+28
-2
lines changed

.gitmodules

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
[submodule "vendor/llhttp"]
22
path = vendor/llhttp
33
url = https://github.com/nodejs/llhttp.git
4-
branch = v8.1.1
4+
branch = v8.x

docs/contributing.rst

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -110,6 +110,8 @@ Install pre-commit hooks:
110110

111111
Congratulations, you are ready to run the test suite!
112112

113+
.. include:: ../vendor/README.rst
114+
113115

114116
Run autoformatter
115117
-----------------

tests/test_http_parser.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -685,6 +685,7 @@ def test_http_response_parser_bad(response) -> None:
685685
response.feed_data(b"HTT/1\r\n\r\n")
686686

687687

688+
@pytest.mark.skipif(not NO_EXTENSIONS, reason="Behaviour has changed in C parser")
688689
def test_http_response_parser_code_under_100(response) -> None:
689690
msg = response.feed_data(b"HTTP/1.1 99 test\r\n\r\n")[0][0][0]
690691
assert msg.code == 99

vendor/README.rst

Lines changed: 23 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,23 @@
1+
LLHTTP
2+
------
3+
4+
When building aiohttp from source, there is a pure Python parser used by default.
5+
For better performance, you may want to build the higher performance C parser.
6+
7+
To build this ``llhttp`` parser, first get/update the submodules (to update to a
8+
newer release, add ``--remote`` and check the branch in ``.gitmodules``)::
9+
10+
git submodule update --init --recursive
11+
12+
Then build ``llhttp``::
13+
14+
cd vendor/llhttp/
15+
npm install
16+
make
17+
18+
Then build our parser::
19+
20+
cd -
21+
make cythonize
22+
23+
Then you can build or install it with ``python -m build`` or ``pip install -e .``

0 commit comments

Comments
 (0)