Skip to content

Enable more lint rules - #1319

Merged
Viicos merged 5 commits into
mainfrom
vp/lint
Nov 7, 2026
Merged

Viicos merged 5 commits into
mainfrom
vp/lint

Conversation

@Viicos

@Viicos Viicos commented Nov 7, 2026 •

Copy link
Copy Markdown
Member

Behavior change

Sending an HTTP/2 request without a Host header directly to a connection (HTTP2Connection.handle_request() / AsyncHTTP2Connection.handle_async_request()) now raises httpcore2.LocalProtocolError("Missing mandatory Host: header"), consistent with HTTP/1.1 (h11). Previously, this raised an unhelpful IndexError.

This only affects requests built manually and sent through the low-level API: request()/stream() add the Host header automatically, and httpx2 always sets it.

View guided diff

@codspeed

codspeed Bot commented Nov 7, 2026 •

Copy link
Copy Markdown

Merging this PR will not alter performance

✅ 18 untouched benchmarks
⏩ 7 skipped benchmarks1


Comparing vp/lint (d34d546) with main (c1f55b6)

Open in CodSpeed

Footnotes

  1. 7 benchmarks were skipped, so the baseline results were used instead. If they were deleted from the codebase, click here and archive them to remove them from the performance reports. ↩

@cubic-dev-ai cubic-dev-ai Bot left a comment •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Review completed against the latest diff

Reply with feedback, questions, or to request a fix.

View guided diff | Re-trigger cubic

Comment thread src/httpx2/httpx2/_models.py Resolved

@cubic-dev-ai cubic-dev-ai Bot left a comment •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

All reported issues were addressed across 20 files

Reply with feedback, questions, or to request a fix.

View guided diff | Re-trigger cubic

Comment thread src/httpcore2/httpcore2/_async/http2.py Resolved
@Viicos
Viicos merged commit f4f65c1 into main Nov 7, 2026
22 of 25 checks passed
@Viicos
Viicos deleted the vp/lint branch November 7, 2026 11:25
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

Successfully merging this pull request may close these issues.

1 participant