Last modified: 2014-07-24 19:27:22 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 T69990, the corresponding Phabricator task for complete and up-to-date bug report information.
Bug 67990 - Run mwgrep over commonswiki_p
Run mwgrep over commonswiki_p
Status: RESOLVED WONTFIX
Product: Wikimedia
Classification: Unclassified
General/Unknown (Other open bugs)
wmf-deployment
All All
: Unprioritized normal (vote)
: ---
Assigned To: Nobody - You can work on this!
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2014-07-14 15:16 UTC by Rainer Rillke @commons.wikimedia
Modified: 2014-07-24 19:27 UTC (History)
1 user (show)

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


Attachments

Description Rainer Rillke @commons.wikimedia 2014-07-14 15:16:22 UTC
I'd like to know about use of deprecated functions and properties at Wikimedia Commons.

Using search (Lucene, Cirrus and Google) w/o quotation marks and w/o insource option I got very few intersection. Therefore I'd like to know whether there is still deprecated code around in the MW namespace at Commons.

Please search for (case sensitive, full word only):
* toJSON
* evalJSON
* secureEvalJSON
* live
* die
* is_*
is_clientPC
is_chrome_mac
is_chrome
webkit_version
is_safari_win
is_safari
webkit_match
is_ff2
ff2_bugs
is_ff2_win
is_ff2_x11
opera95_bugs
opera7_bugs
opera6_bugs
is_opera_95
is_opera_preseven
is_opera
ie6_bugs
* doneOnloadHook
* onloadFuncts
* runOnloadHook
* changeText
* killEvt
* addHandler
* hookEvent
* addClickHandler
* removeHandler
* getElementsByClassName
* getInnerText
* mwEditButtons
* mwCustomEditButtons
* checkboxes
* lastCheckbox
* setupCheckboxShiftClick
* addCheckboxClickHandlers
* checkboxClickHandler
* injectSpinner
* removeSpinner
* escapeQuotes
* escapeQuotesHTML
* jsMsg
* quoteString
* addButton
* insertTags
* user.name
* user.anonymous
* util.wikiGetlink
* util.tooltipAccessKeyPrefix
* liveAndTestAtStart
* $j
* gM
Comment 1 Rainer Rillke @commons.wikimedia 2014-07-14 18:51:20 UTC
mwgrep cannot be run on a single wiki
Comment 2 Krinkle 2014-07-14 19:00:10 UTC
mwgrep is specifically designed to run a search across all wikis. It doesn't have an option to search one wiki.

To search an individual wiki, just use Special:Search (with namespace=8 to limit results to the MediaWiki-namespace).

mwgrep uses the same ElasticSearch backend that the new CirrusSearch uses (which you may have to opt-in via the preferences, or pass &srbackend=CirrusSearch to Special:Search).

As general advice I'd also recommend you don't use search too much when working your way through deprecations. The console is more reliable for this. Both because search in general tends to be fragile (it's meant for English, not code, it misses random things all the time), and encourages a mindset of "0 matches means the code is good". Which is wrong not only because search is fragile, but also because lots of deprecations don't have a text match (e.g. specific signatures of jQuery methods).

You should identify deprecations through the console by it emitting a warning. This way you catch them all, and you're also able to debug it locally, find where the warning is coming from (e.g. make some edits locally, try it out, etc.).

And it also helps focus on code that is actually run on pages you use (as opposed to potentially abandoned/unused code).


As we get closer to the deadline, I will make a few dumps of global mwgrep searches which you may use to also find the left overs on Commons (they'll be grouped by wiki)
Comment 3 Rainer Rillke @commons.wikimedia 2014-07-14 19:06:37 UTC
(In reply to Krinkle from comment #2)
> I will make a few dumps of global mwgrep searches which you may use to also 
> find the left overs on Commons
Thank you!

> And it also helps focus on code that is actually run on pages you use
I don't agree. Non-considered deprecations are ticking time bombs waiting to somebody tick a checkmark, blowing up their JavaScript execution and making them to complain at the Village Pump that their whole JS does not work by using obfuscated symptoms like "Link X went away yesterday" because they didn't realize that ticking the checkmark was the trigger.

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


Navigation
Links