Bug ID: 62467
           Summary: maint script importTextFile.php doesn't set the title
                    for the context
           Product: MediaWiki
           Version: unspecified
          Hardware: All
                OS: All
            Status: NEW
          Severity: normal
          Priority: Unprioritized
         Component: Export/Import
       Web browser: ---
   Mobile Platform: ---

If a parserhook tries to get the title from the request context (as the
UserFunctions extension does) then that will cause importTextFile.php to fail:

PHP Fatal error:  Call to a member function getNamespace() on a non-object in
/vagrant/mediawiki/extensions/UserFunctions/UserFunctions.php on line 84
PHP Stack trace:
PHP   1. {main}() /vagrant/mediawiki/maintenance/importTextFile.php:0
PHP   2. WikiPage->doEdit()
PHP   3. WikiPage->prepareTextForEdit()
PHP   4. Parser->preSaveTransform()
PHP   5. Parser->startParse()
PHP   6. Parser->clearState()
PHP   7. Parser->firstCallInit()
PHP   8. wfRunHooks() /vagrant/mediawiki/includes/parser/Parser.php:237
PHP   9. Hooks::run() /vagrant/mediawiki/includes/GlobalFunctions.php:3859
PHP  10. call_user_func_array:{/vagrant/mediawiki/includes/Hooks.php:216}()
PHP  11. UserFunctions_HookStub->registerParser()

This can be fixed by calling RequestContext::getMain()->setTitle( $title ) at
the right place.

You are receiving this mail because:
You are the assignee for the bug.
You are on the CC list for the bug.
Wikibugs-l mailing list

Reply via email to