Closed myers closed 10 months ago
@myers that's the ASGI lifespan protocol call. Doesn't granian just raise a warning message and keep serving the app?
Ok, thank you I see now. You get an Assertion error, but it still works. May I suggest you handle that lifespan
in some what that doesn't display an error? It is confusing if you are not aware of the differences between lifespan and http messages.
I did roughly this:
create
main.py
the first call to app is with a scope like
{'type': 'lifespan', 'asgi': {'version': '3.0', 'spec_version': '2.3'}}
which trips the assert. Removing the assert allows it to work.