Wikimedia

Replace ~10 deprecated "Revision::getText" calls in 10 MediaWiki extensions (II)

This task might be boring, but boring stuff is also part of a developer's job.

In MediaWiki Core's ContentHandler "module", a lot of hooks+functions were deprecated in version 1.21 (1.21 is unsupported since 2014).

Many of these deprecated hooks+functions are still used in code of MediaWiki extensions ("technical debt") and should be replaced. These extensions need cleaning up so that the deprecated functions can finally be removed from the MediaWiki core code!

You will have to look at the deprecated function in the MediaWiki Core code repository. It will have a "@deprecated since 1.XX use foobar" comment which tells you what to replace it with. You have to look up the correct use + parameters of the replacement. Note that the new function is likely not a direct replacement so you need to change more than just one single line. You could check for code in MediaWiki Core that has already been replaced, for examples how to use the new function.

Then you could search for "->getText(" in the following repositories + provide patches in Gerrit:

  • mediawiki/extensions/ConfirmEdit/SimpleCaptcha
  • mediawiki/extensions/JsonData
  • mediawiki/extensions/PageForms
  • mediawiki/extensions/Patroller
  • mediawiki/extensions/PopupPages
  • mediawiki/extensions/Premoderation
  • mediawiki/extensions/RandomImage
  • mediawiki/extensions/SpamDiffTool
  • mediawiki/extensions/WikimediaMaintenance
  • mediawiki/extensions/WikiObjectModel

The commit message of your Gerrit patch(es) must have the line "Bug: T151973".

Task tags

  • php
  • technical debt

Students who completed this task

Filip

Task type

  • code Code
close

2016