Last modified: 2013-10-19 00:34:45 UTC

Wikimedia Bugzilla is closed!

Wikimedia migrated from Bugzilla to Phabricator. Bug reports are handled in Wikimedia Phabricator.
This static website is read-only and for historical purposes. It is not possible to log in and except for displaying bug reports and their history, links might be broken. See T28792, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 26792 - Add global variable to disable newPP limit report
Add global variable to disable newPP limit report
Status: REOPENED
Product: MediaWiki
Classification: Unclassified
Parser (Other open bugs)
1.22.0
All All
: Normal enhancement (vote)
: ---
Assigned To: Nobody - You can work on this!
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2011-01-18 14:16 UTC by plix tixiplik
Modified: 2013-10-19 00:34 UTC (History)
2 users (show)

See Also:
Web browser: ---
Mobile Platform: ---
Assignee Huggle Beta Tester: ---


Attachments

Description plix tixiplik 2011-01-18 14:16:30 UTC
There is currently no way (that I can find) to disable the HTML comment added by the Parser detailing the "newPPP limit report" without restoring to changing the method call of enableLimitReport() in ParserOptions. 

Not all wikis want or need that HTML comment, especially in API output where it will usually be stripped from the HTML down the line. A global like $wgEnableParserLimitReporting (default true) that could be added to LocalSettings.php and set to false would be much appreciated.
Comment 1 Sam Reed (reedy) 2011-01-18 18:33:29 UTC
SVN trunk, and as such, 1.17 will have, &disablepp in action=parse on the API already...
Comment 2 Mark A. Hershberger 2011-01-19 20:29:38 UTC
Unless you plan to make this a 1.17 blocker, it isn't going in 1.17.
Comment 3 Sam Reed (reedy) 2013-10-14 22:37:50 UTC
Tagging as (very) easy - addition of new global to DefaultSettings.php, use parser/Parser.php around line 534/535 and encompass down to around 560 and then document on mediawiki.org
Comment 4 Gerrit Notification Bot 2013-10-14 23:34:30 UTC
Change 89758 had a related patch set uploaded by Reedy:
Add $wgEnableParserLimitReporting to control whether the NewPP limit report is included as a HTML comment.

https://gerrit.wikimedia.org/r/89758
Comment 5 Gerrit Notification Bot 2013-10-17 22:43:07 UTC
Change 89758 merged by jenkins-bot:
Add $wgEnableParserLimitReporting to control whether the NewPP limit report is included as a HTML comment.

https://gerrit.wikimedia.org/r/89758
Comment 6 MZMcBride 2013-10-18 00:46:31 UTC
I don't understand the point of this global. Re-opening this bug for further consideration.

Can someone please provide a use-case for disabling this HTML comment?
Comment 7 Sam Reed (reedy) 2013-10-18 00:52:25 UTC
(In reply to comment #6)
> I don't understand the point of this global. Re-opening this bug for further
> consideration.
> 
> Can someone please provide a use-case for disabling this HTML comment?

Surely the person requesting this is the use case?
Comment 8 MZMcBride 2013-10-18 03:38:48 UTC
(In reply to comment #7)
> Surely the person requesting this is the use case?

Globals are annoying to maintain. My rough count in DefaultSettings.php at the time of this commit says there are about 730 global configuration variables. Before we add yet another, I'd like there to be a good reason. Database password, script path, etc. ... okay, that makes sense. But an option to disable an HTML comment from the parser output to a standard Web browser? Why?

There's currently one comment from one user (comment 0) saying he or she wants to disable the HTML comment. We have a robust Web API that includes a flag specifically to disable this HTML comment in machine-readable HTML output. What more is needed here?

If this still doesn't convince you, imagine you put every configuration variable next to a checkbox or drop-down menu in a graphical user interface. I doubt many people would think the additional user interface clutter is warranted here.

Note You need to log in before you can comment on or make changes to this bug.


Navigation
Links