panoptes / POCS

An Observatory Control System for the PANOPTES citizen-science project designed to help find transiting exoplanets! :telescope: :stars:
https://pocs.readthedocs.io/en/latest/
MIT License
77 stars 49 forks source link

Fix fastapi deprecation warning in power service #1208

Closed wtgee closed 6 months ago

wtgee commented 8 months ago

Showing up in the CI

panoptes/pocs/utils/service/power.py:28: DeprecationWarning: 
      on_event is deprecated, use lifespan event handlers instead.

      Read more about it in the
      [FastAPI docs for Lifespan Events](https://fastapi.tiangolo.com/advanced/events/).

    @app.on_event('startup')
wtgee commented 6 months ago

Fixed by #1209