Last modified: 2013-06-18 16:57:53 UTC
Created attachment 6128 [details] Patch against Linker.php r50720 - approximate number of edits in rollback It's not particularly clear what the difference is between rollback and undo, as shown at http://lists.wikimedia.org/pipermail/wikitech-l/2009-May/042946.html, and I've chosen the wrong link myself before. Perhaps it would be better if the link text read "rollback 3 edits | undo" - instead of "rollback | undo". The estimated number of edits could be anything from 1 to (literally) 10+. This should be enough to disambiguate the functionality. If this code would run too slow on heavy traffic wikis, perhaps we could make it optional. Somewhat related to the discussion at bug #10531.
Patch commited in r50721
OK cool - then two other things: * Need to change "rollbacklink" in language files to "rollback {{PLURAL:$1|1 edit|$1 edits}}", right? * Since function buildRollbackLink() now may return false, we need to account for that in PageHistory.php (will attach another diff).
Created attachment 6130 [details] Don't show a rollback link when set to false
Comment on attachment 6130 [details] Don't show a rollback link when set to false No longer needed.
Created attachment 6131 [details] Approximate number of edits in rollback Addresses most of http://www.mediawiki.org/wiki/Special:Code/MediaWiki/50721
Reopening as it seems more debate is needed.
Fixed in 50727
Fixed in r50727
Reverted in r50732; patch fails to set default values, has some other potential issues per notes in CR, and the commit is wrapped up with what appear to be unrelated changes making code review extra confusing.
Suggest enabling this feature by default. It should be useful on most sites and not too expensive except for the largest ones. For DefaultSettings.php: /** * Show rollback link as "rollback 3 edits" instead of just "rollback", to * differentiate it from the "undo" link with which it appears. Set to false * if too expensive for larger wikis. */ $wgShowRollbackEditCount = true;
Created attachment 6132 [details] Add "rollbacklinkcount" to messages.inc
Should the number listed be exact or approximate? If exact, the query is going to more expensive. If approximate, then how to reflect that the count is an estimate? Setting the count to "10+" may break localization and apparently breaks {{PLURAL:}}.
Created attachment 6135 [details] Patch for the new Linker function All changes needed to add the function as patch. Please controll it because in my commited changes was bug.
*Bulk BZ Change: +Patch to open bugs with patches attached that are missing the keyword*
Adding the need-review keyword to indicate that these patches are awaiting review. Joshua, Jan, could you mark any obsolete patches as obsolete to clarify what needs review currently? Thanks for your patches, and sorry for the wait.
Comment on attachment 6132 [details] Add "rollbacklinkcount" to messages.inc Marking as obsolete. No "rollbacklinkcount" message in MessageEn.php as of trunk
Comment on attachment 6131 [details] Approximate number of edits in rollback This patch no longer applies to trunk per Rusty Burchfield's automated testing https://docs.google.com/spreadsheet/ccc?key=0Ah_71HHl7qa7dGtvSms3TGpHQU9NU2Y1VmNzUEUteWc .
Comment on attachment 6135 [details] Patch for the new Linker function This patch no longer cleanly applies to trunk per Rusty Burchfield's automated testing https://docs.google.com/spreadsheet/ccc?key=0Ah_71HHl7qa7dGtvSms3TGpHQU9NU2Y1VmNzUEUteWc .
I've removed the "patch" and "need-review" keywords since there's no applicable patch to be reviewed. Jan Luca, Josh Lerner, is one of you interested in revising and attaching the patch, if still desired?
New patch created and uploaded to Gerrit for review: https://gerrit.wikimedia.org/r/#/c/16932/
Feature merged to core in https://gerrit.wikimedia.org/r/#/c/16932 + https://gerrit.wikimedia.org/r/#/c/17335/
For future reference. In $wgMiserMode (enabled by default on WMF servers) the rollback count for Special:RecentChanges and Special:Watchlist is disabled.
Can we please insert a colon ("rollback: 1 edit")? "Rollback" is a noun (not a verb), so the current formatting is grammatically incorrect.
There is the verb "to rollback". Quote from http://oxforddictionaries.com/definition/english/rollback?q=rollback: ... verb [with object] Computing restore (a database) to a previously defined state.
Thanks for bringing that to my attention. But the verb form describes a specific situation in computing (restoring a database to a previously defined state). In the relevant context (reverting to an earlier revision of a wiki page, with subsequent edits retained in the database and history), "rollback" means "act or instance of rolling back". http://dictionary.reference.com/browse/rollback http://www.merriam-webster.com/dictionary/rollback Is the addition of a colon ("rollback: 2 edits") technically feasible?
There is no problem on the technical side (change of < 10 code line) but I prefer the current version. If there are more support for your version I could change the code.
Can you recommend an appropriate forum in which to discuss the matter? This bug is unlikely to generate much additional traffic.
I created a discussion on translatewiki.net: MediaWiki:Rollbacklinkcount/en]]_and_[[MediaWiki:Rollbacklinkcount-morethan/en]]_26448">https://translatewiki.net/wiki/Translating_talk:MediaWiki#About_[[MediaWiki:Rollbacklinkcount/en]]_and_[[MediaWiki:Rollbacklinkcount-morethan/en]]_26448