Error message generated by mod_wsgi

35 views
Skip to first unread message

Thomas W Ekberg

unread,
Jul 13, 2022, 7:12:34 PM7/13/22
to modwsgi
1. Which version of mod_wsgi you are using and if using a packaged
distribution, who provided the distribution. If you are not using the
latest version, then upgrade first and verify the problem still occurs
with the latest version.
4.9.0, daemon mode

2. Which version of Python you are using and if using a packaged distribution, who provided the distribution.
3.10.4

3. Which version of Apache you are using and if using a packaged
distribution, who provided the distribution. If not using latest patch
revision of Apache 2.2, then consider upgrading and trying again.
2.4.52

4. What operating system you are using.
Ubuntu 22.04

5. Details on any third party packages being used and what versions of those packages.
roundup 2.1 - https://www.roundup-tracker.org/index.html

6. The mod_wsgi configuration you are using from Apache configuration
files.
No modules-enabled/wsgi.conf values were specified. All remained
commented out.

7. Relevant error messages from the Apache error logs.

[Wed Jul 13 14:49:16.925053 2022] [wsgi:error] [pid 109702:tid 140471824799296] [remote 10.67.135.184:53189] mod_wsgi (pid=109702): Exception occurred processing WSGI script '/mnt/trackers/it_test/apache/wsgi.py'.
[Wed Jul 13 14:49:16.925097 2022] [wsgi:error] [pid 109702:tid 140471824799296] [remote 10.67.135.184:53189] RuntimeError: response has not been started

The exception message is generated in server/wsgi_logger.c at lines 628 and
633.  This code is in the wsgi_log_python_error function. This
function is called 29 times in server/mod_wsgi.c. It would be nice if
those 29 places passed a message with some detail on the error
encountered. Sophos is turned off, and SELinux is disabled.

The roundup code uses request.wfile to write its HTML code. The
rouhdup code that does this completes with no error and passes control
back to mod_wsgi, which generates the above messages in the apache
error.log file.

Do you have an idea on how to troubleshoot this problem?

Graham Dumpleton

unread,
Jul 13, 2022, 7:16:36 PM7/13/22
to mod...@googlegroups.com
The error means that the WSGI application has tried to return response content but has not called the WSGI start_response() callable first.


What WSGI framework is being used, or is this a custom WSGI application you are trying to create from scratch?

Graham

--
You received this message because you are subscribed to the Google Groups "modwsgi" group.
To unsubscribe from this group and stop receiving emails from it, send an email to modwsgi+u...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/modwsgi/9554bbac-0cc4-45df-b85c-038f91ae0f07n%40googlegroups.com.

Thomas W Ekberg

unread,
Jul 15, 2022, 10:37:29 AM7/15/22
to modwsgi
Graham,

Thank you for your response. The problem was that an exception was thrown, bypassing the code that does the start_response() call. Fixing the problem allowed the web page to display.

Tom

Reply all
Reply to author
Forward
0 new messages