Neoteroi / BlackSheep

Fast ASGI web framework for Python
https://www.neoteroi.dev/blacksheep/
MIT License
1.86k stars 78 forks source link

Issue with OpenAPIHandler doc route for /openapi.json when using `root_path` prefix #488

Open jlujan-invitae opened 6 months ago

jlujan-invitae commented 6 months ago

When setting a root_path of "/prefix" on the uvicorn app, the /docs route from the example/template app results in a 404 when attempting to load /openapi.json. Explicitly setting OpenAPIHandler(...,json_spec_path="/prefix/openapi.json") or to a full URL also returns 404.