Skip to content

Commit

Permalink
Update change_upstream_proxy.py (#6853)
Browse files Browse the repository at this point in the history
Script was not working as ServerSpec accepts a tuple, which was not supplied. I fixed it so a tuple is supplied to ServerSpec
  • Loading branch information
fosple committed May 18, 2024
1 parent d6dc12c commit 0503fbb
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion examples/contrib/change_upstream_proxy.py
Original file line number Diff line number Diff line change
Expand Up @@ -31,4 +31,4 @@ def request(flow: http.HTTPFlow) -> None:
# server_conn already refers to an existing connection (which cannot be modified),
# so we need to replace it with a new server connection object.
flow.server_conn = Server(address=flow.server_conn.address)
flow.server_conn.via = ServerSpec("http", address)
flow.server_conn.via = ServerSpec(("http", address))

0 comments on commit 0503fbb

Please sign in to comment.