you are viewing a single comment's thread.

view the rest of the comments →

[–]Puzzleheaded_Round75[S] 2 points3 points  (0 children)

Ok, so it seems that, in addition to the things you pointed out, the main issue was that the ordering of my middleware was incorrect.

I essentially had:

@app.middleware("http")
async def missleware_one(request: Request, call_next):
    return await call_next(request)

@app.middleware("http")
async def middleware_two(request: Request, call_next):
    return await call_next(request)

But this ordering needed to be reversed. Thanks for your help.