Commit Graph

2 Commits

Author SHA1 Message Date
Alexander Botello bc26ab3319 Support either `cleanup` or `shutdown` in ASGI lifespan messages (#134)
* support either cleanup or shutdown in ASGI message

* change event_type in tests

* update docs

* fix typo

* keep  as event_type for now

* exclude line 65

* blackify

* replace cleanup with shutdown in docs
2018-10-22 15:08:04 +01:00
Tom Christie 139753f857
Add support for `app.on_event("startup")` and `app.on_event("cleanup")`. (#98)
* Push black linting into ./scripts/test Fix some annotations etc.

* Skip black on 3.7

* Fix script

* Blergh. Shell equality tests are weird

* Attempt to fix equality check

* Document 'allow_origin_regex'

* Support app.on_event('startup') and app.on_event('cleanup')

* Nicer decorator handling for on_event

* Add documentation for app.on_event()
2018-10-09 15:47:51 +01:00