Deprecate DO_MAINTENANCE
[lhc/web/wiklou.git] / RELEASE-NOTES-1.31
index 3a7102a..ea3aa8b 100644 (file)
@@ -31,11 +31,8 @@ production.
 * (T188472) The 'comma' value for $wgArticleCountMethod is no longer supported for
   performance reasons, and installations with this setting will now work as if it
   was configured with 'any'.
-* (T185753) MediaWiki now defaults to using RemexHtml to tidy up user input, rather than
-  being off by default. If you wish to disable HTML tidying entirely, set $wgTidyConfig
-  to null; if you wish to use the old, deprecated Tidy external binary, both
-  set $wgTidyConfig to null and also set $wgUseTidy to true.
 * $wgLogAutopatrol now defaults to false instead of true.
+* $wgValidateAllHtml was removed and will be ignored.
 
 === New features in 1.31 ===
 * (T76554) User sub-pages named ….json are now protected in the same way that ….js
@@ -124,7 +121,9 @@ production.
   returned regardless.
 
 === Action API internal changes in 1.31 ===
-* …
+* ApiBase::getProfileDBTime was removed (deprecated since 1.25)
+* ApiBase::getModuleProfileName was removed (deprecated since 1.25)
+* ApiBase::getProfileTime was removed (deprecated since 1.25)
 
 === Languages updated in 1.31 ===
 MediaWiki supports over 350 languages. Many localisations are updated
@@ -139,20 +138,11 @@ changes to languages because of Phabricator reports.
 * (T187750) New language support: Spanish formal address (es-formal).
 * (T187824) New language support: Hungarian formal address (hu-formal).
 
-=== Other changes in 1.31 ===
-* Browser support for Internet Explorer 10 was lowered from Grade A to Grade C.
-* Introducing multi-content-revision capability into the storage layer. For details,
-  see <https://www.mediawiki.org/wiki/Requests_for_comment/Multi-Content_Revisions>.
-* The Revision class was deprecated in favor of RevisionStore, BlobStore, and
-  RevisionRecord and its subclasses.
+=== Breaking changes in 1.31 ===
 * MessageBlobStore::insertMessageBlob() (deprecated in 1.27) was removed.
-* The global function wfBCP47 was renamed to LanguageCode::bcp47.
-* The global function wfBCP47 is now deprecated.
-* The global function wfCountDown() is now deprecated in favor of
-  Maintenance::countDown()
 * The OutputPage class constructor now requires a context parameter,
   (instantiating without context was deprecated in 1.18)
-* mw.page (deprecated in 1.30) was removed.
+* The mw.page JavaScript singleton (deprecated in 1.30) was removed.
 * Article::getLastPurgeTimestamp(), WikiPage::getLastPurgeTimestamp(), and the
   related WikiPage::PURGE_* constants, deprecated in 1.29, were removed.
 * The Article::selectFields(), Article::onArticleCreate(),
@@ -160,58 +150,13 @@ changes to languages because of Phabricator reports.
   in 1.24, were removed.
 * Installer::locateExecutable() and Installer::locateExecutableInDefaultPaths()
   were removed, use ExecutableFinder::findInDefaultPaths() instead.
-* Several methods for returning lists of fields to select from the database
-  have been deprecated in favor of similar methods that also return the tables
-  to select from and the join conditions for those tables.
-  * Block::selectFields() → Block::getQueryInfo()
-  * RecentChange::selectFields() → RecentChange::getQueryInfo()
-  * ArchivedFile::selectFields() → ArchivedFile::getQueryInfo()
-  * LocalFile::selectFields() → LocalFile::getQueryInfo()
-  * LocalFile::getCacheFields() with a prefix no longer works
-  * LocalFile::getLazyCacheFields() with a prefix no longer works
-  * OldLocalFile::selectFields() → OldLocalFile::getQueryInfo()
-  * RecentChange::selectFields() → RecentChange::getQueryInfo()
-  * Revision::userJoinCond() → Revision::getQueryInfo( [ 'user' ] )
-  * Revision::selectUserFields() → Revision::getQueryInfo( [ 'user' ] )
-  * Revision::pageJoinCond() → Revision::getQueryInfo( [ 'page' ] )
-  * Revision::selectPageFields() → Revision::getQueryInfo( [ 'page' ] )
-  * Revision::selectTextFields() → Revision::getQueryInfo( [ 'text' ] )
-  * Revision::selectFields() → Revision::getQueryInfo()
-  * Revision::selectArchiveFields() → Revision::getArchiveQueryInfo()
-  * User::selectFields() → User::getQueryInfo()
-  * WikiPage::selectFields() → WikiPage::getQueryInfo()
-* Due to significant refactoring, method ContribsPager::getUserCond() that had
-  no access restriction has been removed.
-* Revision::setUserIdAndName() was deprecated.
-* Access to TitleValue class properties was deprecated, the relevant getters
-  should be used instead.
-* DifferenceEngine::getDiffBodyCacheKey() is deprecated. Subclasses should
-  override DifferenceEngine::getDiffBodyCacheKeyParams() instead.
 * The deprecated MW_DIFF_VERSION constant was removed.
   DifferenceEngine::MW_DIFF_VERSION should be used instead.
-* Use of Maintenance::error( $err, $die ) to exit script was deprecated. Use
-  Maintenance::fatalError() instead.
-* Passing a ParserOptions object to OutputPage::parserOptions() is deprecated.
-* Browser support for Opera 12 and older was removed.
-  Opera 15+ continues at Grade A support.
+* Due to significant refactoring, method ContribsPager::getUserCond() that had
+  no access restriction has been removed.
 * The Block class will no longer accept usable-but-missing usernames for
   'byText' or ->setBlocker(). Callers should either ensure the blocker exists
   locally or use a new interwiki-format username like "iw>Example".
-* The RevisionInsertComplete hook is now deprecated, use RevisionRecordInserted instead.
-  RevisionInsertComplete is still called, but the second and third parameter will always be null.
-  Hard deprecation is scheduled for 1.32.
-* The following methods that get and set ParserOutput state are deprecated.
-  Callers should use the new stateless $options parameter to
-  ParserOutput::getText() instead.
-  * ParserOptions::getEditSection()
-  * ParserOptions::setEditSection()
-  * ParserOutput::getEditSectionTokens()
-  * ParserOutput::setEditSectionTokens()
-  * ParserOutput::getTOCEnabled()
-  * ParserOutput::setTOCEnabled()
-  * OutputPage::enableSectionEditLinks()
-  * OutputPage::sectionEditLinksEnabled()
-  * The public ParserOutput state fields $mTOCEnabled and $mEditSectionTokens are also deprecated.
 * The following methods and constants from the WatchedItem class, which were deprecated in
   1.27, have been removed.
   * WatchedItem::getTitle()
@@ -231,7 +176,6 @@ changes to languages because of Phabricator reports.
   has been deprecated since 1.27 and was removed as well.
 * The HtmlFormatter class was removed (deprecated in 1.27). The namespaced
   HtmlFormatter\HtmlFormatter class should be used instead.
-* License::getLicenses has been deprecated; use License::getLines instead.
 * The driver 'mysql' for MySQL, deprecated in MediaWiki 1.30, has been removed.
   The driver has been deprecated since PHP 5.5 and was removed in PHP 7.0. The
   default driver for MySQL has been 'mysqli' since MediaWiki 1.22.
@@ -239,18 +183,8 @@ changes to languages because of Phabricator reports.
   * PreparedEdit->newText
   * PreparedEdit->oldText
   * PreparedEdit->pst
-* QuickTemplate::setRef() was deprecated in favour of QuickTemplate::set().
-  Setting template variables by reference allowed violating the principle of data being
-  immutable once added to the skin template. In practice, this method was not being
-  used for that. Rather, setRef() existed as memory optimisation for PHP 4.
-* QuickTemplate::setTranslator() was deprecated in favour of Skin::msg() parameters.
-* MediaWikiI18N::set() was deprecated in favour of Skin::msg() parameters.
-* MediaWikiI18N::translate() was deprecated in favour of Skin::msg() or wfMessage().
-* Passing false to ParserOptions::setWrapOutputClass() is deprecated. Use the
-  'unwrap' transform to ParserOutput::getText() instead.
 * ParserOutput objects generated using a non-default value for
-  ParserOptions::setWrapOutputClass() can no longer be added to the parser
-  cache.
+  ParserOptions::setWrapOutputClass() can no longer be added to the parser cache.
 * The following deprecated methods from the OutputPage class have been removed:
   * OutputPage::addExtensionStyle(); deprecated in 1.27
   * OutputPage::getExtStyle(); deprecated in 1.27
@@ -261,23 +195,6 @@ changes to languages because of Phabricator reports.
   * Additionally, the protected OutputPage::$mExtStyles array, only accessed through
     the above and with no known uses, was removed.
 * The no-op method Skin::showIPinHeader(), deprecated in 1.27, was removed.
-* \ObjectFactory (no namespace) is deprecated, the namespaced \Wikimedia\ObjectFactory
-  from the wikimedia/object-factory library should be used instead.
-* CommentStore::newKey is deprecated. Get an instance from MediaWikiServices instead.
-* The following CommentStore methods have had their signatures changed to introduce a $key parameter,
-  usage of the methods on instances retrieved from CommentStore::newKey will remain unchanged but deprecated:
-  * CommentStore::getFields
-  * CommentStore::getJoin
-  * CommentStore::getComment
-  * CommentStore::getCommentLegacy
-  * CommentStore::insert
-  * CommentStore::insertWithTemplate
-* The following methods in Title have been renamed, and the old ones are deprecated:
-  * Title::getSkinFromCssJsSubpage – use ::getSkinFromConfigSubpage
-  * Title::isCssOrJsPage – use ::isSiteConfigPage
-  * Title::isCssJsSubpage – use ::isUserConfigPage
-  * Title::isCssSubpage – use ::isUserCssConfigPage
-  * Title::isJsSubpage – use ::isUserJsConfigPage
 * The following variables and methods in EditPage, deprecated in MediaWiki 1.30, were removed:
   * $isCssJsSubpage — use ::isUserConfigPage()
   * $isCssSubpage — use ::isUserCssConfigPage()
@@ -288,9 +205,6 @@ changes to languages because of Phabricator reports.
   * ::getCheckboxes() – use ::getCheckboxesWidget() or ::getCheckboxesDefinition()
   * ::getCheckboxesOOUI() – use ::getCheckboxesWidget() or ::getCheckboxesDefinition()
 * The method ResourceLoaderModule::getPosition(), deprecated in 1.29, has been removed.
-* The DeferredStringifier class is deprecated, use Message::listParam() instead.
-* The type string for the parameter $lang of DateFormatter::getInstance is
-  deprecated.
 * In User, the cookie-related methods which were wrappers for the functions on the response
   object, and were deprecated in 1.27, have been removed:
   * ::setCookie()
@@ -302,24 +216,12 @@ changes to languages because of Phabricator reports.
   * ::getPasswordFactory() – create a PasswordFactory directly
   * ::passwordChangeInputAttribs()
 * The global functions wfProfileIn and wfProfileOut, deprecated in 1.25, have been removed.
-* The following methods related to caching of half-parsed HTML were deprecated:
-  * Parser::serializeHalfParsedText()
-  * Parser::unserializeHalfParsedText()
-  * Parser::isValidHalfParsedText()
-  * StripState::getSubState()
-  * StripState::merge()
-* The "free" CSS class is now only applied to unbracketed URLs in wikitext. Links
-  written using square brackets will get the class "text" not "free".
 * SpecialPageFactory::getList(), deprecated in 1.24, has been removed. You can
   use ::getNames() instead.
 * OpenSearch::getOpenSearchTemplate(), deprecated in 1.25, has been removed. You
   can use ApiOpenSearch::getOpenSearchTemplate() instead.
 * The global function wfBaseConvert, deprecated in 1.27, has been removed. Use
   Wikimedia\base_convert() directly.
-* RFC 157418: Whitespace is trimmed from wikitext headings, wikitext list items,
-  wikitext table captions, wikitext table headings, wikitext table cells. HTML
-  headings, HTML list items, HTML table captions, HTML table headings, HTML table cells
-  will not have this trimming behavior.
 * Calling Database::begin() explicitly during an implicit transaction or when DBO_TRX
   is set results in an exception. Calling Database::commit() explicitly for an implicit
   transaction also results in an exception. Previously these were logged as errors.
@@ -335,7 +237,114 @@ changes to languages because of Phabricator reports.
   can use MediaWikiTitleCodec::getTitleInvalidRegex() instead.
 * HTMLForm & VFormHTMLForm::isVForm(), deprecated in 1.25, have been removed.
 * The ProfileSection class, deprecated in 1.25 and unused, has been removed.
+* The ResourceLoaderGetLessVars hook, deprecated in 1.30, has been removed.
+  Use ResourceLoaderModule::getLessVars() to expose local variables instead
+  of global ones.
+* As part of work to modernise user-generated content clean-up, a config option and some
+  methods related to HTML validity were removed without deprecation. The public methods
+  MWTidy::checkErrors() and its callee TidyDriverBase::validate() are removed, as are
+  MediaWikiTestCase::assertValidHtmlSnippet() and ::assertValidHtmlDocument(). The
+  $wgValidateAllHtml configuration option is removed and will be ignored.
+
+=== Deprecations in 1.31 ===
+* The Revision class was deprecated in favor of RevisionStore, BlobStore, and
+  RevisionRecord and its subclasses.
+* The global function wfBCP47 is deprecated in favour of LanguageCode::bcp47.
+* The global function wfCountDown is now deprecated in favor of Maintenance::countDown.
+* Several methods for returning lists of fields to select from the database
+  have been deprecated in favor of similar methods that also return the tables
+  to select from and the join conditions for those tables.
+  * Block::selectFields() → Block::getQueryInfo()
+  * RecentChange::selectFields() → RecentChange::getQueryInfo()
+  * ArchivedFile::selectFields() → ArchivedFile::getQueryInfo()
+  * LocalFile::selectFields() → LocalFile::getQueryInfo()
+  * LocalFile::getCacheFields() with a prefix no longer works
+  * LocalFile::getLazyCacheFields() with a prefix no longer works
+  * OldLocalFile::selectFields() → OldLocalFile::getQueryInfo()
+  * RecentChange::selectFields() → RecentChange::getQueryInfo()
+  * Revision::userJoinCond() → Revision::getQueryInfo( [ 'user' ] )
+  * Revision::selectUserFields() → Revision::getQueryInfo( [ 'user' ] )
+  * Revision::pageJoinCond() → Revision::getQueryInfo( [ 'page' ] )
+  * Revision::selectPageFields() → Revision::getQueryInfo( [ 'page' ] )
+  * Revision::selectTextFields() → Revision::getQueryInfo( [ 'text' ] )
+  * Revision::selectFields() → Revision::getQueryInfo()
+  * Revision::selectArchiveFields() → Revision::getArchiveQueryInfo()
+  * User::selectFields() → User::getQueryInfo()
+  * WikiPage::selectFields() → WikiPage::getQueryInfo()
+* Revision::setUserIdAndName() was deprecated.
+* Access to TitleValue class properties was deprecated, the relevant getters
+  should be used instead.
+* DifferenceEngine::getDiffBodyCacheKey() is deprecated. Subclasses should
+  override DifferenceEngine::getDiffBodyCacheKeyParams() instead.
+* Use of Maintenance::error( $err, $die ) to exit script was deprecated. Use
+  Maintenance::fatalError() instead.
+* Passing a ParserOptions object to OutputPage::parserOptions() is deprecated.
+* The RevisionInsertComplete hook is now deprecated, use RevisionRecordInserted instead.
+  RevisionInsertComplete is still called, but the second and third parameter will always be null.
+  Hard deprecation is scheduled for 1.32.
+* The following methods that get and set ParserOutput state are deprecated.
+  Callers should use the new stateless $options parameter to
+  ParserOutput::getText() instead.
+  * ParserOptions::getEditSection()
+  * ParserOptions::setEditSection()
+  * ParserOutput::getEditSectionTokens()
+  * ParserOutput::setEditSectionTokens()
+  * ParserOutput::getTOCEnabled()
+  * ParserOutput::setTOCEnabled()
+  * OutputPage::enableSectionEditLinks()
+  * OutputPage::sectionEditLinksEnabled()
+  * The public ParserOutput state fields $mTOCEnabled and $mEditSectionTokens are also deprecated.
+* License::getLicenses has been deprecated; use License::getLines instead.
+* QuickTemplate::setRef() was deprecated in favour of QuickTemplate::set().
+  Setting template variables by reference allowed violating the principle of data being
+  immutable once added to the skin template. In practice, this method was not being
+  used for that. Rather, setRef() existed as memory optimisation for PHP 4.
+* QuickTemplate::setTranslator() was deprecated in favour of Skin::msg() parameters.
+* MediaWikiI18N::set() was deprecated in favour of Skin::msg() parameters.
+* MediaWikiI18N::translate() was deprecated in favour of Skin::msg() or wfMessage().
+* Passing false to ParserOptions::setWrapOutputClass() is deprecated. Use the
+  'unwrap' transform to ParserOutput::getText() instead.
+* \ObjectFactory (no namespace) is deprecated, the namespaced \Wikimedia\ObjectFactory
+  from the wikimedia/object-factory library should be used instead.
+* CommentStore::newKey is deprecated. Get an instance from MediaWikiServices instead.
+* The following CommentStore methods have had their signatures changed to introduce a $key parameter,
+  usage of the methods on instances retrieved from CommentStore::newKey will remain unchanged but deprecated:
+  * CommentStore::getFields
+  * CommentStore::getJoin
+  * CommentStore::getComment
+  * CommentStore::getCommentLegacy
+  * CommentStore::insert
+  * CommentStore::insertWithTemplate
+* The following methods in Title have been renamed, and the old ones are deprecated:
+  * Title::getSkinFromCssJsSubpage – use ::getSkinFromConfigSubpage
+  * Title::isCssOrJsPage – use ::isSiteConfigPage
+  * Title::isCssJsSubpage – use ::isUserConfigPage
+  * Title::isCssSubpage – use ::isUserCssConfigPage
+  * Title::isJsSubpage – use ::isUserJsConfigPage
+* The following methods related to caching of half-parsed HTML were deprecated:
+  * Parser::serializeHalfParsedText()
+  * Parser::unserializeHalfParsedText()
+  * Parser::isValidHalfParsedText()
+  * StripState::getSubState()
+  * StripState::merge()
+* The DeferredStringifier class is deprecated, use Message::listParam() instead.
+* The type string for the parameter $lang of DateFormatter::getInstance is
+  deprecated.
 * Wikimedia\Rdbms\SavepointPostgres is deprecated.
+* The DO_MAINTENANCE constant is deprecated. RUN_MAINTENANCE_IF_MAIN should be
+  used instead.
+
+=== Other changes in 1.31 ===
+* Browser support for Internet Explorer 10 was lowered from Grade A to Grade C.
+* Browser support for Opera 12 and older was removed. Opera 15+ continues at Grade A.
+* Introducing multi-content-revision capability into the storage layer. For details,
+  see <https://www.mediawiki.org/wiki/Requests_for_comment/Multi-Content_Revisions>.
+* The "free" CSS class is now only applied to unbracketed URLs in wikitext. Links
+  written using square brackets will get the class "text" not "free".
+* RFC 157418: Whitespace is trimmed from wikitext headings, wikitext list items,
+  wikitext table captions, wikitext table headings, wikitext table cells. HTML
+  headings, HTML list items, HTML table captions, HTML table headings, HTML table cells
+  will not have this trimming behavior.
 
 == Compatibility ==
 MediaWiki 1.31 requires PHP 5.5.9 or later. Although HHVM 3.18.5 or later is supported,