Description

After migrating to moin 1.9.2, moin refuses to spawn a FCGI server.

Steps to reproduce

  1. Migrate to moin 1.9.2.
  2. Use the new server script (moin.fcgi).

Example

$ ./moin.fcgi -i 127.0.0.1 -p 60000
WSGIServer: missing FastCGI param REQUEST_METHOD required by WSGI!
WSGIServer: missing FastCGI param SERVER_NAME required by WSGI!
WSGIServer: missing FastCGI param SERVER_PORT required by WSGI!
WSGIServer: missing FastCGI param SERVER_PROTOCOL required by WSGI!
Status: 404 NOT FOUND
Content-Type: text/html

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2 Final//EN">
<title>404 Not Found</title>
<h1>Not Found</h1>
<p>No wiki configuration matching the URL found!</p>

Component selection

Details

MoinMoin Version

1.9.2

OS and Version

Debian stable

Python Version

2.5.2

Server Setup

Lighttpd + FastCGI

Server Details

Language you are using the wiki in (set in the browser/UserPreferences)

fr

Workaround

Discussion

The new script is not intended to be used with cmdline arguments. You can still use the old moin.cgi script (as you did before).

Alternatively, look into flup.server.fcgi:

class WSGIServer(BaseFCGIServer, ThreadedServer):
    """
    FastCGI server that supports the Web Server Gateway Interface. See
    <http://www.python.org/peps/pep-0333.html>.
    """
    def __init__(self, application, environ=None,
                 multithreaded=True, multiprocess=False,
                 bindAddress=None, umask=None, multiplexed=False,
                 debug=False, roles=(FCGI_RESPONDER,), forceCGI=False, **kw):
        """
        environ, if present, must be a dictionary-like object. Its
        contents will be copied into application's environ. Useful
        for passing application-specific variables.

        bindAddress, if present, must either be a string or a 2-tuple. If
        present, run() will open its own listening socket. You would use
        this if you wanted to run your application as an 'external' FastCGI
        app. (i.e. the webserver would no longer be responsible for starting
        your app) If a string, it will be interpreted as a filename and a UNIX
        socket will be opened. If a tuple, the first element, a string,
        is the interface name/IP to bind to, and the second element (an int)
        is the port number.
        """
...

As you see, you could modify the moin.fcgi to call WSGIServer(application, bindAddress=('127.0.0.1', 60000)).

Plan


CategoryMoinMoinNoBug

MoinMoin: MoinMoinBugs/1.9.2FastCgiServerScriptDoesNotStart (last edited 2010-03-20 21:28:18 by ThomasWaldmann)