Skip to content
New issue

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

Web interface in Docker container/ Error when uploading document: "Must be either POST with the field 'file'...." #136

Open
cboulanger opened this issue May 13, 2021 · 2 comments

Comments

@cboulanger
Copy link

I am running the Web service in a Docker container. When trying to upload and process a file, I am getting the following Error: Must be either POST with file field 'file' or GET with param 'url'.

Bildschirmfoto 2021-05-13 um 12 37 58

Environment:

  • MacOS 11.3.1
  • Docker Engine v20.10.0
  • ocr-transform v0.4.0
@cboulanger
Copy link
Author

Ok, in the logs I see this:

[Thu May 13 10:41:22 2021] 172.17.0.1:63222 Accepted
[Thu May 13 10:41:23 2021] PHP Warning:  POST Content-Length of 14446932 bytes exceeds the limit of 8388608 bytes in Unknown on line 0
[Thu May 13 10:41:23 2021] 172.17.0.1:63222 [400]: POST /ocr-fileformat.php?do=transform&from=abbyy&to=page
[Thu May 13 10:41:23 2021] 172.17.0.1:63222 Closing

Seems like you need to increase the file size limit for PHP or, if you don't want to do that, provide an more informative error message.

kba added a commit to kba/ocr-schemas that referenced this issue May 14, 2021
kba added a commit to kba/ocr-schemas that referenced this issue May 14, 2021
stweil pushed a commit that referenced this issue Jul 6, 2022
@stweil
Copy link
Member

stweil commented Jul 6, 2022

The latest code no longer limits the upload size when running in a Docker container.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants