Сейчас я делаю следующее:
Код: Выделить всё
from fastapi import FastAPI
app = FastAPI()
items = {}
@app.on_event("startup")
def startup_event():
//Download file
Подробнее здесь: https://stackoverflow.com/questions/773 ... e-event-lo
Код: Выделить всё
from fastapi import FastAPI
app = FastAPI()
items = {}
@app.on_event("startup")
def startup_event():
//Download file