We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
pdf_ocr_service/src/app.py
Lines 97 to 107 in 8d2f336
These exceptions are not reachable, due to the fact that the exception from FileResponse is raised after the return.
As noted in https://stackoverflow.com/questions/74103330/fastapi-fileresponse-not-entering-the-except-block/74103398#74103398 a simple os.stat() on the file's path before the return is enough to trigger the exceptions as expected.
os.stat()
The text was updated successfully, but these errors were encountered:
No branches or pull requests
pdf_ocr_service/src/app.py
Lines 97 to 107 in 8d2f336
These exceptions are not reachable, due to the fact that the exception from FileResponse is raised after the return.
As noted in https://stackoverflow.com/questions/74103330/fastapi-fileresponse-not-entering-the-except-block/74103398#74103398 a simple
os.stat()
on the file's path before the return is enough to trigger the exceptions as expected.The text was updated successfully, but these errors were encountered: