fastapi: 404 Error with OpenAPI
Hi all,
New to fastAPI, and coming from Flask, I’m very impressed by the solution.
But using the OpenAPI documentation/UI, I can see in the logs that I have the following issue each time I extend a resource/API :
INFO: <IP>:57175 - "GET /%5Bobject%20Module%5D HTTP/1.1" 404 Not Found
The API is working, but I get this error in the log.
I’m using v0.63.0, on an ubuntu server (18.04)
Thanks a lot for your support.
About this issue
- Original URL
- State: closed
- Created 3 years ago
- Reactions: 17
- Comments: 27 (3 by maintainers)
Created a pull request with a temporary fix to this (#2656). Thanks @Gatux for linking the issue with the monkey patch.
I also get the samme INFO message in my log
Thanks a lot,
Just checked, and I’ve got the same issue even if I expand a GET, PUT or DELETE resource. Let say that I click on this item to expand it, I’ll get the log :
INFO: <IP>:51426 - "GET /%5Bobject%20Module%5D HTTP/1.1" 404 Not FoundSame thing if I do it on a POST item :
INFO: <IP>:51504 - "GET /%5Bobject%20Module%5D HTTP/1.1" 404 Not FoundI have the issue whatever the route and associated method I expand. But if it has been expanded/loaded 1 time, I will never get the issue for it if I collapse/expand it, until I refresh the page (Which is quite obvious as content as been loaded…)
It also returns a
404response when passingurlas a path parameter.Above code works if path paremeter is a plain string eg.
some-string, but not for something likehttps://facebook.com. Terminal logs show that the request url isIt fails to encode the slashes. On swagger I have the following data, tho
I hope this gets fix soon. I really love FastAPI
Hi, Welcome to FastAPI
please follow the Issue instruction. we need more information to help you. thanks.