[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Page MenuHomePhabricator

OpenStackManager test fails with "Call to a member function doLogout() on boolean"
Closed, ResolvedPublic

Description

SpecialNovaProject calls new OpenStackNovaUser(), which makes the username default to the empty string, then OpenStackNovaUser::getCredentials() calls OpenStackNovaController::newFromUser( $this ) and getUnscopedToken() on the resulting controller object, which tries to create a User with the empty username and fails (without any error checking). This breaks SpecialPageFatalTest (a core structure test which initializes every special page to see if the code runs without errors).

If the special pages are not used anymore, it should be removed.

08:36:41 1) SpecialPageFatalTest::testSpecialPageDoesNotFatal with data set "NovaProject" (SpecialNovaProject Object (...))
08:36:41 Error: Call to a member function doLogout() on boolean
08:36:41 
08:36:41 /workspace/src/extensions/OpenStackManager/nova/OpenStackNovaController.php:1063
08:36:41 /workspace/src/extensions/OpenStackManager/nova/OpenStackNovaUser.php:78
08:36:41 /workspace/src/extensions/OpenStackManager/nova/OpenStackNovaUser.php:162
08:36:41 /workspace/src/extensions/OpenStackManager/special/SpecialNovaProject.php:31
08:36:41 /workspace/src/tests/phpunit/includes/specials/SpecialPageExecutor.php:108
08:36:41 /workspace/src/tests/phpunit/includes/specials/SpecialPageExecutor.php:36
08:36:41 /workspace/src/tests/phpunit/structure/SpecialPageFatalTest.php:34
08:36:41 /workspace/src/tests/phpunit/MediaWikiTestCase.php:424
08:36:41 /workspace/src/maintenance/doMaintenance.php:94
08:36:41 
08:36:41 2) SpecialPageFatalTest::testSpecialPageDoesNotFatal with data set "NovaVolume" (SpecialNovaVolume Object (...))
08:36:41 Error: Call to a member function doLogout() on boolean
08:36:41 
08:36:41 /workspace/src/extensions/OpenStackManager/nova/OpenStackNovaController.php:1063
08:36:41 /workspace/src/extensions/OpenStackManager/nova/OpenStackNovaUser.php:78
08:36:41 /workspace/src/extensions/OpenStackManager/nova/OpenStackNovaUser.php:162
08:36:41 /workspace/src/extensions/OpenStackManager/special/SpecialNovaVolume.php:31
08:36:41 /workspace/src/tests/phpunit/includes/specials/SpecialPageExecutor.php:108
08:36:41 /workspace/src/tests/phpunit/includes/specials/SpecialPageExecutor.php:36
08:36:41 /workspace/src/tests/phpunit/structure/SpecialPageFatalTest.php:34
08:36:41 /workspace/src/tests/phpunit/MediaWikiTestCase.php:424
08:36:41 /workspace/src/maintenance/doMaintenance.php:94
08:36:41 
08:36:41 3) SpecialPageFatalTest::testSpecialPageDoesNotFatal with data set "NovaSudoer" (SpecialNovaSudoer Object (...))
08:36:41 Error: Call to a member function doLogout() on boolean
08:36:41 
08:36:41 /workspace/src/extensions/OpenStackManager/nova/OpenStackNovaController.php:1063
08:36:41 /workspace/src/extensions/OpenStackManager/nova/OpenStackNovaUser.php:78
08:36:41 /workspace/src/extensions/OpenStackManager/nova/OpenStackNovaUser.php:162
08:36:41 /workspace/src/extensions/OpenStackManager/special/SpecialNovaSudoer.php:23
08:36:41 /workspace/src/tests/phpunit/includes/specials/SpecialPageExecutor.php:108
08:36:41 /workspace/src/tests/phpunit/includes/specials/SpecialPageExecutor.php:36
08:36:41 /workspace/src/tests/phpunit/structure/SpecialPageFatalTest.php:34
08:36:41 /workspace/src/tests/phpunit/MediaWikiTestCase.php:424
08:36:41 /workspace/src/maintenance/doMaintenance.php:94
08:36:41 
08:36:41 4) SpecialPageFatalTest::testSpecialPageDoesNotFatal with data set "NovaResources" (SpecialNovaResources Object (...))
08:36:41 Error: Call to a member function doLogout() on boolean
08:36:41 
08:36:41 /workspace/src/extensions/OpenStackManager/nova/OpenStackNovaController.php:1063
08:36:41 /workspace/src/extensions/OpenStackManager/nova/OpenStackNovaUser.php:78
08:36:41 /workspace/src/extensions/OpenStackManager/nova/OpenStackNovaUser.php:162
08:36:41 /workspace/src/extensions/OpenStackManager/special/SpecialNovaResources.php:39
08:36:41 /workspace/src/tests/phpunit/includes/specials/SpecialPageExecutor.php:108
08:36:41 /workspace/src/tests/phpunit/includes/specials/SpecialPageExecutor.php:36
08:36:41 /workspace/src/tests/phpunit/structure/SpecialPageFatalTest.php:34
08:36:41 /workspace/src/tests/phpunit/MediaWikiTestCase.php:424
08:36:41 /workspace/src/maintenance/doMaintenance.php:94

Event Timeline

Change 492480 had a related patch set uploaded (by Umherirrender; owner: Umherirrender):
[mediawiki/extensions/OpenStackManager@master] Error: Call to a member function doLogout() on boolean

https://gerrit.wikimedia.org/r/492480

Change 492480 merged by jenkins-bot:
[mediawiki/extensions/OpenStackManager@master] Error: Call to a member function doLogout() on boolean

https://gerrit.wikimedia.org/r/492480

Umherirrender claimed this task.
Umherirrender triaged this task as Medium priority.