Skip to content
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

Fix syntax error in http handler #254

Closed
wants to merge 1 commit into from
Closed

Fix syntax error in http handler #254

wants to merge 1 commit into from

Conversation

susodapop
Copy link
Contributor

This code path never runs from DBR because we never send a Set-Cookie header. But some internal users during testing have found this codepath raises a syntax error.

Signed-off-by: Jesse Whitehouse <[email protected]>
@@ -191,7 +189,7 @@ def flush(self):

# Saves the cookie sent by the server response
if "Set-Cookie" in self.headers:
self.setCustomHeaders(dict("Cookie", self.headers["Set-Cookie"]))
self.setCustomHeaders({"Cookie", self.headers["Set-Cookie"]})

Choose a reason for hiding this comment

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

I don't think setCustomHeaders is correct here, this will replace all existing headers . Shouldn't it be something like headers.update to append ?

@benc-db
Copy link
Collaborator

benc-db commented Mar 26, 2024

Close in favor of newer PR

@benc-db benc-db closed this Mar 26, 2024
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.

3 participants