[Moin-devel] Re: 1.3.2 does not run on IIS due to error in request.py

Alexander Schremmer 2004b at usenet.alexanderweb.de
Mon Jan 24 08:25:21 EST 2005


On Mon, 24 Jan 2005 17:21:30 +0100, Robert Seeger wrote:

> In request.py, function RequestBase::_setup_vars_from_std_env there is some
> special code to handle some strange stuff on windows.
> The first branch is supposed to be checking for apache and if this fails,
> the second branch is checking for IIS.
> However the second branch is never executed due to an obvious error in the
> first check:
> 
>         # First check if we can use Apache's request_uri variable in order
> to
>         # gather the correct user input
>         if (os.name != 'posix' and server_software.find('Apache/1.3') == -1
>             and self.request_uri != ''):
>             import urllib
>             path_info =
> urllib.unquote(self.request_uri.replace(self.script_name, '', 1).replace('?'
> + query_string, '', 1))
> 
> 
> Obviously if we are using IID, then
> 	server_software.find('Apache/1.3') == -1
> is always true.
> 
> The correct check should be
>         if (os.name != 'posix' and server_software.find('Apache/1.3') != -1
> 
> The symptoms of this error were not easy to understand, because most of the
> unit tests (I re-enabled them) worked OK and I could perfectly work with
> FrontPage - but only with FrontPage! Whichever page was requested I always
> got just FrontPage.

Can you give me the URL to your site? Did you change the if line to 
if (os.name != 'posix' and server_software.find('Apache/1.3') != -1:?

Can I have the output of your CGI environment (is printed if you request
the tests from localhost)? I would like to know if IIS gives you the
request_uri. If it does not, the above patch does not make any sense
because it sets path_info to an empty string.

Kind regards,
Alexander





More information about the Moin-devel mailing list