Skip to content
This repository was archived by the owner on Jan 13, 2021. It is now read-only.

Raising error in HTTP11Response if created with illegal attributes - #235

Open
AvivC wants to merge 1 commit into
python-hyper:developmentfrom
AvivC:validate-http11-response-info
Open

AvivC wants to merge 1 commit into
python-hyper:developmentfrom
AvivC:validate-http11-response-info

Conversation

@AvivC

@AvivC AvivC commented Apr 25, 2016

Copy link
Copy Markdown
Contributor

An HTTP response must either specify a content-length header, specify
'close' for a connection header to signal that the connection will be
closed after the response, or be a chunked response.

If none of these conditions are true, we raise a detailed ValueError,
instead of the plain assertion.

@Lukasa

Lukasa commented Apr 25, 2016

Copy link
Copy Markdown
Member

Thanks for this! The patch fails the linter: do you mind cleaning that up?

@AvivC
AvivC force-pushed the validate-http11-response-info branch 2 times, most recently from 1d8f94b to 1fb6f2b Compare April 25, 2016 17:22
An HTTP response must either specify a content-length header, specify
'close' for a connection header to signal that the connection will be
closed after the response, or be a chunked response.

If none of these conditions are true, we raise a detailed ValueError,
instead of the plain assertion.
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

2 participants