Hi 👋
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?
|
def __init__(self, message: str, event_hint: Optional[Event] = None) -> None: |
EDIT: See Kludex/uvicorn#1486.
Hi 👋
I was trying to add a test on
uvicorn, whenconn.receive_data()was able to send aRemoteProtocolErrorwithout 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
wsprotosource code, there's always anevent_hintbeing sent.Can we make
event_hintmandatory here?wsproto/src/wsproto/utilities.py
Line 50 in a7d9ff0
EDIT: See Kludex/uvicorn#1486.