[GH-ISSUE #153] Latest docker images produce an error in handler.wsgi #119

Closed
opened 2026-02-25 21:31:15 +03:00 by kerem · 8 comments
Owner

Originally created by @DrVanSteiner on GitHub (Oct 9, 2020).
Original GitHub issue: https://github.com/ciur/papermerge/issues/153

Originally assigned to: @ciur on GitHub.

Description
Docker images with tag latest produce an error when opening the UI. (Previous versions work fine, just changed the version)

Actual
When navigation to WebUI:

FileNotFoundError: [Errno 2] No such file or directory: '/opt/app/ '

Info:
I suspect somewhere a typo with an ending space.

Originally created by @DrVanSteiner on GitHub (Oct 9, 2020). Original GitHub issue: https://github.com/ciur/papermerge/issues/153 Originally assigned to: @ciur on GitHub. **Description** Docker images with tag _latest_ produce an error when opening the UI. (Previous versions work fine, just changed the version) **Actual** When navigation to WebUI: `FileNotFoundError: [Errno 2] No such file or directory: '/opt/app/ '` **Info:** I suspect somewhere a typo with an ending space.
kerem 2026-02-25 21:31:15 +03:00
  • closed this issue
  • added the
    bug
    label
Author
Owner

@DrVanSteiner commented on GitHub (Oct 9, 2020):

log.txt

<!-- gh-comment-id:706062055 --> @DrVanSteiner commented on GitHub (Oct 9, 2020): [log.txt](https://github.com/ciur/papermerge/files/5353706/log.txt)
Author
Owner

@ciur commented on GitHub (Oct 9, 2020):

Hi @DrVanSteiner, thank you for opening the issue.

Please don't use image tagged with "latest".

The docker image tagged with "latest" is pulled from master branch which is development branch. Please use image tagged with 1.4.5 instead.

<!-- gh-comment-id:706080242 --> @ciur commented on GitHub (Oct 9, 2020): Hi @DrVanSteiner, thank you for opening the issue. Please don't use image tagged with "latest". The docker image tagged with "latest" is pulled from master branch which is development branch. **Please use image tagged with 1.4.5 instead.**
Author
Owner

@williwehrlos commented on GitHub (Oct 10, 2020):

Its happening with 1.4.5 too

<!-- gh-comment-id:706557220 --> @williwehrlos commented on GitHub (Oct 10, 2020): Its happening with 1.4.5 too
Author
Owner

@maxiride commented on GitHub (Oct 10, 2020):

Please use image tagged with 1.4.5 instead.

I encountered the same error with the 1.4.5 tag. Following the documentation:

  • I cloned the repo locally
  • Entered the 1.4 docker folder cd docker/1.4 which used the image image: eugenci/papermerge:1.4.5
  • Changed the external port to 8001 (due to port conflict)
  • Issued docker-compose up -d

The webapp homepage shows a 500 Internal server error:

Internal Server Error
The server encountered an internal error or misconfiguration and was unable to complete your request.
Please contact the server administrator at [no address given] to inform them of the time this error occurred, and the actions you performed just before this error.
More information about this error may be available in the server error log.

The log:

  
[Sat Oct 10 14:15:53.910486 2020] [wsgi:error] [pid 158:tid 139731586509888] mod_wsgi (pid=158): Failed to exec Python script file '/opt/app//handler.wsgi'.,
[Sat Oct 10 14:15:53.910580 2020] [wsgi:error] [pid 158:tid 139731586509888] mod_wsgi (pid=158): Exception occurred processing WSGI script '/opt/app//handler.wsgi'.,
[Sat Oct 10 14:15:53.911583 2020] [wsgi:error] [pid 158:tid 139731586509888] Traceback (most recent call last):,
[Sat Oct 10 14:15:53.911640 2020] [wsgi:error] [pid 158:tid 139731586509888]   File "/opt/app//handler.wsgi", line 89, in <module>,
[Sat Oct 10 14:15:53.911668 2020] [wsgi:error] [pid 158:tid 139731586509888]     handler = mod_wsgi.server.ApplicationHandler(entry_point,,
[Sat Oct 10 14:15:53.911682 2020] [wsgi:error] [pid 158:tid 139731586509888]   File "/opt/app/.venv/lib/python3.8/site-packages/mod_wsgi/server/__init__.py", line 1421, in __init__,
[Sat Oct 10 14:15:53.911686 2020] [wsgi:error] [pid 158:tid 139731586509888]     with open(entry_point, 'r') as fp:,
[Sat Oct 10 14:15:53.911710 2020] [wsgi:error] [pid 158:tid 139731586509888] FileNotFoundError: [Errno 2] No such file or directory: '/opt/app/ '

I've also tried to checkout the git commit tag 1.4.4 and launch the docker-compose file from there obtaining an altogether different issue which I suppose isn't worth mentioning as I think it is better to focus on the latest release.

<!-- gh-comment-id:706558502 --> @maxiride commented on GitHub (Oct 10, 2020): > Please use image tagged with 1.4.5 instead. I encountered the same error with the 1.4.5 tag. Following the [documentation](https://papermerge.readthedocs.io/en/latest/setup/docker.html): - I cloned the repo locally - Entered the 1.4 docker folder `cd docker/1.4` which used the [image](https://github.com/ciur/papermerge/blob/master/docker/1.4/docker-compose.yml#L4) `image: eugenci/papermerge:1.4.5` - Changed the [external port to 8001](https://github.com/ciur/papermerge/blob/master/docker/1.4/docker-compose.yml#L10) (due to port conflict) - Issued `docker-compose up -d` The webapp homepage shows a 500 Internal server error: > Internal Server Error The server encountered an internal error or misconfiguration and was unable to complete your request. Please contact the server administrator at [no address given] to inform them of the time this error occurred, and the actions you performed just before this error. More information about this error may be available in the server error log. The log: ``` [Sat Oct 10 14:15:53.910486 2020] [wsgi:error] [pid 158:tid 139731586509888] mod_wsgi (pid=158): Failed to exec Python script file '/opt/app//handler.wsgi'., [Sat Oct 10 14:15:53.910580 2020] [wsgi:error] [pid 158:tid 139731586509888] mod_wsgi (pid=158): Exception occurred processing WSGI script '/opt/app//handler.wsgi'., [Sat Oct 10 14:15:53.911583 2020] [wsgi:error] [pid 158:tid 139731586509888] Traceback (most recent call last):, [Sat Oct 10 14:15:53.911640 2020] [wsgi:error] [pid 158:tid 139731586509888] File "/opt/app//handler.wsgi", line 89, in <module>, [Sat Oct 10 14:15:53.911668 2020] [wsgi:error] [pid 158:tid 139731586509888] handler = mod_wsgi.server.ApplicationHandler(entry_point,, [Sat Oct 10 14:15:53.911682 2020] [wsgi:error] [pid 158:tid 139731586509888] File "/opt/app/.venv/lib/python3.8/site-packages/mod_wsgi/server/__init__.py", line 1421, in __init__, [Sat Oct 10 14:15:53.911686 2020] [wsgi:error] [pid 158:tid 139731586509888] with open(entry_point, 'r') as fp:, [Sat Oct 10 14:15:53.911710 2020] [wsgi:error] [pid 158:tid 139731586509888] FileNotFoundError: [Errno 2] No such file or directory: '/opt/app/ ' ``` I've also tried to checkout the git commit tag 1.4.4 and launch the docker-compose file from there obtaining an altogether different issue which I suppose isn't worth mentioning as I think it is better to focus on the latest release.
Author
Owner

@ciur commented on GitHub (Oct 11, 2020):

ok, I will have a look. Thank you for heads up, guys!

<!-- gh-comment-id:706655527 --> @ciur commented on GitHub (Oct 11, 2020): ok, I will have a look. Thank you for heads up, guys!
Author
Owner

@ciur commented on GitHub (Oct 11, 2020):

OK, I was able to reproduce it! Very strange! Investigating...

<!-- gh-comment-id:706681298 --> @ciur commented on GitHub (Oct 11, 2020): OK, I was able to reproduce it! Very strange! Investigating...
Author
Owner

@ciur commented on GitHub (Oct 11, 2020):

The problem was because I included "a whitespace" after comment in startup script - it considered that "whitespace" as entry point.
Lesson learned: no (white)spaces after backslash character :)

<!-- gh-comment-id:706687030 --> @ciur commented on GitHub (Oct 11, 2020): The problem was because I included "a whitespace" after comment in startup script - it considered that "whitespace" as entry point. Lesson learned: no (white)spaces after backslash character :)
Author
Owner

@ciur commented on GitHub (Oct 12, 2020):

Fix is now part of 1.5.rc1

<!-- gh-comment-id:706880817 --> @ciur commented on GitHub (Oct 12, 2020): Fix is now part of [1.5.rc1](https://github.com/ciur/papermerge/releases/tag/v1.5.0.rc1)
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/papermerge#119
No description provided.