Closed SalmonMode closed 5 years ago
@SalmonMode thanks for the PR. I will test this out and then merge it. Probably won't be today, but I will get to it as soon as I can.
I actually just found that the underlying websocket client is already looking for a subprotocols
argument that creates that specific header, so I changed it to use that instead of just passing it as a complete header.
@SalmonMode sorry for the delay. I finally got time to test this. Turns out the websocket client library already supports wss
, and we don't have to do anything. But your change to add the sub-protocol is useful though, so I am interested in merging this. But it would be better if can you change the commit messages, the PR message, changelog, readme etc. to reflect that (something like add graphql-ws
sub-protocol...).
you got it! All edited!
@SalmonMode sorry for the extreme delay! I have merged this and release a new beta version.
Install via: pip install py-graphql-client==0.1.1b1
Once you confirm it all works, I will publish a stable version (0.1.1).
Closes #1
Now passes the
"Sec-WebSocket-Protocol: graphql-ws"
in the initial connection, which should fix connecting over theWSS://
protocol for some servers.I also updated the changelog and readme files to reflect this