Page MenuHomePhabricator

Exception: Unable to determine IP
Closed, ResolvedPublic

Description

Author: mwalker

Description:
Lots of this in fluorine's exception log:

2013-09-18 19:14:49 mw1028 enwiki: [6c87a086] /favicon.ico Exception from line 1161 of /usr/local/apache/common-local/php-1.22wmf16/includes/WebRequest.php: Unable to determine IP
#0 /usr/local/apache/common-local/php-1.22wmf16/includes/ProxyTools.php(59): WebRequest->getIP()
#1 /usr/local/apache/common-local/wmf-config/throttle.php(66): wfGetIP()
#2 [internal function]: efRaiseAccountCreationThrottle()
#3 /usr/local/apache/common-local/php-1.22wmf16/includes/Setup.php(592): call_user_func('efRaiseAccountC...')
#4 /usr/local/apache/common-local/php-1.22wmf16/includes/WebStart.php(156): require_once('/usr/local/apac...')
#5 /usr/local/apache/common-local/w/favicon.php(5): require('/usr/local/apac...')
#6 {main}


Version: 1.22.0
Severity: normal

Details

Reference
bz54288

Event Timeline

bzimport raised the priority of this task from to Needs Triage.Nov 22 2014, 1:58 AM
bzimport set Reference to bz54288.
bzimport added a subscriber: Unknown Object (MLST).

mwalker wrote:

efRaiseAccountCreationThrottle is in wmf-config/throttle.php; but the line that's failing was last touched in late 2012 so this is a regression of some sort.

Reedy added a comment.Sep 18 2013, 8:44 PM
  1. Allow extensions to improve our guess
		wfRunHooks( 'GetIP', array( &$ip ) );

		if ( !$ip ) {
			throw new MWException( "Unable to determine IP" );
		}

v> var_dump( $wgHooks['GetIP'] );
PHP Notice: Undefined index: GetIP in /a/common/php-1.22wmf16/maintenance/eval.php(72) : eval()'d code on line 1

Notice: Undefined index: GetIP in /a/common/php-1.22wmf16/maintenance/eval.php(72) : eval()'d code on line 1
NULL

There doesn't seem to be any subscribers to that hook. Not sure efRaiseAccountCreationThrottle is related either, it only calls wfGetIP();

reedy@fluorine:/a/mw-log$ grep "determine IP" -c exception.log
27401
reedy@fluorine:/a/mw-log$ grep -c "\[" exception.log
55579

So it accounts for a huge amount of the lines. I guess we need to stuff some more debugging in it

(In reply to comment #2)

I guess we need to stuff some more debugging in it

Reedy: Would you have time for that? If not, who else could do that? :-/

(In reply to comment #4)

https://gerrit.wikimedia.org/r/#/c/84866/ was merged and deployed

Ah thanks, Nemo! Based on the commit message, I guess that fixes it.