Issue:DPL does not work with Cite-Extension under MW1.12

From FollowTheScore
Jump to: navigation, search
Description: DPL does not work with Cite-Extension under MW1.12
Extension / Version: DPL   /   1.7.4
Type / Status: Bug   /   open


When using DPL together with the Cite-Extension by Ævar Arnfjörð Bjarmason under MediaWiki 1.12 the following error occurs:

Using a DPL-statement between(!) a <ref>- and a <references/>-statement will leave the corresponding references empty (no references are displayed).


This is a test<ref>This is some footnote-text</ref>

... Here comes some DPL-code ...

== References ==



Set $wgParserConf['class'] = 'Parser_OldPP'; in LocalSettings.php of your MW-Deployment and use the parser function syntax of DPL.


The problem still exists with the newly released MW1.13.

This issue still occurs in MW 1.15.1, too! tedo 20:19, 14 October 2009 (UTC)


Does the same problem occur when you use a parser function call for DPL ({{#dpl: ...}}) ? An old version of Cite is installed here in this wiki ... Gero 06:00, 15 October 2009 (UTC)

Yes, the same problem occurs when using parser function calls. --Carroe 10:17, 17 February 2010 (UTC)
The problem seems to be with localparser->transformMsg. I ran into this before (transformMsg resets the parser state), but I don't know why it's affecting the main parser since localparser is a copy and is supposed to avoid exactly this problem. -- Nx / talk 07:16, 4 November 2010 (UTC)
Ok, the only thing you can do is not use transformMsg. transformMsg clears the parser state and the Cite extension has a hook that clears its internal state (i.e. the saved refs) when this happens (using ParserClearState), no matter which parser's state was cleared. The Cite extension could be improved to have one instance for every parser instead of a single global instance, but that's how it is... -- Nx / talk 08:04, 4 November 2010 (UTC)
And of course the other parser clones in DPL.php etc... this is quite a nice mess. -- Nx / talk 08:26, 4 November 2010 (UTC)