wsproto
wsproto copied to clipboard
`RemoteProtocolError` `event_hint` parameter
Hi :wave:
I was trying to add a test on uvicorn, when conn.receive_data() was able to send a RemoteProtocolError without an error hint:
https://github.com/encode/uvicorn/blob/22bd00eab6dfa7145618ce6cd1acfdffea8bbe6e/uvicorn/protocols/websockets/wsproto_impl.py#L89-L94
But the thing is... In the whole wsproto source code, there's always an event_hint being sent.
Can we make event_hint mandatory here?
https://github.com/python-hyper/wsproto/blob/a7d9ff0c34567b042d025db555595bb6234f89e8/src/wsproto/utilities.py#L50
EDIT: See https://github.com/encode/uvicorn/pull/1486.
👋
👋
Seems fine to me.
On Sun, Dec 17, 2023, 00:59 Marcelo Trylesinski @.***> wrote:
👋
— Reply to this email directly, view it on GitHub https://github.com/python-hyper/wsproto/issues/178#issuecomment-1859078382, or unsubscribe https://github.com/notifications/unsubscribe-auth/AAEU42DRJZCFBAAPQR5HTFTYJ2YARAVCNFSM6AAAAAARR526MKVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMYTQNJZGA3TQMZYGI . You are receiving this because you are subscribed to this thread.Message ID: @.***>
Why?
@Kludex happy to review a PR and consider it for the next minor API-breaking release!