in reply to Re: Request returns "200 OK", reports internal server error.
in thread Request returns "200 OK", reports internal server error. [solved]

Thanks for your comment! The code in question has in it:

use Apache::Constants qw( OK REDIRECT etc. );

Also, this is only triggered in a special case. That is, something like this:

sub general_request_handler { # do the usual stuff if ( $r->param( 'special' ) ) { # go off and do something special } # etc. }

We're taking the same path otherwise, and the "return OK" is fine there, so I don't think that's the problem here. Also, it doesn't happen every time the special case is used, only for certain users, certain data sets.

Thanks again.

Replies are listed 'Best First'.
Re^3: Request returns "200 OK", reports internal server error.
by perrin (Chancellor) on Sep 18, 2008 at 18:37 UTC
    Well, the word "OK" in your error response is very suspicious. Try adding a warn to log the value of OK, and try making that sub return "OK()" to force the call to the imported sub.

      I did this:

      $ find lib -type f -name \*.pm -print|xargs perl -pi.bak -e 's/return +OK/return OK()/'

      (That was pretty fun.)

      I'm still getting the same results. Thanks again for your suggestions.

      P. S. — I did this to put it all back:

      find lib -name \*.bak -print|perl -lne 'chomp;$f=$_;s/\.bak$//;print " +mv -v $f $_"'|sh