https://bugzilla.wikimedia.org/show_bug.cgi?id=56226

--- Comment #2 from Bawolff (Brian Wolff) <[email protected]> ---
Created attachment 13597
  --> https://bugzilla.wikimedia.org/attachment.cgi?id=13597&action=edit
patch that seems to fix issue. Make messageCache not clone $wgParser

Issue appears to stem from how MessageCache clones its parser, combined with an
exception from translate being the first thing that messageCache transforms,
happening during parsing



Here's the backtrace from the point where the uniqPrefix of the parser seems to
get changed:

<ul>
<li>Parser.php line 323 calls wfBacktrace()</li>
<li>Parser.php line 4837 calls Parser->clearState()</li>
<li>Parser.php line 628 calls Parser->startParse()</li>
<li>Parser.php line 4864 calls Parser->preprocess()</li>
<li>MessageCache.php line 982 calls Parser->transformMsg()</li>
<li>Message.php line 854 calls MessageCache->transform()</li>
<li>Message.php line 592 calls Message->transformText()</li>
<li>Message.php line 649 calls Message->toString()</li>

<li>TPException.php line 25 calls Message->text()</li>
<li>TranslatablePage.php line 291 calls TPException->__construct()</li>
<li>PageTranslationHooks.php line 32 calls TranslatablePage->getParse()</li>
<li>- line - calls PageTranslationHooks::renderTagPage()</li>
<li>Hooks.php line 199 calls call_user_func_array()</li>
<li>GlobalFunctions.php line 3877 calls Hooks::run()</li>
<li>Parser.php line 405 calls wfRunHooks()</li>
<li>WikitextContent.php line 300 calls Parser->parse()</li>
<li>EditPage.php line 3223 calls WikitextContent->getParserOutput()</li>

<li>EditPage.php line 2169 calls EditPage->getPreviewText()</li>
<li>EditPage.php line 441 calls EditPage->showEditForm()</li>
<li>EditAction.php line 50 calls EditPage->edit()</li>
<li>EditAction.php line 76 calls EditAction->show()</li>
<li>Wiki.php line 448 calls SubmitAction->show()</li>
<li>Wiki.php line 312 calls MediaWiki->performAction()</li>
<li>Wiki.php line 603 calls MediaWiki->performRequest()</li>
<li>Wiki.php line 467 calls MediaWiki->main()</li>
<li>index.php line 49 calls MediaWiki->run()</li>

</ul>


If I change MessageCache to create a new instance of parser instead of cloning,
issue goes away. So something funky with how cloning works perhaps?

-- 
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
[email protected]
https://lists.wikimedia.org/mailman/listinfo/wikibugs-l

Reply via email to