Merge "selenium: Remove '☃' character (U+2603 snowman emoji) from random usernames"
authorjenkins-bot <jenkins-bot@gerrit.wikimedia.org>
Fri, 29 Jun 2018 19:37:18 +0000 (19:37 +0000)
committerGerrit Code Review <gerrit@wikimedia.org>
Fri, 29 Jun 2018 19:37:18 +0000 (19:37 +0000)
46 files changed:
RELEASE-NOTES-1.32
includes/MWNamespace.php
includes/MediaWikiServices.php
includes/MovePage.php
includes/ServiceWiring.php
includes/Storage/PageUpdater.php
includes/Storage/RevisionStore.php
includes/Storage/RevisionStoreFactory.php [new file with mode: 0644]
includes/api/ApiBase.php
includes/api/i18n/zh-hant.json
includes/deferred/LinksUpdate.php
includes/libs/MapCacheLRU.php
includes/libs/ProcessCacheLRU.php
includes/libs/objectcache/MultiWriteBagOStuff.php
includes/logging/LogEventsList.php
includes/logging/LogPager.php
includes/page/WikiPage.php
languages/data/Names.php
languages/i18n/be.json
languages/i18n/ce.json
languages/i18n/ckb.json
languages/i18n/eu.json
languages/i18n/io.json
languages/i18n/ja.json
languages/i18n/mni.json
languages/i18n/nn.json
languages/i18n/pnb.json
languages/i18n/ps.json
languages/i18n/sr-ec.json
languages/i18n/wa.json
languages/i18n/zh-hant.json
languages/messages/MessagesMni.php [new file with mode: 0644]
languages/messages/MessagesSa.php
maintenance/updateCollation.php
resources/Resources.php
resources/src/mediawiki.ForeignStructuredUpload.BookletLayout/BookletLayout.js
resources/src/mediawiki.rcfilters/styles/mw.rcfilters.ui.FilterTagMultiselectWidget.less
resources/src/mediawiki.rcfilters/ui/mw.rcfilters.ui.FilterTagMultiselectWidget.js
resources/src/mediawiki.special.changeslist.css
tests/phpunit/includes/MWNamespaceTest.php
tests/phpunit/includes/MediaWikiServicesTest.php
tests/phpunit/includes/Storage/RevisionStoreFactoryTest.php [new file with mode: 0644]
tests/phpunit/includes/libs/MapCacheLRUTest.php
tests/phpunit/includes/libs/ProcessCacheLRUTest.php
tests/phpunit/includes/libs/objectcache/MultiWriteBagOStuffTest.php
tests/phpunit/includes/page/WikiPageDbTestBase.php

index 5282236..d0d5eb2 100644 (file)
@@ -97,6 +97,7 @@ because of Phabricator reports.
 * (T194047) Added language support for Shawiya, Latin script (shy-latn).
 * (T195940) Added language support for Batak Mandailing (btm).
 * (T137491) Added language support for Standard Moroccan Amazigh (zgh).
+* (T198132) Added language support for Manipuri (mni).
 
 === Breaking changes in 1.32 ===
 * $wgRequestTime, deprecated in 1.25, was removed. Use
@@ -133,6 +134,7 @@ because of Phabricator reports.
 * The jquery.footHovzer module, for mediawiki.debug, was removed.
 * The es5-shim module, empty and deprecated since 1.29, was removed.
 * the dom-level2-shim module, empty and deprecated since 1.29, was removed.
+* the json module, empty and deprecated since 1.29, was removed.
 * The mediawiki.widgets.visibleByteLimit module alias, deprecated in 1.32, was
   removed. Use mediawiki.widgets.visibleLengthLimit instead.
 * The jquery.farbtastic module, unused since 1.18, was removed.
index 73fdd82..1df5d51 100644 (file)
@@ -540,4 +540,26 @@ class MWNamespace {
 
                return $usableLevels;
        }
+
+       /**
+        * Returns the link type to be used for categories.
+        *
+        * This determines which section of a category page titles
+        * in the namespace will appear within.
+        *
+        * @since 1.32
+        * @param int $index Namespace index
+        * @return string One of 'subcat', 'file', 'page'
+        */
+       public static function getCategoryLinkType( $index ) {
+               self::isMethodValidFor( $index, __METHOD__ );
+
+               if ( $index == NS_CATEGORY ) {
+                       return 'subcat';
+               } elseif ( $index == NS_FILE ) {
+                       return 'file';
+               } else {
+                       return 'page';
+               }
+       }
 }
index ac15574..caaa6b3 100644 (file)
@@ -21,6 +21,9 @@ use MediaWiki\Storage\NameTableStore;
 use MediaWiki\Storage\RevisionFactory;
 use MediaWiki\Storage\RevisionLookup;
 use MediaWiki\Storage\RevisionStore;
+use MediaWiki\Storage\RevisionStoreFactory;
+use OldRevisionImporter;
+use UploadRevisionImporter;
 use Wikimedia\Rdbms\LBFactory;
 use LinkCache;
 use Wikimedia\Rdbms\LoadBalancer;
@@ -757,6 +760,14 @@ class MediaWikiServices extends ServiceContainer {
                return $this->getService( 'RevisionStore' );
        }
 
+       /**
+        * @since 1.32
+        * @return RevisionStoreFactory
+        */
+       public function getRevisionStoreFactory() {
+               return $this->getService( 'RevisionStoreFactory' );
+       }
+
        /**
         * @since 1.31
         * @return RevisionLookup
@@ -829,6 +840,22 @@ class MediaWikiServices extends ServiceContainer {
                return $this->getService( 'ActorMigration' );
        }
 
+       /**
+        * @since 1.32
+        * @return UploadRevisionImporter
+        */
+       public function getUploadRevisionImporter() {
+               return $this->getService( 'UploadRevisionImporter' );
+       }
+
+       /**
+        * @since 1.32
+        * @return OldRevisionImporter
+        */
+       public function getOldRevisionImporter() {
+               return $this->getService( 'OldRevisionImporter' );
+       }
+
        ///////////////////////////////////////////////////////////////////////////
        // NOTE: When adding a service getter here, don't forget to add a test
        // case for it in MediaWikiServicesTest::provideGetters() and in
index 614ea7d..ec44b6e 100644 (file)
@@ -280,13 +280,7 @@ class MovePage {
                        [ 'cl_from' => $pageid ],
                        __METHOD__
                );
-               if ( $this->newTitle->getNamespace() == NS_CATEGORY ) {
-                       $type = 'subcat';
-               } elseif ( $this->newTitle->getNamespace() == NS_FILE ) {
-                       $type = 'file';
-               } else {
-                       $type = 'page';
-               }
+               $type = MWNamespace::getCategoryLinkType( $this->newTitle->getNamespace() );
                foreach ( $prefixes as $prefixRow ) {
                        $prefix = $prefixRow->cl_sortkey_prefix;
                        $catTo = $prefixRow->cl_to;
index 425b789..ba576d5 100644 (file)
@@ -46,7 +46,7 @@ use MediaWiki\Preferences\DefaultPreferencesFactory;
 use MediaWiki\Shell\CommandFactory;
 use MediaWiki\Storage\BlobStoreFactory;
 use MediaWiki\Storage\NameTableStore;
-use MediaWiki\Storage\RevisionStore;
+use MediaWiki\Storage\RevisionStoreFactory;
 use MediaWiki\Storage\SqlBlobStore;
 use Wikimedia\ObjectFactory;
 
@@ -463,10 +463,15 @@ return [
        },
 
        'RevisionStore' => function ( MediaWikiServices $services ) {
+               return $services->getRevisionStoreFactory()->getRevisionStore();
+       },
+
+       'RevisionStoreFactory' => function ( MediaWikiServices $services ) {
                /** @var SqlBlobStore $blobStore */
                $blobStore = $services->getService( '_SqlBlobStore' );
+               $config = $services->getMainConfig();
 
-               $store = new RevisionStore(
+               $store = new RevisionStoreFactory(
                        $services->getDBLoadBalancer(),
                        $blobStore,
                        $services->getMainWANObjectCache(),
@@ -474,14 +479,11 @@ return [
                        $services->getContentModelStore(),
                        $services->getSlotRoleStore(),
                        $services->getMainConfig()->get( 'MultiContentRevisionSchemaMigrationStage' ),
-                       $services->getActorMigration()
+                       $services->getActorMigration(),
+                       LoggerFactory::getInstance( 'RevisionStore' ),
+                       $config->get( 'ContentHandlerUseDB' )
                );
 
-               $store->setLogger( LoggerFactory::getInstance( 'RevisionStore' ) );
-
-               $config = $services->getMainConfig();
-               $store->setContentHandlerUseDB( $config->get( 'ContentHandlerUseDB' ) );
-
                return $store;
        },
 
index 7900210..2376d16 100644 (file)
@@ -45,6 +45,7 @@ use User;
 use Wikimedia\Assert\Assert;
 use Wikimedia\Rdbms\DBConnRef;
 use Wikimedia\Rdbms\DBUnexpectedError;
+use Wikimedia\Rdbms\IDatabase;
 use Wikimedia\Rdbms\LoadBalancer;
 use WikiPage;
 
@@ -639,7 +640,7 @@ class PageUpdater {
                // NOTE: This grabs the parent revision as the CAS token, if grabParentRevision
                // wasn't called yet. If the page is modified by another process before we are done with
                // it, this method must fail (with status 'edit-conflict')!
-               // NOTE: The parent revision may be different from $this->baseRevisionId.
+               // NOTE: The parent revision may be different from $this->originalRevisionId.
                $this->grabParentRevision();
                $flags = $this->checkFlags( $flags );
 
@@ -922,7 +923,6 @@ class PageUpdater {
 
                // XXX: we may want a flag that allows a null revision to be forced!
                $changed = $this->derivedDataUpdater->isChange();
-               $mainContent = $newRevisionRecord->getContent( 'main' );
 
                $dbw = $this->getDBConnectionRef( DB_MASTER );
 
@@ -991,22 +991,19 @@ class PageUpdater {
                        $user->incEditCount();
 
                        $dbw->endAtomic( __METHOD__ );
-               } else {
-                       // T34948: revision ID must be set to page {{REVISIONID}} and
-                       // related variables correctly. Likewise for {{REVISIONUSER}} (T135261).
-                       // Since we don't insert a new revision into the database, the least
-                       // error-prone way is to reuse given old revision.
-                       $newRevisionRecord = $oldRev;
-                       $newLegacyRevision = new Revision( $newRevisionRecord );
-               }
 
-               if ( $changed ) {
                        // Return the new revision to the caller
                        $status->value['revision-record'] = $newRevisionRecord;
 
                        // TODO: globally replace usages of 'revision' with getNewRevision()
                        $status->value['revision'] = $newLegacyRevision;
                } else {
+                       // T34948: revision ID must be set to page {{REVISIONID}} and
+                       // related variables correctly. Likewise for {{REVISIONUSER}} (T135261).
+                       // Since we don't insert a new revision into the database, the least
+                       // error-prone way is to reuse given old revision.
+                       $newRevisionRecord = $oldRev;
+
                        $status->warning( 'edit-no-change' );
                        // Update page_touched as updateRevisionOn() was not called.
                        // Other cache updates are managed in WikiPage::onArticleEdit()
@@ -1021,30 +1018,15 @@ class PageUpdater {
                // importantly, before the parser cache has been updated. This would cause the
                // content to be parsed a second time, or may cause stale content to be shown.
                DeferredUpdates::addUpdate(
-                       new AtomicSectionUpdate(
+                       $this->getAtomicSectionUpdate(
                                $dbw,
-                               __METHOD__,
-                               function () use (
-                                       $wikiPage, $newRevisionRecord, $newLegacyRevision, $user, $mainContent,
-                                       $summary, $flags, $changed, $status
-                               ) {
-                                       // Update links tables, site stats, etc.
-                                       $this->derivedDataUpdater->prepareUpdate(
-                                               $newRevisionRecord,
-                                               [
-                                                       'changed' => $changed,
-                                               ]
-                                       );
-                                       $this->derivedDataUpdater->doUpdates();
-
-                                       // Trigger post-save hook
-                                       // TODO: replace legacy hook!
-                                       // TODO: avoid pass-by-reference, see T193950
-                                       $params = [ &$wikiPage, &$user, $mainContent, $summary->text, $flags & EDIT_MINOR,
-                                               null, null, &$flags, $newLegacyRevision, &$status, $this->getOriginalRevisionId(),
-                                               $this->undidRevId ];
-                                       Hooks::run( 'PageContentSaveComplete', $params );
-                               }
+                               $wikiPage,
+                               $newRevisionRecord,
+                               $user,
+                               $summary,
+                               $flags,
+                               $status,
+                               [ 'changed' => $changed, ]
                        ),
                        DeferredUpdates::PRESEND
                );
@@ -1162,47 +1144,65 @@ class PageUpdater {
                $status->value['revision'] = $newLegacyRevision;
                $status->value['revision-record'] = $newRevisionRecord;
 
-               // XXX: make sure we are not loading the Content from the DB
-               $mainContent = $newRevisionRecord->getContent( 'main' );
-
                // Do secondary updates once the main changes have been committed...
                DeferredUpdates::addUpdate(
-                       new AtomicSectionUpdate(
+                       $this->getAtomicSectionUpdate(
                                $dbw,
-                               __METHOD__,
-                               function () use (
-                                       $wikiPage,
-                                       $newRevisionRecord,
-                                       $newLegacyRevision,
-                                       $user,
-                                       $mainContent,
-                                       $summary,
-                                       $flags,
-                                       $status
-                               ) {
-                                       // Update links, etc.
-                                       $this->derivedDataUpdater->prepareUpdate(
-                                               $newRevisionRecord,
-                                               [ 'created' => true ]
-                                       );
-                                       $this->derivedDataUpdater->doUpdates();
+                               $wikiPage,
+                               $newRevisionRecord,
+                               $user,
+                               $summary,
+                               $flags,
+                               $status,
+                               [ 'created' => true ]
+                       ),
+                       DeferredUpdates::PRESEND
+               );
 
+               return $status;
+       }
+
+       private function getAtomicSectionUpdate(
+               IDatabase $dbw,
+               WikiPage $wikiPage,
+               RevisionRecord $newRevisionRecord,
+               User $user,
+               CommentStoreComment $summary,
+               $flags,
+               Status $status,
+               $hints = []
+       ) {
+               return new AtomicSectionUpdate(
+                       $dbw,
+                       __METHOD__,
+                       function () use (
+                               $wikiPage, $newRevisionRecord, $user,
+                               $summary, $flags, $status, $hints
+                       ) {
+                               $newLegacyRevision = new Revision( $newRevisionRecord );
+                               $mainContent = $newRevisionRecord->getContent( 'main', RevisionRecord::RAW );
+
+                               // Update links tables, site stats, etc.
+                               $this->derivedDataUpdater->prepareUpdate( $newRevisionRecord, $hints );
+                               $this->derivedDataUpdater->doUpdates();
+
+                               // TODO: replace legacy hook!
+                               // TODO: avoid pass-by-reference, see T193950
+
+                               if ( $hints['created'] ?? false ) {
                                        // Trigger post-create hook
-                                       // TODO: replace legacy hook!
-                                       // TODO: avoid pass-by-reference, see T193950
                                        $params = [ &$wikiPage, &$user, $mainContent, $summary->text,
                                                $flags & EDIT_MINOR, null, null, &$flags, $newLegacyRevision ];
                                        Hooks::run( 'PageContentInsertComplete', $params );
-                                       // Trigger post-save hook
-                                       // TODO: replace legacy hook!
-                                       $params = array_merge( $params, [ &$status, $this->getOriginalRevisionId(), 0 ] );
-                                       Hooks::run( 'PageContentSaveComplete', $params );
                                }
-                       ),
-                       DeferredUpdates::PRESEND
-               );
 
-               return $status;
+                               // Trigger post-save hook
+                               $params = [ &$wikiPage, &$user, $mainContent, $summary->text,
+                                               $flags & EDIT_MINOR, null, null, &$flags, $newLegacyRevision,
+                                               &$status, $this->getOriginalRevisionId(), $this->undidRevId ];
+                               Hooks::run( 'PageContentSaveComplete', $params );
+                       }
+               );
        }
 
 }
index 6c30d62..12bee1e 100644 (file)
@@ -83,6 +83,7 @@ class RevisionStore
 
        /**
         * @var boolean
+        * @see $wgContentHandlerUseDB
         */
        private $contentHandlerUseDB = true;
 
@@ -182,6 +183,7 @@ class RevisionStore
        }
 
        /**
+        * @see $wgContentHandlerUseDB
         * @param bool $contentHandlerUseDB
         * @throws MWException
         */
diff --git a/includes/Storage/RevisionStoreFactory.php b/includes/Storage/RevisionStoreFactory.php
new file mode 100644 (file)
index 0000000..6f8bd99
--- /dev/null
@@ -0,0 +1,141 @@
+<?php
+
+/**
+ * This program is free software; you can redistribute it and/or modify
+ * it under the terms of the GNU General Public License as published by
+ * the Free Software Foundation; either version 2 of the License, or
+ * (at your option) any later version.
+ *
+ * This program is distributed in the hope that it will be useful,
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+ * GNU General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with this program; if not, write to the Free Software Foundation, Inc.,
+ * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+ * http://www.gnu.org/copyleft/gpl.html
+ *
+ * Attribution notice: when this file was created, much of its content was taken
+ * from the Revision.php file as present in release 1.30. Refer to the history
+ * of that file for original authorship.
+ *
+ * @file
+ */
+
+namespace MediaWiki\Storage;
+
+use ActorMigration;
+use CommentStore;
+use Psr\Log\LoggerInterface;
+use WANObjectCache;
+use Wikimedia\Assert\Assert;
+use Wikimedia\Rdbms\LoadBalancer;
+
+/**
+ * @since 1.32
+ */
+class RevisionStoreFactory {
+
+       /** @var SqlBlobStore */
+       private $blobStore;
+
+       /** @var LoadBalancer */
+       private $loadBalancer;
+
+       /** @var WANObjectCache */
+       private $cache;
+
+       /** @var CommentStore */
+       private $commentStore;
+
+       /** @var ActorMigration */
+       private $actorMigration;
+
+       /** @var NameTableStore */
+       private $contentModelStore;
+
+       /** @var NameTableStore */
+       private $slotRoleStore;
+
+       /** @var int One of the MIGRATION_* constants */
+       private $mcrMigrationStage;
+
+       /**
+        * @var bool
+        * @see $wgContentHandlerUseDB
+        */
+       private $contentHandlerUseDB;
+
+       /** @var LoggerInterface */
+       private $logger;
+
+       /**
+        * @todo $blobStore should be allowed to be any BlobStore!
+        *
+        * @param LoadBalancer $loadBalancer
+        * @param SqlBlobStore $blobStore
+        * @param WANObjectCache $cache
+        * @param CommentStore $commentStore
+        * @param NameTableStore $contentModelStore
+        * @param NameTableStore $slotRoleStore
+        * @param int $migrationStage
+        * @param ActorMigration $actorMigration
+        * @param LoggerInterface $logger
+        * @param bool $contentHandlerUseDB see {@link $wgContentHandlerUseDB}
+        */
+       public function __construct(
+               LoadBalancer $loadBalancer,
+               SqlBlobStore $blobStore,
+               WANObjectCache $cache,
+               CommentStore $commentStore,
+               NameTableStore $contentModelStore,
+               NameTableStore $slotRoleStore,
+               $migrationStage,
+               ActorMigration $actorMigration,
+               LoggerInterface $logger,
+               $contentHandlerUseDB
+       ) {
+               Assert::parameterType( 'integer', $migrationStage, '$migrationStage' );
+
+               $this->loadBalancer = $loadBalancer;
+               $this->blobStore = $blobStore;
+               $this->cache = $cache;
+               $this->commentStore = $commentStore;
+               $this->contentModelStore = $contentModelStore;
+               $this->slotRoleStore = $slotRoleStore;
+               $this->mcrMigrationStage = $migrationStage;
+               $this->actorMigration = $actorMigration;
+               $this->logger = $logger;
+               $this->contentHandlerUseDB = $contentHandlerUseDB;
+       }
+
+       /**
+        * @since 1.32
+        *
+        * @param bool|string $wikiId false for the current domain / wikid
+        *
+        * @return RevisionStore for the given wikiId with all necessary services and a logger
+        */
+       public function getRevisionStore( $wikiId = false ) {
+               Assert::parameterType( 'string|boolean', $wikiId, '$wikiId' );
+
+               $store = new RevisionStore(
+                       $this->loadBalancer,
+                       $this->blobStore,
+                       $this->cache,
+                       $this->commentStore,
+                       $this->contentModelStore,
+                       $this->slotRoleStore,
+                       $this->mcrMigrationStage,
+                       $this->actorMigration,
+                       $wikiId
+               );
+
+               $store->setLogger( $this->logger );
+               $store->setContentHandlerUseDB( $this->contentHandlerUseDB );
+
+               return $store;
+       }
+
+}
index 98aa554..943ee22 100644 (file)
@@ -2675,16 +2675,14 @@ abstract class ApiBase extends ContextSource {
         * @deprecated since 1.25
         */
        public function profileIn() {
-               // No wfDeprecated() yet because extensions call this and might need to
-               // keep doing so for BC.
+               wfDeprecated( __METHOD__, '1.25' );
        }
 
        /**
         * @deprecated since 1.25
         */
        public function profileOut() {
-               // No wfDeprecated() yet because extensions call this and might need to
-               // keep doing so for BC.
+               wfDeprecated( __METHOD__, '1.25' );
        }
 
        /**
index 30a685b..ac7a7b5 100644 (file)
@@ -29,7 +29,7 @@
        "apihelp-main-param-servedby": "在結果中包括提出請求的主機名。",
        "apihelp-main-param-curtimestamp": "在結果中包括目前的時間戳。",
        "apihelp-main-param-responselanginfo": "在結果中包括<var>uselang</var>和<var>errorlang</var>所用的語言。",
-       "apihelp-block-summary": "封鎖用戶。",
+       "apihelp-block-summary": "封鎖使用者。",
        "apihelp-block-param-user": "要封鎖的使用者名稱、IP 位址或 IP 範圍。不能與 <var>$1userid</var> 一起使用",
        "apihelp-block-param-reason": "封鎖原因。",
        "apihelp-block-param-anononly": "僅封鎖匿名使用者 (禁止這個 IP 位址的匿名使用者編輯)。",
@@ -60,7 +60,7 @@
        "apihelp-compare-param-torev": "要比對的第二個修訂。",
        "apihelp-compare-example-1": "建立修訂 1 與 1 的差異檔",
        "apihelp-createaccount-summary": "建立新使用者帳號。",
-       "apihelp-createaccount-param-name": "用戶名。",
+       "apihelp-createaccount-param-name": "使用者名稱。",
        "apihelp-createaccount-param-password": "密碼 (若有設定 <var>$1mailpassword</var> 則可略過)。",
        "apihelp-createaccount-param-domain": "外部身分核對使用的網域 (可有可無)。",
        "apihelp-createaccount-param-token": "在第一次請求時已取得的帳號建立金鑰。",
        "apihelp-import-param-namespace": "匯入至此命名空間。無法與 <var>$1rootpage</var> 一起使用。",
        "apihelp-import-param-rootpage": "匯入作為此頁面的子頁面。無法與 <var>$1namespace</var> 一起使用。",
        "apihelp-login-summary": "登入並取得身分核對 cookies",
-       "apihelp-login-param-name": "用戶名。",
+       "apihelp-login-param-name": "使用者名稱。",
        "apihelp-login-param-password": "密碼。",
        "apihelp-login-param-domain": "網域名稱(可有可無)。",
        "apihelp-login-example-login": "登入",
        "apihelp-unblock-example-id": "解除封銷 ID #<kbd>105</kbd>。",
        "apihelp-undelete-param-reason": "還原的原因。",
        "apihelp-userrights-summary": "變更一位使用者的群組成員。",
-       "apihelp-userrights-param-user": "用戶名。",
-       "apihelp-userrights-param-userid": "用戶ID。",
+       "apihelp-userrights-param-user": "使用者名稱。",
+       "apihelp-userrights-param-userid": "使用者ID。",
        "apihelp-userrights-param-add": "加入使用者至這些群組;若已是成員,則更新失效時間。",
        "apihelp-userrights-param-remove": "從這些群組移除使用者。",
        "apihelp-userrights-param-reason": "變更的原因。",
index 398df01..5c82f09 100644 (file)
@@ -593,13 +593,7 @@ class LinksUpdate extends DataUpdate implements EnqueueableDataUpdate {
                        $nt = Title::makeTitleSafe( NS_CATEGORY, $name );
                        $wgContLang->findVariantLink( $name, $nt, true );
 
-                       if ( $this->mTitle->getNamespace() == NS_CATEGORY ) {
-                               $type = 'subcat';
-                       } elseif ( $this->mTitle->getNamespace() == NS_FILE ) {
-                               $type = 'file';
-                       } else {
-                               $type = 'page';
-                       }
+                       $type = MWNamespace::getCategoryLinkType( $this->mTitle->getNamespace() );
 
                        # Treat custom sortkeys as a prefix, so that if multiple
                        # things are forced to sort as '*' or something, they'll
index 553315f..bca8c05 100644 (file)
@@ -25,27 +25,47 @@ use Wikimedia\Assert\Assert;
 /**
  * Handles a simple LRU key/value map with a maximum number of entries
  *
- * Use ProcessCacheLRU if hierarchical purging is needed or objects can become stale
+ * The last-modification timestamp of entries is internally tracked so that callers can
+ * specify the maximum acceptable age of entries in calls to the has() method. As a convenience,
+ * the hasField(), getField(), and setField() methods can be used for entries that are field/value
+ * maps themselves; such fields will have their own internally tracked last-modification timestamp.
  *
  * @see ProcessCacheLRU
  * @ingroup Cache
  * @since 1.23
  */
-class MapCacheLRU {
-       /** @var array */
-       protected $cache = []; // (key => value)
+class MapCacheLRU implements IExpiringStore, Serializable {
+       /** @var array Map of (key => value) */
+       private $cache = [];
+       /** @var array Map of (key => (UNIX timestamp, (field => UNIX timestamp))) */
+       private $timestamps = [];
+       /** @var float Default entry timestamp if not specified */
+       private $epoch;
 
-       protected $maxCacheKeys; // integer; max entries
+       /** @var int Max number of entries */
+       private $maxCacheKeys;
+
+       /** @var float|null */
+       private $wallClockOverride;
+
+       const RANK_TOP = 1.0;
+
+       /** @var int Array key that holds the entry's main timestamp (flat key use) */
+       const SIMPLE = 0;
+       /** @var int Array key that holds the entry's field timestamps (nested key use) */
+       const FIELDS = 1;
 
        /**
-        * @param int $maxKeys Maximum number of entries allowed (min 1).
-        * @throws Exception When $maxCacheKeys is not an int or not above zero.
+        * @param int $maxKeys Maximum number of entries allowed (min 1)
+        * @throws Exception When $maxKeys is not an int or not above zero
         */
        public function __construct( $maxKeys ) {
                Assert::parameterType( 'integer', $maxKeys, '$maxKeys' );
                Assert::parameter( $maxKeys > 0, '$maxKeys', 'must be above zero' );
 
                $this->maxCacheKeys = $maxKeys;
+               // Use the current time as the default "as of" timesamp of entries
+               $this->epoch = $this->getCurrentTime();
        }
 
        /**
@@ -86,13 +106,14 @@ class MapCacheLRU {
         * @param float $rank Bottom fraction of the list where keys start off [Default: 1.0]
         * @return void
         */
-       public function set( $key, $value, $rank = 1.0 ) {
+       public function set( $key, $value, $rank = self::RANK_TOP ) {
                if ( $this->has( $key ) ) {
                        $this->ping( $key );
                } elseif ( count( $this->cache ) >= $this->maxCacheKeys ) {
                        reset( $this->cache );
                        $evictKey = key( $this->cache );
                        unset( $this->cache[$evictKey] );
+                       unset( $this->timestamps[$evictKey] );
                }
 
                if ( $rank < 1.0 && $rank > 0 ) {
@@ -103,20 +124,31 @@ class MapCacheLRU {
                } else {
                        $this->cache[$key] = $value;
                }
+
+               $this->timestamps[$key] = [
+                       self::SIMPLE => $this->getCurrentTime(),
+                       self::FIELDS => []
+               ];
        }
 
        /**
         * Check if a key exists
         *
         * @param string $key
+        * @param float $maxAge Ignore items older than this many seconds (since 1.32)
         * @return bool
         */
-       public function has( $key ) {
+       public function has( $key, $maxAge = 0.0 ) {
                if ( !is_int( $key ) && !is_string( $key ) ) {
                        throw new UnexpectedValueException(
                                __METHOD__ . ' called with invalid key. Must be string or integer.' );
                }
-               return array_key_exists( $key, $this->cache );
+
+               if ( !array_key_exists( $key, $this->cache ) ) {
+                       return false;
+               }
+
+               return ( $maxAge <= 0 || $this->getAge( $key ) <= $maxAge );
        }
 
        /**
@@ -137,6 +169,46 @@ class MapCacheLRU {
                return $this->cache[$key];
        }
 
+       /**
+        * @param string|int $key
+        * @param string|int $field
+        * @param mixed $value
+        * @param float $initRank
+        */
+       public function setField( $key, $field, $value, $initRank = self::RANK_TOP ) {
+               if ( $this->has( $key ) ) {
+                       $this->ping( $key );
+               } else {
+                       $this->set( $key, [], $initRank );
+               }
+
+               if ( !is_array( $this->cache[$key] ) ) {
+                       throw new UnexpectedValueException( "The value of '$key' is not an array." );
+               }
+
+               $this->cache[$key][$field] = $value;
+               $this->timestamps[$key][self::FIELDS][$field] = $this->getCurrentTime();
+       }
+
+       /**
+        * @param string|int $key
+        * @param string|int $field
+        * @param float $maxAge
+        * @return bool
+        */
+       public function hasField( $key, $field, $maxAge = 0.0 ) {
+               $value = $this->get( $key );
+               if ( !is_array( $value ) || !array_key_exists( $field, $value ) ) {
+                       return false;
+               }
+
+               return ( $maxAge <= 0 || $this->getAge( $key, $field ) <= $maxAge );
+       }
+
+       public function getField( $key, $field ) {
+               return $this->get( $key )[$field] ?? null;
+       }
+
        /**
         * @return array
         * @since 1.25
@@ -154,10 +226,13 @@ class MapCacheLRU {
         * @param string $key
         * @param callable $callback Callback that will produce the value
         * @param float $rank Bottom fraction of the list where keys start off [Default: 1.0]
+        * @param float $maxAge Ignore items older than this many seconds [Default: 0.0] (since 1.32)
         * @return mixed The cached value if found or the result of $callback otherwise
         */
-       public function getWithSetCallback( $key, callable $callback, $rank = 1.0 ) {
-               if ( $this->has( $key ) ) {
+       public function getWithSetCallback(
+               $key, callable $callback, $rank = self::RANK_TOP, $maxAge = 0.0
+       ) {
+               if ( $this->has( $key, $maxAge ) ) {
                        $value = $this->get( $key );
                } else {
                        $value = call_user_func( $callback );
@@ -178,21 +253,99 @@ class MapCacheLRU {
        public function clear( $keys = null ) {
                if ( $keys === null ) {
                        $this->cache = [];
+                       $this->timestamps = [];
                } else {
                        foreach ( (array)$keys as $key ) {
                                unset( $this->cache[$key] );
+                               unset( $this->timestamps[$key] );
                        }
                }
        }
 
+       /**
+        * Get the maximum number of keys allowed
+        *
+        * @return int
+        * @since 1.32
+        */
+       public function getMaxSize() {
+               return $this->maxCacheKeys;
+       }
+
+       /**
+        * Resize the maximum number of cache entries, removing older entries as needed
+        *
+        * @param int $maxKeys Maximum number of entries allowed (min 1)
+        * @return void
+        * @throws Exception When $maxKeys is not an int or not above zero
+        * @since 1.32
+        */
+       public function setMaxSize( $maxKeys ) {
+               Assert::parameterType( 'integer', $maxKeys, '$maxKeys' );
+               Assert::parameter( $maxKeys > 0, '$maxKeys', 'must be above zero' );
+
+               $this->maxCacheKeys = $maxKeys;
+               while ( count( $this->cache ) > $this->maxCacheKeys ) {
+                       reset( $this->cache );
+                       $evictKey = key( $this->cache );
+                       unset( $this->cache[$evictKey] );
+                       unset( $this->timestamps[$evictKey] );
+               }
+       }
+
        /**
         * Push an entry to the top of the cache
         *
         * @param string $key
         */
-       protected function ping( $key ) {
+       private function ping( $key ) {
                $item = $this->cache[$key];
                unset( $this->cache[$key] );
                $this->cache[$key] = $item;
        }
+
+       /**
+        * @param string|int $key
+        * @param string|int|null $field [optional]
+        * @return float UNIX timestamp; the age of the given entry or entry field
+        */
+       private function getAge( $key, $field = null ) {
+               if ( $field !== null ) {
+                       $mtime = $this->timestamps[$key][self::FIELDS][$field] ?? $this->epoch;
+               } else {
+                       $mtime = $this->timestamps[$key][self::SIMPLE] ?? $this->epoch;
+               }
+
+               return ( $this->getCurrentTime() - $mtime );
+       }
+
+       public function serialize() {
+               return serialize( [
+                       'entries' => $this->cache,
+                       'timestamps' => $this->timestamps
+               ] );
+       }
+
+       public function unserialize( $serialized ) {
+               $data = unserialize( $serialized );
+               $this->cache = $data['entries'] ?? [];
+               $this->timestamps = $data['timestamps'] ?? [];
+               $this->epoch = $this->getCurrentTime();
+       }
+
+       /**
+        * @return float UNIX timestamp
+        * @codeCoverageIgnore
+        */
+       protected function getCurrentTime() {
+               return $this->wallClockOverride ?: microtime( true );
+       }
+
+       /**
+        * @param float|null &$time Mock UNIX timestamp for testing
+        * @codeCoverageIgnore
+        */
+       public function setMockTime( &$time ) {
+               $this->wallClockOverride =& $time;
+       }
 }
index b374259..eb32d98 100644 (file)
@@ -20,7 +20,6 @@
  * @file
  * @ingroup Cache
  */
-use Wikimedia\Assert\Assert;
 
 /**
  * Class for process caching individual properties of expiring items
@@ -28,22 +27,18 @@ use Wikimedia\Assert\Assert;
  * When the key for an entire item is deleted, all properties for it are deleted
  *
  * @ingroup Cache
+ * @deprecated Since 1.32 Use MapCacheLRU instead
  */
 class ProcessCacheLRU {
-       /** @var array */
-       protected $cache = []; // (key => prop => value)
-
-       /** @var array */
-       protected $cacheTimes = []; // (key => prop => UNIX timestamp)
-
-       protected $maxCacheKeys; // integer; max entries
+       /** @var MapCacheLRU */
+       protected $cache;
 
        /**
         * @param int $maxKeys Maximum number of entries allowed (min 1).
         * @throws UnexpectedValueException When $maxCacheKeys is not an int or =< 0.
         */
        public function __construct( $maxKeys ) {
-               $this->resize( $maxKeys );
+               $this->cache = new MapCacheLRU( $maxKeys );
        }
 
        /**
@@ -57,16 +52,7 @@ class ProcessCacheLRU {
         * @return void
         */
        public function set( $key, $prop, $value ) {
-               if ( isset( $this->cache[$key] ) ) {
-                       $this->ping( $key );
-               } elseif ( count( $this->cache ) >= $this->maxCacheKeys ) {
-                       reset( $this->cache );
-                       $evictKey = key( $this->cache );
-                       unset( $this->cache[$evictKey] );
-                       unset( $this->cacheTimes[$evictKey] );
-               }
-               $this->cache[$key][$prop] = $value;
-               $this->cacheTimes[$key][$prop] = microtime( true );
+               $this->cache->setField( $key, $prop, $value );
        }
 
        /**
@@ -78,13 +64,7 @@ class ProcessCacheLRU {
         * @return bool
         */
        public function has( $key, $prop, $maxAge = 0.0 ) {
-               if ( isset( $this->cache[$key][$prop] ) ) {
-                       return ( $maxAge <= 0 ||
-                               ( microtime( true ) - $this->cacheTimes[$key][$prop] ) <= $maxAge
-                       );
-               }
-
-               return false;
+               return $this->cache->hasField( $key, $prop, $maxAge );
        }
 
        /**
@@ -97,11 +77,7 @@ class ProcessCacheLRU {
         * @return mixed
         */
        public function get( $key, $prop ) {
-               if ( !isset( $this->cache[$key][$prop] ) ) {
-                       return null;
-               }
-               $this->ping( $key );
-               return $this->cache[$key][$prop];
+               return $this->cache->getField( $key, $prop );
        }
 
        /**
@@ -111,15 +87,7 @@ class ProcessCacheLRU {
         * @return void
         */
        public function clear( $keys = null ) {
-               if ( $keys === null ) {
-                       $this->cache = [];
-                       $this->cacheTimes = [];
-               } else {
-                       foreach ( (array)$keys as $key ) {
-                               unset( $this->cache[$key] );
-                               unset( $this->cacheTimes[$key] );
-                       }
-               }
+               $this->cache->clear( $keys );
        }
 
        /**
@@ -130,27 +98,7 @@ class ProcessCacheLRU {
         * @throws UnexpectedValueException
         */
        public function resize( $maxKeys ) {
-               Assert::parameterType( 'integer', $maxKeys, '$maxKeys' );
-               Assert::parameter( $maxKeys > 0, '$maxKeys', 'must be above zero' );
-
-               $this->maxCacheKeys = $maxKeys;
-               while ( count( $this->cache ) > $this->maxCacheKeys ) {
-                       reset( $this->cache );
-                       $evictKey = key( $this->cache );
-                       unset( $this->cache[$evictKey] );
-                       unset( $this->cacheTimes[$evictKey] );
-               }
-       }
-
-       /**
-        * Push an entry to the top of the cache
-        *
-        * @param string $key
-        */
-       protected function ping( $key ) {
-               $item = $this->cache[$key];
-               unset( $this->cache[$key] );
-               $this->cache[$key] = $item;
+               $this->cache->setMaxSize( $maxKeys );
        }
 
        /**
@@ -158,6 +106,6 @@ class ProcessCacheLRU {
         * @return int
         */
        public function getSize() {
-               return $this->maxCacheKeys;
+               return $this->cache->getMaxSize();
        }
 }
index edd5fbc..fd45024 100644 (file)
@@ -34,9 +34,8 @@ class MultiWriteBagOStuff extends BagOStuff {
        protected $caches;
        /** @var bool Use async secondary writes */
        protected $asyncWrites = false;
-
-       /** Idiom for "write to all backends" */
-       const ALL = INF;
+       /** @var int[] List of all backing cache indexes */
+       protected $cacheIndexes = [];
 
        const UPGRADE_TTL = 3600; // TTL when a key is copied to a higher cache tier
 
@@ -91,6 +90,8 @@ class MultiWriteBagOStuff extends BagOStuff {
                        $params['replication'] === 'async' &&
                        is_callable( $this->asyncHandler )
                );
+
+               $this->cacheIndexes = array_keys( $this->caches );
        }
 
        public function setDebug( $debug ) {
@@ -107,21 +108,24 @@ class MultiWriteBagOStuff extends BagOStuff {
                        return $this->caches[0]->get( $key, $flags );
                }
 
-               $misses = 0; // number backends checked
                $value = false;
-               foreach ( $this->caches as $cache ) {
+               $missIndexes = []; // backends checked
+               foreach ( $this->caches as $i => $cache ) {
                        $value = $cache->get( $key, $flags );
                        if ( $value !== false ) {
                                break;
                        }
-                       ++$misses;
+                       $missIndexes[] = $i;
                }
 
                if ( $value !== false
-                       && $misses > 0
+                       && $missIndexes
                        && ( $flags & self::READ_VERIFIED ) == self::READ_VERIFIED
                ) {
-                       $this->doWrite( $misses, $this->asyncWrites, 'set', $key, $value, self::UPGRADE_TTL );
+                       // Backfill the value to the lower (and often larger) cache tiers
+                       $this->doWrite(
+                               $missIndexes, $this->asyncWrites, 'set', $key, $value, self::UPGRADE_TTL
+                       );
                }
 
                return $value;
@@ -132,23 +136,39 @@ class MultiWriteBagOStuff extends BagOStuff {
                        ? false
                        : $this->asyncWrites;
 
-               return $this->doWrite( self::ALL, $asyncWrites, 'set', $key, $value, $exptime );
+               return $this->doWrite( $this->cacheIndexes, $asyncWrites, 'set', $key, $value, $exptime );
        }
 
        public function delete( $key ) {
-               return $this->doWrite( self::ALL, $this->asyncWrites, 'delete', $key );
+               return $this->doWrite( $this->cacheIndexes, $this->asyncWrites, 'delete', $key );
        }
 
        public function add( $key, $value, $exptime = 0 ) {
-               return $this->doWrite( self::ALL, $this->asyncWrites, 'add', $key, $value, $exptime );
+               // Try the write to the top-tier cache
+               $ok = $this->doWrite( [ 0 ], $this->asyncWrites, 'add', $key, $value, $exptime );
+               if ( $ok ) {
+                       // Relay the add() using set() if it succeeded. This is meant to handle certain
+                       // migration scenarios where the same store might get written to twice for certain
+                       // keys. In that case, it does not make sense to return false due to "self-conflicts".
+                       return $this->doWrite(
+                               array_slice( $this->cacheIndexes, 1 ),
+                               $this->asyncWrites,
+                               'set',
+                               $key,
+                               $value,
+                               $exptime
+                       );
+               }
+
+               return false;
        }
 
        public function incr( $key, $value = 1 ) {
-               return $this->doWrite( self::ALL, $this->asyncWrites, 'incr', $key, $value );
+               return $this->doWrite( $this->cacheIndexes, $this->asyncWrites, 'incr', $key, $value );
        }
 
        public function decr( $key, $value = 1 ) {
-               return $this->doWrite( self::ALL, $this->asyncWrites, 'decr', $key, $value );
+               return $this->doWrite( $this->cacheIndexes, $this->asyncWrites, 'decr', $key, $value );
        }
 
        public function lock( $key, $timeout = 6, $expiry = 6, $rclass = '' ) {
@@ -170,29 +190,26 @@ class MultiWriteBagOStuff extends BagOStuff {
        }
 
        /**
-        * Apply a write method to the first $count backing caches
+        * Apply a write method to the backing caches specified by $indexes (in order)
         *
-        * @param int $count
+        * @param int[] $indexes List of backing cache indexes
         * @param bool $asyncWrites
         * @param string $method
         * @param mixed $args,...
         * @return bool
         */
-       protected function doWrite( $count, $asyncWrites, $method /*, ... */ ) {
+       protected function doWrite( $indexes, $asyncWrites, $method /*, ... */ ) {
                $ret = true;
                $args = array_slice( func_get_args(), 3 );
 
-               if ( $count > 1 && $asyncWrites ) {
+               if ( count( $indexes ) > 1 && $asyncWrites ) {
                        // Deep-clone $args to prevent misbehavior when something writes an
                        // object to the BagOStuff then modifies it afterwards, e.g. T168040.
                        $args = unserialize( serialize( $args ) );
                }
 
-               foreach ( $this->caches as $i => $cache ) {
-                       if ( $i >= $count ) {
-                               break; // ignore the lower tiers
-                       }
-
+               foreach ( $indexes as $i ) {
+                       $cache = $this->caches[$i];
                        if ( $i == 0 || !$asyncWrites ) {
                                // First store or in sync mode: write now and get result
                                if ( !$cache->$method( ...$args ) ) {
index 911a8cc..7b8ffef 100644 (file)
@@ -177,7 +177,7 @@ class LogEventsList extends ContextSource {
                        $query = $this->getDefaultQuery();
                        $queryKey = "hide_{$type}_log";
 
-                       $hideVal = 1 - intval( $val );
+                       $hideVal = $val ? 0 : 1;
                        $query[$queryKey] = $hideVal;
 
                        $link = $linkRenderer->makeKnownLink(
index 84653b1..6b177ae 100644 (file)
@@ -105,7 +105,7 @@ class LogPager extends ReverseChronologicalPager {
                        return $filters;
                }
                foreach ( $wgFilterLogTypes as $type => $default ) {
-                       $hide = $this->getRequest()->getInt( "hide_{$type}_log", $default );
+                       $hide = $this->getRequest()->getBool( "hide_{$type}_log", $default );
 
                        $filters[$type] = $hide;
                        if ( $hide ) {
index b970820..ad3c8c5 100644 (file)
@@ -2527,17 +2527,9 @@ class WikiPage implements Page, IDBAccessObject {
                // Note array_intersect() preserves keys from the first arg, and we're
                // assuming $revQuery has `revision` primary and isn't using subtables
                // for anything we care about.
-               $tablesFlat = [];
-               array_walk_recursive(
-                       $revQuery['tables'],
-                       function ( $a ) use ( &$tablesFlat ) {
-                               $tablesFlat[] = $a;
-                       }
-               );
-
                $res = $dbw->select(
                        array_intersect(
-                               $tablesFlat,
+                               $revQuery['tables'],
                                [ 'revision', 'revision_comment_temp', 'revision_actor_temp' ]
                        ),
                        '1',
@@ -2970,6 +2962,13 @@ class WikiPage implements Page, IDBAccessObject {
                $updater->setUndidRevisionId( $current->getId() );
                $updater->addTags( $tags );
 
+               // TODO: this logic should not be in the storage layer, it's here for compatibility
+               // with 1.31 behavior. Applying the 'autopatrol' right should be done in the same
+               // place the 'bot' right is handled, which is currently in EditPage::attemptSave.
+               if ( $wgUseRCPatrol && $this->getTitle()->userCan( 'autopatrol', $guser ) ) {
+                       $updater->setRcPatrolStatus( RecentChange::PRC_AUTOPATROLLED );
+               }
+
                // Actually store the rollback
                $rev = $updater->saveRevision(
                        CommentStoreComment::newUnsavedComment( $summary ),
@@ -3259,16 +3258,13 @@ class WikiPage implements Page, IDBAccessObject {
         */
        public function updateCategoryCounts( array $added, array $deleted, $id = 0 ) {
                $id = $id ?: $this->getId();
-               $ns = $this->getTitle()->getNamespace();
+               $type = MWNamespace::getCategoryLinkType( $this->getTitle()->getNamespace() );
 
                $addFields = [ 'cat_pages = cat_pages + 1' ];
                $removeFields = [ 'cat_pages = cat_pages - 1' ];
-               if ( $ns == NS_CATEGORY ) {
-                       $addFields[] = 'cat_subcats = cat_subcats + 1';
-                       $removeFields[] = 'cat_subcats = cat_subcats - 1';
-               } elseif ( $ns == NS_FILE ) {
-                       $addFields[] = 'cat_files = cat_files + 1';
-                       $removeFields[] = 'cat_files = cat_files - 1';
+               if ( $type !== 'page' ) {
+                       $addFields[] = "cat_{$type}s = cat_{$type}s + 1";
+                       $removeFields[] = "cat_{$type}s = cat_{$type}s - 1";
                }
 
                $dbw = wfGetDB( DB_MASTER );
@@ -3300,8 +3296,8 @@ class WikiPage implements Page, IDBAccessObject {
                                        $insertRows[] = [
                                                'cat_title'   => $cat,
                                                'cat_pages'   => 1,
-                                               'cat_subcats' => ( $ns == NS_CATEGORY ) ? 1 : 0,
-                                               'cat_files'   => ( $ns == NS_FILE ) ? 1 : 0,
+                                               'cat_subcats' => ( $type === 'subcat' ) ? 1 : 0,
+                                               'cat_files'   => ( $type === 'file' ) ? 1 : 0,
                                        ];
                                }
                                $dbw->upsert(
index 97ff012..277bd02 100644 (file)
@@ -297,6 +297,7 @@ class Names {
                'mk' => 'македонски', # Macedonian
                'ml' => 'മലയാളം', # Malayalam
                'mn' => 'монгол', # Halh Mongolian (Cyrillic) (ISO 639-3: khk)
+               'mni' => 'মেইতেই লোন্', # Manipuri/Meitei
                'mo' => 'молдовеняскэ', # Moldovan, deprecated
                'mr' => 'मराठी', # Marathi
                'mrj' => 'кырык мары', # Hill Mari
index 44f4040..2277444 100644 (file)
        "thu": "Чц",
        "fri": "Пт",
        "sat": "Сб",
-       "january": "cтудзень",
+       "january": "студзень",
        "february": "люты",
        "march": "сакавік",
        "april": "красавік",
index 0f2f3fc..fa5dac2 100644 (file)
        "special-characters-group-greek": "Грекийн",
        "special-characters-group-greekextended": "Грекийн алсам",
        "special-characters-group-cyrillic": "Кирилан",
-       "special-characters-group-arabic": "Ӏарбийн",
+       "special-characters-group-arabic": "Ó\80аÑ\8cÑ\80бийн",
        "special-characters-group-arabicextended": "Ӏаьрбийн алсам",
        "special-characters-group-persian": "Пхьарсхойн",
        "special-characters-group-hebrew": "Жуьгтийн",
index ef417f5..061f7bc 100644 (file)
        "rcfilters-advancedfilters": "پاڵوێنە پێشکەوتووەکان",
        "rcfilters-limit-title": "ئەنجام بۆ نیشاندان",
        "rcfilters-limit-and-date-label": "$1 گۆڕانکاری، $2",
+       "rcfilters-date-popup-title": "ماوە بۆ گەڕان",
+       "rcfilters-days-title": "ڕۆژ",
+       "rcfilters-hours-title": "کاتژمێر",
        "rcfilters-days-show-days": "$1 {{PLURAL:$1|ڕۆژ}}",
        "rcfilters-quickfilters": "پاڵوێنە پاشەکەوتکراوەکان",
        "rcfilters-quickfilters-placeholder-title": "ھیچ پاڵوێنەیەک پاشەکەوت نەکراوە",
        "special-characters-group-gujarati": "گوجەراتی",
        "special-characters-group-thai": "تایلەندی",
        "special-characters-group-khmer": "خمێری",
+       "mw-widgets-dateinput-no-date": "ڕێکەوت ھەڵنەبژێردراوە",
        "mw-widgets-usersmultiselect-placeholder": "زیادکردن...",
+       "date-range-from": "لە ڕێکەوتی:",
+       "date-range-to": "بۆ ڕێکەوتی:",
        "log-action-filter-block": "جۆری بلۆک:",
        "log-action-filter-contentmodel": "جۆری گۆڕینی مۆدێلی ناوەڕۆک:",
        "log-action-filter-all": "ھەموو",
index c93d35d..88d39dd 100644 (file)
        "grant-createaccount": "Kontuak sortu",
        "grant-createeditmovepage": "Orrialdeak sortu, aldatu eta mugitu",
        "grant-delete": "Ezabatu orriak, berrikuspenak eta sarrerak",
-       "grant-editinterface": "MediaWiki izen eremua eta CSS/JavaScript erabiltzailea aldatu",
+       "grant-editinterface": "MediaWiki izen eremua eta CSS/JSON/JavaScript erabiltzailea aldatu",
        "grant-editmycssjs": "Zure CSS/JSON/JavaScript erabiltzailea aldatu",
        "grant-editmyoptions": "Aldatu zure hobespenak",
        "grant-editmywatchlist": "Zure jarraipen zerrenda aldatu",
        "apisandbox-dynamic-parameters-add-label": "Gehitu parametroa:",
        "apisandbox-dynamic-parameters-add-placeholder": "Parametroaren izena",
        "apisandbox-dynamic-error-exists": "$1 parametro izena dagoeneko existitzen da",
+       "apisandbox-templated-parameter-reason": "[[Special:ApiHelp/main#main/templatedparams|templated parameter]] Hau $2-(a)ren {{PLURAL:$1|balio $1-ean|$1 baliotan}} oinarrituta dago eskainita.",
        "apisandbox-deprecated-parameters": "Aurretiaz zehaztutako parametroak",
        "apisandbox-fetch-token": "Token-a automatikoki bete",
        "apisandbox-add-multi": "Gehitu",
        "deletionlog": "ezabaketa erregistroa",
        "log-name-create": "Orri sorkuntzaren erregistroa",
        "log-description-create": "Azpian, sortutako azken orrien zerrenda ageri da.",
+       "logentry-create-create": "$1 {{GENDER:$2|erabiltzaileak}} $3 orria sortu du",
        "reverted": "Lehenagoko berrikuspen batera itzuli da",
        "deletecomment": "Arrazoia:",
        "deleteotherreason": "Arrazoi gehigarria:",
        "rollback-success": "{{GENDER:$3|$1}}; wikilariaren aldaketak deseginda,\nedukia {{GENDER:$4|$2}} wikilariaren azken bertsiora itzuli da.",
        "rollback-success-notify": "$1k leheneratutako aldaketal;\nazkenengo berrikusketara aldatu da berriz $2ren eskutik. [$3 Erakutsi aldaketak]",
        "sessionfailure-title": "Saio-akatsa",
-       "sessionfailure": "Badirudi saioarekin arazoren bat dagoela; bandalismoak saihesteko ekintza hau ezeztatu egin da. Mesedez, nabigatzaileko \"atzera\" botoian klik egin, hona ekarri zaituen orrialde hori berriz kargatu, eta saiatu berriz.",
+       "sessionfailure": "Badirudi saioarekin arazoren bat dagoela; ekintza hau ezeztatua izan da, saio bahiketa saihesteko neurri bezala. Mesedez, nabigatzaileko \"atzera\" botoian klik egin, hona ekarri zaituen orrialde hori berriz kargatu, eta saiatu berriz.",
        "changecontentmodel": "Aldatu orri bateko eduki eredua",
        "changecontentmodel-legend": "Aldatu eduki eredua",
        "changecontentmodel-title-label": "Orriaren izenburua",
        "fix-double-redirects": "Eguneratu jatorrizko izenburura zuzendutako birbideratze guztiak",
        "move-leave-redirect": "Utzi atzean birbideratzea",
        "protectedpagemovewarning": "'''Oharra:''' Orrialde hau babestua izan da, beraz administratzaile eskumenak dituztenek alda dezakete bakarrik.\nAzken erregistroko sarrera ematen da azpian erreferentzia gisa:",
-       "semiprotectedpagemovewarning": "'''Oharra:''' Orrialde hau blokeatu dute, izena emanda duten erabiltzaileek soilik mugitu ahal dezaten. Erregistroko azken sarrera erakusten da jarraian erreferentzia gisa:",
+       "semiprotectedpagemovewarning": "<strong>Oharra:</strong> Orrialde hau blokeatu dute, izena emanda duten erabiltzaileek soilik mugitu ahal dezaten. Erregistroko azken sarrera jarraian erakusten da erreferentzia gisa:",
        "move-over-sharedrepo": "[[:$1]] datu-base partekatu batean existitzen da. Izenburu honetara fitxategi bat mugitzean partekatutako fitxategia gainezarriko du.",
        "file-exists-sharedrepo": "Aukeratutako artxibo izena jadanik partekatutako biltegi batean erabiltzen ari da. Aukeratu beste izen bat mesedez.",
        "export": "Orrialdeak esportatu",
        "thumbnail_dest_directory": "Ezinezkoa izan da helburu direktorioa sortu",
        "thumbnail_image-type": "Irudi mota ez babestua",
        "thumbnail_gd-library": "GD liburutegiaren konfigurazio osagabea: $1 funtzioa falta da",
+       "thumbnail_image-size-zero": "Irudi fitxategiaren tamaina zero dela dirudi.",
        "thumbnail_image-missing": "Fitxategirik ez dagoela dirudi: $1",
        "thumbnail_image-failure-limit": "Koadro txikiak sortzeko saiakera galduak ($1 edo gehiago) gehiegi izan dira. Saiatu berriz geroago mesedez.",
        "import": "Orrialdeak inportatu",
        "tooltip-preferences-save": "Hobespenak gorde",
        "tooltip-summary": "Laburpen labur bat sar ezazu",
        "common.css": "/** Hemen idatzitako CSS kodeak itxura guztietan izango du eragina */",
+       "common.json": "/* Hemen idatzitako JSON oro erabiltzaile guztiek edozein orrialde irekitzerakoan kargatuko da. */",
        "common.js": "/* Hemen idatzitako JavaScript kode oro erabiltzaile guztiek edozein orrialde irekitzerakoan kargatuko da. */",
        "anonymous": "{{SITENAME}}(e)ko lankide {{PLURAL:$1|anonimoa|anonimoak}}",
        "siteuser": "{{SITENAME}}(e)ko $1 erabiltzailea",
        "watchlistedit-clear-titles": "Izenburuak:",
        "watchlistedit-clear-submit": "Garbitu jarraipen zerrenda (Behin betiko da!)",
        "watchlistedit-clear-done": "Zure jarraipen-zerrenda garbitu da.",
+       "watchlistedit-clear-jobqueue": "Jarraipen zerrenda garbitzen ari da. Prozesu honen denbora apur bat luza daiteke!",
        "watchlistedit-clear-removed": "{{PLURAL:$1|Izenburu 1 kendu da|$1 izenburu kendu dira}}:",
        "watchlistedit-too-many": " Orrialde gehiegi, hemen erakusteko.",
        "watchlisttools-clear": "Garbitu jarraipen-zerrenda",
        "limitreport-expansiondepth": "Gehienezko espantsio sakonera",
        "limitreport-expensivefunctioncount": "Parser funtzio kontaketa garestia",
        "limitreport-unstrip-depth": "Unstrip errekurtsio sakona",
+       "limitreport-unstrip-size-value": "{{PLURAL:$2|byte $1/$2|$1/$2 byte}}",
        "expandtemplates": "Txantiloi ordezkatzailea",
        "expand_templates_intro": "Orri berezi honek wiki-testua hartu eta txantiloi guztiak modu errekurtsiboan zabaltzen ditu.\nOnartutako funtzio sintaktikoak ere ordezkatzen ditu, hala nola\n<code><nowiki>{{</nowiki>#language:…}}</code>; eta aldagaiak ere, hala nola\n<code><nowiki>{{</nowiki>CURRENTDAY}}</code>.\nIzan ere, kortxete bikoitzen arteko ia edozer zabaltzen du.",
        "expand_templates_title": "Izenburua ({{FULLPAGENAME}} ordezkatzeko, eta abar):",
        "unlinkaccounts-success": "Kontua desestekatu da.",
        "authenticationdatachange-ignored": "Autentifikazio datuen aldaketa ez da kudeatu. Beharbada ez da hornitzailerik konfiguratu?",
        "userjsispublic": "Kontutan izan mesedez: JavaScript azpiorriek ez lukete datu konfidentzialik eraman behar, beste erabiltzaileek ikusi ahal dituztelako.",
+       "userjsonispublic": "Gogoratu: JSON azpiorriek ez dute datu konfidentzialik eduki behar, beste erabiltzaile batzuek ikus ditzaketelako.",
        "usercssispublic": "Kontutan izan mesedez: CSS azpiorriek ez lukete datu konfidentzialik eraman behar, beste erabiltzaileek ikusi ahal dituztelako.",
        "restrictionsfield-badip": "Baliogabeko IP helbide edo eremua: $1",
        "restrictionsfield-label": "Onartutako IP eremuak:",
        "passwordpolicies-policy-minimalpasswordlength": "Pasahitzak gutxienez {{PLURAL:$1|kraktere $1eko|$1 karaktereko}} luzera izan behar du",
        "passwordpolicies-policy-minimumpasswordlengthtologin": "Pasahitzak gutxienez {{PLURAL:$1|kraktere $1eko|$1 karaktereko}} luzera izan behar du saioa hasi ahal izateko",
        "passwordpolicies-policy-passwordcannotmatchusername": "Pasahitza ezin da erabiltzaile izenaren berdina izan",
-       "passwordpolicies-policy-passwordcannotmatchblacklist": "Pasahitza ezin da zerrenda beltzean zehaztutakoren bat izan"
+       "passwordpolicies-policy-passwordcannotmatchblacklist": "Pasahitza ezin da zerrenda beltzean zehaztutakoren bat izan",
+       "passwordpolicies-policy-maximalpasswordlength": "Pasahitza ezin da {{PLURAL:$1|karaktere $1|$1 karaktere}} baino luzeagoa izan",
+       "passwordpolicies-policy-passwordcannotbepopular": "Pasahitza ezin da {{PLURAL:$1|pasahitz erabiliena izan|$1 pasahitz erabilienen zerrendan egon}}"
 }
index 7f27e4a..b095455 100644 (file)
        "rcfilters-days-show-hours": "$1 {{PLURAL:$1|horo|hori}}",
        "rcfilters-quickfilters": "Konservita filtrili",
        "rcfilters-quickfilters-placeholder-title": "Nula filtrilo konservesis til nun",
+       "rcfilters-quickfilters-placeholder-description": "Por konservar vua ajusto di filtrili ed uzar li pose, kliktez en la marko-rubando ikono en la buxo adinfre, ube l'agiva filtrili montresas.",
        "rcfilters-savedqueries-defaultlabel": "Konservita filtrili",
+       "rcfilters-clear-all-filters": "Efacar omna filtrili",
        "rcfilters-show-new-changes": "Videz la maxim recenta chanji",
        "rcfilters-search-placeholder": "Filtrar la modifikuri (uzez la menuo o serchez segun la nomo dil filtrilo)",
        "rcfilters-filterlist-feedbacklink": "Dicez a ni quon vu pensas pri la filtrili",
        "protectexpiry": "Expiras:",
        "protect_expiry_invalid": "Expirotempo es ne-valida.",
        "protect_expiry_old": "Expirotempo es in pasinta.",
+       "protect-cascadeon": "Ica pagino esas nune protektita, pro ke existas kopio de ol en {{PLURAL:$1|pagino qua|pagini qui}} protektesas \"seriale\" (cascade protection).\nModifiki en la nivelo di protektado por ica pagino ne modifikos la \"protekto seriala\".",
        "protect-default": "Permisar omna uzanti",
        "protect-fallback": "Permisez nur uzeri kun permiso \"$1\"",
        "protect-level-autoconfirmed": "Permisar nur uzeri automatale konfirmata",
index 0d59119..a40f475 100644 (file)
        "dellogpage": "削除記録",
        "dellogpagetext": "以下は最近の削除と復元の一覧です。",
        "deletionlog": "削除記録",
+       "log-name-create": "ページ作成記録",
+       "log-description-create": "以下はページ作成の最近の記録です。",
        "logentry-create-create": "$1 がページ「$3」を{{GENDER:$2|作成しました}}",
        "reverted": "以前の版への差し戻し",
        "deletecomment": "理由:",
index d6033e1..b81785c 100644 (file)
        "userlogin-yourname": "Username",
        "userlogin-yourname-ph": "Enter your username",
        "userlogin-yourpassword": "ꯆꯪꯁꯤꯟꯅꯕꯥ ꯋꯥꯍꯩ",
+       "userlogin-yourpassword-ph": "ꯄꯥꯁꯋ꯭ꯇ ꯏꯔꯛ ꯎ",
        "createacct-yourpassword-ph": "ꯄꯥꯁꯋ꯭ꯇ ꯏꯔꯛ ꯎ",
        "createacct-yourpasswordagain": "Confirm password",
        "createacct-yourpasswordagain-ph": "ꯑꯃꯨꯛ ꯍꯟꯅꯥ ꯄꯥꯁꯋ꯭ꯇ ꯏꯌꯨ",
+       "userlogin-remembermypassword": "ꯑꯩꯕꯨ ꯑꯗꯨꯝ ꯂꯣꯒ ꯏꯟ ꯇꯧꯍꯟꯂꯨ",
        "login": "Chang Sinba",
+       "logout": "Log out",
+       "userlogout": "ꯂꯣꯒ ꯑꯧꯇ",
+       "userlogin-noaccount": "ꯑꯦꯀꯥꯎꯟ ꯂꯩꯇꯕꯔꯥ",
+       "userlogin-joinproject": "ꯌꯥꯎꯕꯥ {{ꯃꯃꯤꯡ ꯏꯐꯝ}}",
        "createaccount": "ꯑꯩꯒꯤ ꯑꯣꯏꯕꯥ ꯑꯃꯥ ꯁꯦꯝꯕꯥ",
+       "userlogin-resetpassword-link": "ꯄꯥꯁꯋꯔꯇ ꯀꯥꯎꯈꯔꯕꯥ",
+       "userlogin-helplink2": "ꯂꯣꯒꯒꯤꯡ ꯇꯧꯗꯨꯅꯥ ꯃꯇꯦꯡ ꯄꯥꯡ ꯎ",
        "createacct-emailoptional": "Email address (ꯑꯇꯣꯞꯄꯥ ꯱)",
        "createacct-email-ph": "Enter your email address",
+       "createacct-reason": "ꯃꯔꯝ",
        "createacct-submit": "ꯅꯪꯒꯤ ꯑꯦꯀꯥꯎꯟꯇ ꯁꯦꯝꯕꯥ",
        "createacct-benefit-heading": "{{SITENAME}} ꯁꯤ ꯅꯪꯒꯥ ꯃꯥꯟꯅꯕꯥ ꯃꯤꯑꯣꯏꯁꯤꯡꯅꯥ ꯁꯦꯝꯕꯅꯤ",
        "createacct-benefit-body1": "{{PLURAL:$1|edit|edits}}",
        "createacct-benefit-body3": "ꯍꯧꯖꯤꯛꯀꯤ {{PLURAL:$1|contributor|contributors}}",
        "loginlanguagelabel": "$1 ꯂꯣꯟ",
        "pt-login": "Chang Sinba",
+       "pt-login-button": "Chang Sinba",
        "pt-createaccount": "ꯑꯩꯒꯤ ꯑꯣꯏꯕꯥ ꯑꯃꯥ ꯁꯦꯝꯕꯥ",
        "pt-userlogout": "Log out",
        "bold_sample": "ꯆꯥꯎꯅꯥ ꯏꯕꯥ",
        "showdiff": "ꯑꯍꯣꯡꯕꯗꯨ ꯎꯨꯇꯂꯨ",
        "anoneditwarning": "<strong>Warning:</strong> You are not logged in. Your IP address will be publicly visible if you make any edits. If you <strong>[$1 log in]</strong> or <strong>[$2 create an account]</strong>, your edits will be attributed to your username, along with other benefits.",
        "loginreqlink": "Chang Sinba",
+       "newarticletext": "You have followed a link to a page that does not exist yet.\nTo create the page, start typing in the box below (see the [$1 help page] for more info).\nIf you are here by mistake, click your browser's <strong>back</strong> button.",
        "noarticletext": "There is currently no text in this page.\nYou can [[Special:Search/{{PAGENAME}}|search for this page title]] in other pages,\n<span class=\"plainlinks\">[{{fullurl:{{#Special:Log}}|page={{FULLPAGENAMEE}}}} search the related logs],\nor [{{fullurl:{{FULLPAGENAME}}|action=edit}} create this page]</span>.",
        "noarticletext-nopermission": "There is currently no text in this page.\nYou can [[Special:Search/{{PAGENAME}}|search for this page title]] in other pages, or <span class=\"plainlinks\">[{{fullurl:{{#Special:Log}}|page={{FULLPAGENAMEE}}}} search the related logs]</span>, but you do not have permission to create this page.",
        "creating": "Creating $1",
        "editingsection": "Editing $1 (section)",
        "template-protected": "ꯉꯥꯛꯊꯣꯛꯂꯕꯥ",
        "template-semiprotected": "ꯇꯪꯈꯥꯏ ꯉꯥꯛꯊꯣꯛꯂꯕꯥ",
+       "currentrev-asof": "$1 ꯒꯤ ꯅꯧꯅꯥ ꯑꯃꯨꯛꯍꯟꯅꯥ ꯌꯦꯡꯕꯥ ꯃꯤꯠꯌꯦꯡ",
        "revisionasof": "Revision as of $1",
        "previousrevision": "ꯑꯔꯤꯕꯥ ꯑꯃꯨꯛ ꯍꯟꯅꯥ ꯌꯦꯡꯕꯥ",
+       "nextrevision": "ꯑꯅꯧꯕꯥ ꯑꯃꯨꯛꯍꯟꯅꯥ ꯌꯦꯡꯕꯥ",
+       "currentrevisionlink": "ꯈꯋꯥꯏꯗꯒꯤ ꯅꯧꯅꯥ ꯑꯃꯨꯛ ꯌꯦꯡꯕꯥ",
        "cur": "ꯍꯧ",
        "last": "ꯃꯥꯃꯥꯡꯒꯤ",
        "rev-delundel": "ꯑꯍꯣꯡꯕꯥ ꯎꯍꯟꯂꯤꯕꯥ",
        "searchresults-title": "Search results for \"$1\"",
        "prevn": "ꯍꯥꯟꯅꯒꯤ {{PLURAL:$1|$1}}",
        "nextn": "ꯃꯥꯊꯪ{{PLURAL:$1|$1}}",
+       "prevn-title": "ꯃꯃꯥꯡꯒꯤ $1 {{PLURAL:$1|result|results}}",
        "nextn-title": "Next $1 {{PLURAL:$1|result|results}}",
        "shown-title": "Show $1 {{PLURAL:$1|result|results}} per page",
        "viewprevnext": "ꯎꯨꯇꯂꯨ ($1 {{int:pipe-separator}} $2) ($3)",
        "search-result-size": "$1 ({{PLURAL:$2|1 word|$2 words}})",
        "search-redirect": "(redirect from $1)",
        "search-section": "(section $1)",
+       "search-suggest": "$1 ꯁꯤꯔꯥ ꯅꯪꯅꯥ ꯍꯥꯏꯅꯤꯡꯂꯤꯕꯥꯁꯤ",
        "searchall": "ꯄꯨꯂꯞ",
        "search-showingresults": "{{PLURAL:$4|Result <strong>$1</strong> of <strong>$3</strong>|Results <strong>$1 – $2</strong> of <strong>$3</strong>}}",
        "search-nonefound": "ꯃꯁꯤꯒꯤ ꯐꯣꯜꯁꯤꯒꯥ ꯆꯥꯟꯅꯕꯥ ꯂꯩꯇꯦ",
        "recentchanges-legend-newpage": "{{int:recentchanges-label-newpage}} (also see [[Special:NewPages|list of new pages]])",
        "rclistfrom": "$2$3 ꯁꯤꯗꯒꯤ ꯍꯧꯔꯒꯥ ꯑꯅꯧꯕꯥ ꯑꯍꯣꯡꯕꯗꯨ ꯎꯨꯇꯂꯨ",
        "rcshowhideminor": "$1 ꯄꯤꯛꯅꯥ ꯁꯦꯝꯒꯠꯄꯥ",
+       "rcshowhideminor-show": "ꯎꯨꯇꯄꯥ",
        "rcshowhideminor-hide": "ꯂꯣꯇꯄꯥ",
        "rcshowhidebots": "$1 bots",
        "rcshowhidebots-show": "ꯎꯨꯇꯄꯥ",
+       "rcshowhidebots-hide": "ꯂꯣꯇꯄꯥ",
        "rcshowhideliu": "ꯃꯃꯤꯡ ꯆꯟꯂꯕꯥ ꯄꯥꯏꯔꯤꯕꯥ $1",
+       "rcshowhideliu-show": "ꯎꯨꯇꯄꯥ",
        "rcshowhideliu-hide": "ꯂꯣꯇꯄꯥ",
        "rcshowhideanons": "$1 ꯃꯁꯛ ꯃꯥꯅꯥꯗꯕꯥ ꯄꯥꯏꯔꯤꯕꯥ ꯃꯤ",
+       "rcshowhideanons-show": "ꯎꯨꯇꯄꯥ",
        "rcshowhideanons-hide": "ꯂꯣꯇꯄꯥ",
        "rcshowhidemine": "$1 ꯑꯩꯅꯥ ꯁꯦꯝꯒꯠꯄꯁꯤꯡ",
+       "rcshowhidemine-show": "ꯎꯨꯇꯄꯥ",
        "rcshowhidemine-hide": "ꯂꯣꯇꯄꯥ",
        "rclinks": "$1 ꯒꯤ ꯑꯔꯣꯏꯕꯥ ꯑꯍꯣꯡꯕꯥꯗꯎ ꯎꯨꯇꯂꯎ $2 ꯃꯅꯨꯡꯗꯥ",
        "diff": "ꯈꯦꯠ",
        "upload": "ꯐꯥꯏꯜ ꯊꯥꯒꯠꯂꯨ",
        "filedesc": "ꯑꯇꯦꯟꯕꯥ ꯁꯟꯗꯣꯛꯅꯥ ꯇꯥꯛꯄꯥ",
        "license-header": "ꯑꯌꯥꯕꯥ",
+       "imgfile": "ꯈꯣꯝꯖꯤꯟꯗꯨꯅꯥ ꯍꯥꯞꯐꯝ",
        "file-anchor-link": "ꯈꯣꯝꯖꯤꯟꯗꯨꯅꯥ ꯍꯥꯞꯐꯝ",
        "filehist": "ꯐꯥꯏꯜꯒꯤ ꯄꯨꯋꯥꯔꯤ",
        "filehist-help": "Cheichat/Matamda nammmu matam aduda file adu ooonaba",
+       "filehist-revert": "ꯑꯃꯨꯛ ꯍꯟꯂꯟꯕꯥ",
        "filehist-current": "Houjikki",
        "filehist-datetime": "ꯆꯩꯆꯠ/ꯃꯇꯝ",
        "filehist-thumb": "Khutpina namba",
        "randompage": "ꯆꯥꯡ ꯅꯥꯏꯗꯕꯥ ꯂꯥꯃꯥꯏ",
        "nbytes": "$1 {{PLURAL:$1|byte|bytes}}",
        "newpages": "ꯑꯅꯧꯕꯥ ꯂꯥꯃꯥꯏꯁꯤꯡ",
+       "move": "ꯂꯦꯡꯍꯟꯕꯥ",
        "booksources": "ꯂꯥꯏꯔꯤꯛꯀꯤ ꯍꯧꯔꯛꯐꯝ",
+       "booksources-search": "ꯊꯤꯕꯥ",
        "log": "ꯆꯪꯕꯥ",
+       "allpages": "ꯂꯥꯃꯥꯏ ꯂꯣꯏꯅꯥ",
+       "allarticles": "ꯂꯥꯃꯥꯏ ꯂꯣꯏꯅꯥ",
        "allpagessubmit": "ꯆꯠꯂꯨ",
        "mywatchlist": "Watchlist",
        "watch": "ꯌꯦꯡꯕꯥ",
+       "dellogpage": "ꯀꯛꯊꯠꯄꯥꯒꯤ ꯂꯣꯒ",
        "rollbacklink": "ꯑꯃꯨꯛ ꯍꯟꯍꯟꯕꯥ",
+       "restriction-edit": "ꯁꯦꯝꯒꯠꯄꯥ",
+       "restriction-move": "ꯂꯦꯡꯍꯟꯕꯥ",
        "namespace": "ꯃꯥꯃꯤꯡꯒꯤ ꯃꯐꯝ",
        "invert": "Khanlibadu Makoktagi lak hanba",
        "tooltip-invert": "Akhannaba maming gi manungda page tungi ahongba lotnaba oopu du yeng ngoo",
        "anoncontribs": "ꯈꯣꯝꯒꯠꯂꯛꯂꯤꯕꯁꯤꯡ",
        "month": "ꯃꯗꯨꯒꯤ ꯊꯥꯗꯒꯤ (ꯑꯃꯗꯤ ꯅꯧꯔꯤꯕꯥ)",
        "year": "ꯃꯗꯨꯒꯤ ꯆꯥꯍꯤꯗꯒꯤ (ꯑꯃꯗꯤ ꯅꯧꯔꯤꯕꯥ)",
+       "sp-contributions-talk": "ꯉꯥꯡꯐꯝ",
+       "sp-contributions-submit": "ꯊꯤꯕꯥ",
        "whatlinkshere": "ꯃꯁꯤꯗꯥ ꯀꯔꯤ ꯁꯝꯃꯤ",
        "whatlinkshere-title": "$1 ꯒꯥ ꯃꯔꯤ ꯂꯩꯅꯕꯥ ꯁꯝꯅꯐꯝ",
        "whatlinkshere-page": "ꯂꯥꯃꯥꯏ",
        "tooltip-undo": "\"Undo\" reverts this edit and opens the edit form in preview mode. It allows adding a reason in the summary.",
        "tooltip-summary": "ꯑꯇꯦꯟꯕꯥ ꯀꯨꯞꯅꯥ ꯁꯟꯗꯣꯛꯅꯩ ꯇꯥꯛꯄꯥ ꯏꯌꯨ",
        "simpleantispam-label": "Anti-spam check.\nDo <strong>not</strong> fill this in!",
+       "pageinfo-header-restrictions": "ꯉꯥꯛꯊꯣꯛꯂꯕꯥ ꯂꯥꯃꯥꯏ",
        "pageinfo-robot-noindex": "ꯌꯥꯍꯟꯗꯕꯥ",
        "pageinfo-subpages-name": "ꯂꯥꯃꯥꯏꯁꯤ ꯒꯤ ꯃꯅꯨꯡ ꯆꯟꯕꯥ ꯀꯨꯞꯊꯕꯥ ꯂꯥꯃꯥꯏꯁꯤꯡ",
        "pageinfo-subpages-value": "$1 ($2 {{PLURAL:$2|redirect|redirects}}; $3 {{PLURAL:$3|non-redirect|non-redirects}})",
        "pageinfo-magic-words": "Magic {{PLURAL:$1|word|words}} ($1)",
        "pageinfo-toolboxlink": "ꯂꯥꯃꯥꯏꯒꯤ ꯃꯇꯥꯡꯗꯥ",
+       "pageinfo-contentpage-yes": "ꯍꯣꯏ",
        "previousdiff": "ꯑꯔꯤꯕꯥ ꯁꯦꯝꯒꯠꯂꯛꯐꯝ",
        "file-info-size": "$1 × $2 pixels, file size: $3, MIME type: $4",
        "file-nohires": "ꯃꯁꯤꯗꯒꯤ ꯍꯦꯟꯅꯥ ꯁꯦꯡꯕꯥ ꯂꯩꯇꯔꯦ",
        "namespacesall": "Pullap",
        "monthsall": "ꯄꯨꯂꯞ",
        "signature": "[[{{ns:user}}:$1|$2]] ([[{{ns:user_talk}}:$1|talk]])",
+       "redirect-submit": "ꯆꯠꯂꯨ",
+       "redirect-value": "ꯃꯔꯨꯑꯣꯏꯕꯥ",
        "specialpages": "MediaWiki:Bs-wikiadmin-mediawiki-akhannaba-lamai-text/mni",
        "tag-filter": "[[Special:Tags|Tag]] filter:",
        "tag-list-wrapper": "([[Special:Tags|{{PLURAL:$1|Tag|Tags}}]]: $2)",
+       "tags-active-yes": "ꯍꯣꯏ",
+       "tags-active-no": "ꯅꯠꯇꯦ",
        "logentry-delete-delete": "$1 {{GENDER:$2|deleted}} page $3",
        "logentry-newusers-create": "User account $1 was {{GENDER:$2|created}}",
        "searchsuggest-search": "ꯊꯤꯔꯣ ꯃꯐꯝꯗꯨꯒꯤ ꯃꯃꯤꯡ"
index f51ac71..395b665 100644 (file)
        "rcfilters-legend-heading": "<strong>Liste over forkortingar:</strong>",
        "rcfilters-group-results-by-page": "Grupper resultat etter side",
        "rcfilters-activefilters": "Aktive filter",
+       "rcfilters-activefilters-hide": "Gøym",
+       "rcfilters-activefilters-show": "Vis",
+       "rcfilters-activefilters-hide-tooltip": "Gøym området for aktive filter",
+       "rcfilters-activefilters-show-tooltip": "Vis området for aktive filter",
        "rcfilters-advancedfilters": "Avanserte filter",
-       "rcfilters-limit-title": "Tal endringar som skal visast",
+       "rcfilters-limit-title": "Resultat som skal visast",
        "rcfilters-limit-and-date-label": "{{PLURAL:$1|éi endring|$1 endringar}}, $2",
        "rcfilters-date-popup-title": "Søk i tidsperioden",
        "rcfilters-days-title": "Dei siste dagane",
        "exif-model": "Kameramodell",
        "exif-software": "Programvare brukt",
        "exif-artist": "Skapar",
-       "exif-copyright": "Opphavsrettsleg eigar",
+       "exif-copyright": "Opphavsrettshaldar",
        "exif-exifversion": "Exif-versjon",
        "exif-flashpixversion": "Støtta Flashpix-versjon",
        "exif-colorspace": "Fargerom",
index 989c83b..9fba0d5 100644 (file)
        "virus-scanfailed": "کھوج نا ہوسکی (کوڈ $1)",
        "virus-unknownscanner": "اندیکھا اینٹیوائرس:",
        "logouttext": "'''تسی لاگ آؤٹ ہوگۓ او.'''\nتسی   {{SITENAME}} نوں گمنامی چ ورت سکدے او یا تسی <span class='plainlinks'>[$1 لاگ ان دوبارہ]</span> ہوجاؤ اوسے ناں توں یا وکھرے ورتن والے توں۔ اے گل چیتے رکھنا جے کج صفیاں تے تسی لاگ ان دسے جاؤگے جدوں تک تسی اپنے براؤزر دے کاشے نوں صاف ناں کرلو۔\nYou can continue to use {{SITENAME}} anonymously, or you can <span class='plainlinks'>[$1 log in again]</span> as the same or as a different user.\nNote that some pages may continue to be displayed as if you were still logged in, until you clear your browser cache.",
+       "welcomeuser": "جی آیاں نوں، $1!",
        "yourname": "ورتن والہ:",
        "userlogin-yourname": "ورتن ناں",
        "userlogin-yourname-ph": "اپنا ورتن ناں لکھو",
index 7802628..a88101d 100644 (file)
        "undeletepagetitle": "'''د [[:$1|$1]] ړنگې شوې بڼې په لاندې توگه دي'''.",
        "viewdeletedpage": "ړنگ شوي مخونه کتل",
        "undelete-fieldset-title": "بڼې بيازېرمل",
+       "undeleteextrahelp": "د ټول مخ د معلوماتو د بيا کتنې لپاره د '''''{{int:undeletebtn}}''''' پر\nبټن کښي کاږي، او ددي ترمخه چي د '''''{{int:undeletebtn}}''''' پر مخ ګوته يا موس بټن کښي کاږي نو لږ فکر پر وکړي.",
        "undeleterevisions": "$1 {{PLURAL:$1|بڼه|بڼې}} خونديځ کې {{PLURAL:$1|ورگډ شو|ورگډ شول}}",
        "undeletehistory": "که تاسې همدا مخ بيازېرمه کوۍ، نو ټولې بڼې به يې پېښليک کې زېرمه شي.\nکه چېرته د ړنگېدو وروسته په همدې نوم يو بل نوی مخ جوړ شوی وي، نو زېرمه شوې بڼې به يې په پخواني پېښليک کې ښکاره شي.",
+       "undeleterevdel": "ړنګيدنه بيرته راګرځول به د مخ په پيښنليک کي نشي ښکاره، او تاسو که ليکنه ړنګه کړي نو د کارنانو سمونې به بيا هم پرځای پاته وي. \nپه دا ډول پيښو کې تاسو بايد د کارنانو سمونې پټې يا ړنګې کړي.",
+       "undelete-revision": "د $1 ړنګه شوي بڼه (چې د $4 نيټې په $5 بجو) د $3 لخوا داسې جوړه شوي وه:",
        "undelete-nodiff": "کومې پخوانۍ بڼې و نه موندل شوې.",
        "undeletebtn": "بيازېرمل",
        "undeletelink": "کتل/بيازېرمل",
index 656f82f..31ebb2c 100644 (file)
        "resetpass-submit-cancel": "Откажи",
        "resetpass-wrong-oldpass": "Неисправна привремена или тренутна лозинка.\nМожда сте већ променили лозинку или сте затражили нову привремену лозинку.",
        "resetpass-recycled": "Унели сте садашњу лозинку, да бисте променили лозинку морате унети нову.",
-       "resetpass-temp-emailed": "Пријавили сте се са привременим кодом из имејла.\nДа бисте завршили пријављивање морате поставити нову лозинку овде:",
+       "resetpass-temp-emailed": "Пријавили сте се са привременим кôдом из имејла.\nДа бисте завршили пријављивање морате поставити нову лозинку овде:",
        "resetpass-temp-password": "Привремена лозинка:",
        "resetpass-abort-generic": "Промену лозинке је спречио додатак.",
        "resetpass-expired": "Ваша лозинка је истекла. Поставите нову лозинку да бисте се пријавили.",
        "exif-iimsupplementalcategory": "Допунске категорије",
        "exif-datetimeexpires": "Не користи након",
        "exif-datetimereleased": "Објављено",
-       "exif-originaltransmissionref": "Изворни пренос кода локације",
+       "exif-originaltransmissionref": "Изворни пренос кôда локације",
        "exif-identifier": "Назнака",
        "exif-lens": "Коришћени објектив",
        "exif-serialnumber": "Серијски број камере",
        "monthsall": "све",
        "confirmemail": "Потврда имејл адресе",
        "confirmemail_noemail": "Нисте унели исправну имејл адресу у [[Special:Preferences|подешавањима]].",
-       "confirmemail_text": "{{SITENAME}} захтева да потврдите имејл адресу пре него што почнете да користите могућности имејла.\nКликните на дугме испод за слање поруке на вашу адресу.\nУ поруци ће се налазити веза с потврдним кодом;\nунесите је у прегледач да бисте потврдили да је ваша имејл адреса исправна.",
+       "confirmemail_text": "{{SITENAME}} захтева да потврдите имејл адресу пре него што почнете да користите могућности имејла.\nКликните на дугме испод за слање поруке на вашу адресу.\nУ поруци ће се налазити веза с потврдним кôдом;\nунесите је у прегледач да бисте потврдили да је ваша имејл адреса исправна.",
        "confirmemail_pending": "Потврдни кôд вам је већ послат. Ако сте управо отворили налог, онда вероватно треба да сачекате неколико минута да пристигне, пре него што поново затражите нови кôд.",
        "confirmemail_send": "Пошаљи потврдни кôд",
        "confirmemail_sent": "Потврдна порука је послата.",
index 70ec8d2..dfd60de 100644 (file)
@@ -53,6 +53,7 @@
        "tog-showhiddencats": "Mostrer les categoreyes mucheyes",
        "tog-norollbackdiff": "Èn nén håyner les diferinces après on disfijhaedje",
        "tog-useeditwarning": "M' advierti cwand dji cwite ene pådje k' a des candjmints nén schapés",
+       "tog-prefershttps": "Todi eployî on seur raloyaedje cwand dji so elodjî",
        "underline-always": "Tofer",
        "underline-never": "Måy",
        "underline-default": "Valixhance del pea u do betchteu",
index 54296b1..18bd346 100644 (file)
        "group-sysop-member": "{{GENDER:$1|管理員}}",
        "group-bureaucrat-member": "行政員",
        "group-suppress-member": "{{GENDER:$1|監督員}}",
-       "grouppage-user": "{{ns:project}}:用戶",
+       "grouppage-user": "{{ns:project}}:使用者",
        "grouppage-autoconfirmed": "{{ns:project}}:自動確認使用者",
        "grouppage-bot": "{{ns:project}}:機器人",
        "grouppage-sysop": "{{ns:project}}:管理員",
        "listfiles_thumb": "縮圖",
        "listfiles_date": "日期",
        "listfiles_name": "名稱",
-       "listfiles_user": "用戶",
+       "listfiles_user": "使用者",
        "listfiles_size": "大小",
        "listfiles_description": "描述",
        "listfiles_count": "版本",
        "filehist-thumb": "縮圖",
        "filehist-thumbtext": "於 $1 版本的縮圖",
        "filehist-nothumb": "沒有縮圖",
-       "filehist-user": "用戶",
+       "filehist-user": "使用者",
        "filehist-dimensions": "尺寸",
        "filehist-filesize": "檔案大小",
        "filehist-comment": "備註",
        "unwatching": "正在停止監視...",
        "watcherrortext": "變更 \"$1\" 的監視清單設定時發生錯誤。",
        "enotif_reset": "標記所有頁面為已檢視",
-       "enotif_impersonal_salutation": "{{SITENAME}}用戶",
+       "enotif_impersonal_salutation": "{{SITENAME}}使用者",
        "enotif_subject_deleted": "{{SITENAME}} $2 已刪除頁面 $1",
        "enotif_subject_created": "{{SITENAME}} $2 已建立頁面 $1",
        "enotif_subject_moved": "{{SITENAME}} $2 已移動頁面 $1",
        "pageinfo-category-pages": "頁面數量",
        "pageinfo-category-subcats": "子分類數量",
        "pageinfo-category-files": "檔案數量",
-       "pageinfo-user-id": "用戶ID",
+       "pageinfo-user-id": "使用者 ID",
        "pageinfo-file-hash": "雜湊值",
        "markaspatrolleddiff": "標記為已巡查",
        "markaspatrolledtext": "標記此頁面為已巡查",
        "redirect-submit": "執行",
        "redirect-lookup": "查詢:",
        "redirect-value": "值:",
-       "redirect-user": "用戶ID",
+       "redirect-user": "使用者ID",
        "redirect-page": "頁面 ID",
        "redirect-revision": "頁面修訂 ID",
        "redirect-file": "檔案名稱",
diff --git a/languages/messages/MessagesMni.php b/languages/messages/MessagesMni.php
new file mode 100644 (file)
index 0000000..1641c2a
--- /dev/null
@@ -0,0 +1,9 @@
+<?php
+/** Manipuri/Meitei (মেইতেই লোন্)
+ *
+ * To improve a translation please visit https://translatewiki.net
+ *
+ * @ingroup Language
+ * @file
+ *
+ */
index aa5fdeb..81a8a14 100644 (file)
@@ -92,92 +92,92 @@ $namespaceAliases = [
 ];
 
 $specialPageAliases = [
-       'Allmessages'               => [ 'सर्वप्रणाली-संदेश' ],
-       'Allpages'                  => [ 'सर्वपृष्टानि' ],
-       'Ancientpages'              => [ 'पूर्वतनपृष्टानि' ],
-       'Blankpage'                 => [ 'रिक्तपृष्ठ' ],
-       'Block'                     => [ 'सदस्यप्रतिबन्ध' ],
-       'Booksources'               => [ 'पुस्तकस्रोत' ],
-       'BrokenRedirects'           => [ 'खण्डीतपुनर्निर्देशन' ],
-       'Categories'                => [ 'वर्गः' ],
-       'ChangePassword'            => [ 'सङ्केतशब्दपुन:प्रयुक्ता' ],
-       'Confirmemail'              => [ 'विपत्रपुष्टिकृते' ],
-       'Contributions'             => [ 'योगदानम्' ],
-       'CreateAccount'             => [ 'सृज्उपयोजकसंज्ञा' ],
-       'Deadendpages'              => [ 'निराग्रपृष्टानि' ],
-       'DeletedContributions'      => [ 'परित्यागितयोगदान' ],
-       'DoubleRedirects'           => [ 'पुनर्निर्देशनद्वंद्व' ],
-       'Emailuser'                 => [ 'विपत्रयोजक' ],
-       'ExpandTemplates'           => [ 'बिंबधरविस्तारकरोसि' ],
-       'Export'                    => [ 'निर्यात' ],
-       'Fewestrevisions'           => [ 'स्वल्पपरिवर्तन' ],
-       'FileDuplicateSearch'       => [ 'अनुकृतसंचिकाशोध' ],
-       'Filepath'                  => [ 'संचिकापथ' ],
-       'Import'                    => [ 'आयात' ],
-       'Invalidateemail'           => [ 'अमान्यविपत्र' ],
-       'BlockList'                 => [ 'प्रतिबन्धसूची' ],
-       'LinkSearch'                => [ 'सम्बन्धन्‌शोध' ],
-       'Listadmins'                => [ 'प्रचालकसूची' ],
-       'Listbots'                  => [ 'स्वयंअनुकृसूची' ],
-       'Listfiles'                 => [ 'चित्रसूची', 'संचिकासूचि' ],
-       'Listgrouprights'           => [ 'गटअधिकारसूची' ],
-       'Listredirects'             => [ 'विचालन्‌सूची' ],
-       'Listusers'                 => [ 'सदस्यासूची' ],
-       'Lockdb'                    => [ 'विदाद्वारंबन्ध्' ],
-       'Log'                       => [ 'अङ्कन' ],
-       'Lonelypages'               => [ 'अकलपृष्टानि' ],
-       'Longpages'                 => [ 'दीर्घपृष्टानि' ],
-       'MergeHistory'              => [ 'इतिहाससंयोग' ],
-       'MIMEsearch'                => [ 'विविधामाप_(माईम)_शोधसि' ],
-       'Mostcategories'            => [ 'अधिकतमवर्ग' ],
-       'Mostimages'                => [ 'अधिकतमसम्भन्दिन्_संचिका' ],
-       'Mostlinked'                => [ 'अधिकतमसम्भन्दिन्_पृष्टानि', 'अधिकतमसम्भन्दिन्' ],
-       'Mostlinkedcategories'      => [ 'अधिकतमसम्भन्दिन्_वर्ग' ],
-       'Mostlinkedtemplates'       => [ 'अधिकतमसम्भन्दिन्_फलकानि' ],
-       'Mostrevisions'             => [ 'अधिकतमपरिवर्तन' ],
-       'Movepage'                  => [ 'पृष्ठस्थानान्तर' ],
-       'Mycontributions'           => [ 'मदीययोगदानम्' ],
-       'Mypage'                    => [ 'मम_पृष्टम्' ],
-       'Mytalk'                    => [ 'मदीयसंवादम्' ],
-       'Newimages'                 => [ 'नूतनसंचिका', 'नूतनचित्रानि' ],
-       'Newpages'                  => [ 'नूतनपृष्टानि' ],
-       'PasswordReset'             => [ 'सङ्केतशब्दपुन:प्रयु्क्ता' ],
+       'Allmessages'               => [ 'सरà¥\8dवसनà¥\8dदà¥\87शाà¤\83', 'सरà¥\8dवपà¥\8dरणालà¥\80-सà¤\82दà¥\87श' ],
+       'Allpages'                  => [ 'सरà¥\8dवपà¥\83षà¥\8dठानि', 'सरà¥\8dवपà¥\83षà¥\8dà¤\9fानि' ],
+       'Ancientpages'              => [ 'पà¥\81रातनपà¥\83षà¥\8dठानि', 'पà¥\82रà¥\8dवतनपà¥\83षà¥\8dà¤\9fानि' ],
+       'Blankpage'                 => [ 'रिक्तपृष्ठानि', 'रिक्तपृष्ठ' ],
+       'Block'                     => [ 'पà¥\8dरतिबनà¥\8dधà¤\83', 'सदसà¥\8dयपà¥\8dरतिबनà¥\8dध' ],
+       'Booksources'               => [ 'पुस्तकस्रोतांसि', 'पुस्तकस्रोत' ],
+       'BrokenRedirects'           => [ 'भà¤\97à¥\8dनानि_à¤\85नà¥\81पà¥\8dरà¥\87षणानि', 'à¤\96णà¥\8dडà¥\80तपà¥\81नरà¥\8dनिरà¥\8dदà¥\87शन' ],
+       'Categories'                => [ 'वरà¥\8dà¤\97ाà¤\83', 'वरà¥\8dà¤\97à¤\83' ],
+       'ChangePassword'            => [ 'à¤\95à¥\82à¤\9fशबà¥\8dदà¤\83_परिवरà¥\8dतà¥\8dयतामà¥\8d', 'सà¤\99à¥\8dà¤\95à¥\87तशबà¥\8dदपà¥\81न:पà¥\8dरयà¥\81à¤\95à¥\8dता' ],
+       'Confirmemail'              => [ 'विपतà¥\8dरà¤\82_पà¥\81षà¥\8dà¤\9fà¥\8dयतामà¥\8d', 'विपतà¥\8dरपà¥\81षà¥\8dà¤\9fिà¤\95à¥\83तà¥\87' ],
+       'Contributions'             => [ 'यà¥\8bà¤\97दानानि', 'यà¥\8bà¤\97दानमà¥\8d' ],
+       'CreateAccount'             => [ 'लà¥\87à¤\96ा_सà¥\83à¤\9cà¥\8dयतामà¥\8d', 'सà¥\83à¤\9cà¥\8dà¤\89पयà¥\8bà¤\9cà¤\95सà¤\82à¤\9cà¥\8dà¤\9eा' ],
+       'Deadendpages'              => [ 'मà¥\83तानि_पà¥\83षà¥\8dठानि', 'निराà¤\97à¥\8dरपà¥\83षà¥\8dà¤\9fानि' ],
+       'DeletedContributions'      => [ 'à¤\85पाà¤\95à¥\83तानि_यà¥\8bà¤\97दानानि', 'परितà¥\8dयाà¤\97ितयà¥\8bà¤\97दान' ],
+       'DoubleRedirects'           => [ 'दà¥\8dवà¥\88धपà¥\81नरà¥\8dनिरà¥\8dदà¥\87शनमà¥\8d', 'पà¥\81नरà¥\8dनिरà¥\8dदà¥\87शनदà¥\8dवà¤\82दà¥\8dव' ],
+       'Emailuser'                 => [ 'विपतà¥\8dरपà¥\8dरयà¥\8bà¤\95à¥\8dता', 'विपतà¥\8dरयà¥\8bà¤\9cà¤\95' ],
+       'ExpandTemplates'           => [ 'फलà¤\95ानि_विसà¥\8dतà¥\80रà¥\8dयनà¥\8dतामà¥\8d', 'बिà¤\82बधरविसà¥\8dतारà¤\95रà¥\8bसि' ],
+       'Export'                    => [ 'निरà¥\8dयापयतà¥\81', 'निरà¥\8dयात' ],
+       'Fewestrevisions'           => [ 'सà¥\8dवलà¥\8dपतमपरिवरà¥\8dतानानि', 'सà¥\8dवलà¥\8dपपरिवरà¥\8dतन' ],
+       'FileDuplicateSearch'       => [ 'समानसà¤\9eà¥\8dà¤\9aिà¤\95ानà¥\8dवà¥\87षणमà¥\8d', 'à¤\85नà¥\81à¤\95à¥\83तसà¤\82à¤\9aिà¤\95ाशà¥\8bध' ],
+       'Filepath'                  => [ 'सà¤\9eà¥\8dà¤\9aिà¤\95ापथà¤\83', 'सà¤\82à¤\9aिà¤\95ापथ' ],
+       'Import'                    => [ 'à¤\86यापयतà¥\81', 'à¤\86यात' ],
+       'Invalidateemail'           => [ 'विपतà¥\8dरà¥\87ऽमानà¥\8dयमà¥\8d', 'à¤\85मानà¥\8dयविपतà¥\8dर' ],
+       'BlockList'                 => [ 'पà¥\8dरतिबनà¥\8dधावलिà¤\83', 'पà¥\8dरतिबनà¥\8dधसà¥\82à¤\9aà¥\80' ],
+       'LinkSearch'                => [ 'परिसनà¥\8dधà¥\87à¤\83_à¤\85नà¥\8dवà¥\87षणमà¥\8d', 'समà¥\8dबनà¥\8dधनà¥\8dâ\80\8cशà¥\8bध' ],
+       'Listadmins'                => [ 'पà¥\8dरबनà¥\8dधà¤\95ावलिà¤\83', 'पà¥\8dरà¤\9aालà¤\95सà¥\82à¤\9aà¥\80' ],
+       'Listbots'                  => [ 'बà¥\89à¤\9fसà¥\82à¤\9aà¥\80', 'सà¥\8dवयà¤\82à¤\85नà¥\81à¤\95à¥\83सà¥\82à¤\9aà¥\80' ],
+       'Listfiles'                 => [ 'सà¤\9eà¥\8dà¤\9aिà¤\95ावलिà¤\83', 'à¤\9aितà¥\8dरसà¥\82à¤\9aà¥\80', 'सà¤\82à¤\9aिà¤\95ासà¥\82à¤\9aि' ],
+       'Listgrouprights'           => [ 'समà¥\82हाधिà¤\95ारावलिà¤\83', 'à¤\97à¤\9fà¤\85धिà¤\95ारसà¥\82à¤\9aà¥\80' ],
+       'Listredirects'             => [ 'à¤\85नà¥\81पà¥\8dरà¥\87षितावलिà¤\83', 'विà¤\9aालनà¥\8dâ\80\8cसà¥\82à¤\9aà¥\80' ],
+       'Listusers'                 => [ 'सदसà¥\8dयावलिà¤\83', 'सदसà¥\8dयासà¥\82à¤\9aà¥\80' ],
+       'Lockdb'                    => [ 'दतà¥\8dताà¤\82शà¤\95à¥\80लनमà¥\8d', 'विदादà¥\8dवारà¤\82बनà¥\8dधà¥\8d' ],
+       'Log'                       => [ 'सà¤\82रà¤\95à¥\8dषितावलिà¤\83', 'à¤\85à¤\99à¥\8dà¤\95न' ],
+       'Lonelypages'               => [ 'à¤\8fà¤\95ाà¤\95िपà¥\83षà¥\8dठानि', 'à¤\85à¤\95लपà¥\83षà¥\8dà¤\9fानि' ],
+       'Longpages'                 => [ 'दà¥\80रà¥\8dà¤\98पà¥\83षà¥\8dठानि', 'दà¥\80रà¥\8dà¤\98पà¥\83षà¥\8dà¤\9fानि' ],
+       'MergeHistory'              => [ 'à¤\87तिहासविलयà¤\83', 'à¤\87तिहाससà¤\82यà¥\8bà¤\97' ],
+       'MIMEsearch'                => [ 'MIME_अन्वेषणम्', 'विविधामाप_(माईम)_शोधसि' ],
+       'Mostcategories'            => [ 'अधिकतमवर्गाः', 'अधिकतमवर्ग' ],
+       'Mostimages'                => [ 'à¤\85धिà¤\95तमसà¤\9eà¥\8dà¤\9aिà¤\95ाà¤\83', 'à¤\85धिà¤\95तमसमà¥\8dभनà¥\8dदिनà¥\8d_सà¤\82à¤\9aिà¤\95ा' ],
+       'Mostlinked'                => [ 'à¤\85धिà¤\95तमपरिसनà¥\8dधितमà¥\8d', 'à¤\85धिà¤\95तमसमà¥\8dभनà¥\8dदिनà¥\8d_पà¥\83षà¥\8dà¤\9fानि', 'à¤\85धिà¤\95तमसमà¥\8dभनà¥\8dदिनà¥\8d' ],
+       'Mostlinkedcategories'      => [ 'à¤\85धिà¤\95तमपरिसनà¥\8dधितवरà¥\8dà¤\97ाà¤\83', 'à¤\85धिà¤\95तमसमà¥\8dभनà¥\8dदिनà¥\8d_वरà¥\8dà¤\97' ],
+       'Mostlinkedtemplates'       => [ 'à¤\85धिà¤\95तमपरिसनà¥\8dधितफलà¤\95ानि', 'à¤\85धिà¤\95तमसमà¥\8dभनà¥\8dदिनà¥\8d_फलà¤\95ानि' ],
+       'Mostrevisions'             => [ 'à¤\85धिà¤\95तमसà¤\82सà¥\8dà¤\95रणानि', 'à¤\85धिà¤\95तमपरिवरà¥\8dतन' ],
+       'Movepage'                  => [ 'पृष्ठस्थानान्तरणम्', 'पृष्ठस्थानान्तर' ],
+       'Mycontributions'           => [ 'मम_यà¥\8bà¤\97दानानि', 'मदà¥\80ययà¥\8bà¤\97दानमà¥\8d' ],
+       'Mypage'                    => [ 'मम_पà¥\83षà¥\8dठमà¥\8d', 'मम_पà¥\83षà¥\8dà¤\9fमà¥\8d' ],
+       'Mytalk'                    => [ 'मम_समà¥\8dभाषणमà¥\8d', 'मदà¥\80यसà¤\82वादमà¥\8d' ],
+       'Newimages'                 => [ 'नवà¥\80नà¤\9aितà¥\8dराणि', 'नà¥\82तनसà¤\82à¤\9aिà¤\95ा', 'नà¥\82तनà¤\9aितà¥\8dरानि' ],
+       'Newpages'                  => [ 'नवà¥\80नपà¥\83षà¥\8dठानि', 'नà¥\82तनपà¥\83षà¥\8dà¤\9fानि' ],
+       'PasswordReset'             => [ 'à¤\95à¥\82à¤\9fशबà¥\8dदसà¥\8dय_पà¥\81नसà¥\8dसà¥\8dथापनमà¥\8d', 'सà¤\99à¥\8dà¤\95à¥\87तशबà¥\8dदपà¥\81न:पà¥\8dरयà¥\81à¥\8dà¤\95à¥\8dता' ],
        'Preferences'               => [ 'इष्टतमानि' ],
-       'Prefixindex'               => [ 'उपसर्गअनुक्रमणी' ],
-       'Protectedpages'            => [ 'सुरक्षितपृष्टानि' ],
-       'Protectedtitles'           => [ 'सुरक्षितशिर्षकम्' ],
-       'Randompage'                => [ 'अविशीष्टपृष्ठम्' ],
-       'RandomInCategory'          => [ 'अविशिष्टवर्ग' ],
-       'Randomredirect'            => [ 'अविशीष्टविचालन्‌' ],
-       'Recentchanges'             => [ 'नवीनतम_परिवर्तन' ],
-       'Recentchangeslinked'       => [ 'नवीनतमसम्भन्दिन_परिवर्त' ],
-       'Revisiondelete'            => [ 'आवृत्तीपरित्याग' ],
-       'Search'                    => [ 'शोध' ],
-       'Shortpages'                => [ 'लघुपृष्टानि' ],
-       'Specialpages'              => [ 'विशेषपृष्टानि' ],
-       'Statistics'                => [ 'सांख्यिकी' ],
-       'Uncategorizedcategories'   => [ 'अवर्गीकृतवर्ग' ],
-       'Uncategorizedimages'       => [ 'अवर्गीकृतसंचिका', 'अवर्गीकृतचित्रानि' ],
-       'Uncategorizedpages'        => [ 'अवर्गीकृतपृष्टानि' ],
+       'Prefixindex'               => [ 'à¤\89पसरà¥\8dà¤\97ानà¥\81à¤\95à¥\8dरमणà¥\80', 'à¤\89पसरà¥\8dà¤\97à¤\85नà¥\81à¤\95à¥\8dरमणà¥\80' ],
+       'Protectedpages'            => [ 'सà¥\81रà¤\95à¥\8dषितपà¥\83षà¥\8dठानि', 'सà¥\81रà¤\95à¥\8dषितपà¥\83षà¥\8dà¤\9fानि' ],
+       'Protectedtitles'           => [ 'सà¥\81रà¤\95à¥\8dषितशà¥\80रà¥\8dषà¤\95ाणि', 'सà¥\81रà¤\95à¥\8dषितशिरà¥\8dषà¤\95मà¥\8d' ],
+       'Randompage'                => [ 'यादà¥\83à¤\9aà¥\8dà¤\9bिà¤\95पà¥\83षà¥\8dठमà¥\8d', 'à¤\85विशà¥\80षà¥\8dà¤\9fपà¥\83षà¥\8dठमà¥\8d' ],
+       'RandomInCategory'          => [ 'वरà¥\8dà¤\97à¥\87_यादà¥\83à¤\9aà¥\8dà¤\9bिà¤\95मà¥\8d', 'à¤\85विशिषà¥\8dà¤\9fवरà¥\8dà¤\97' ],
+       'Randomredirect'            => [ 'यादà¥\83à¤\9aà¥\8dà¤\9bिà¤\95ानà¥\81पà¥\8dरà¥\87षितमà¥\8d', 'à¤\85विशà¥\80षà¥\8dà¤\9fविà¤\9aालनà¥\8dâ\80\8c' ],
+       'Recentchanges'             => [ 'नà¥\82तनपरिवरà¥\8dतनानि', 'नवà¥\80नतम_परिवरà¥\8dतन' ],
+       'Recentchangeslinked'       => [ 'नà¥\82तनपरिवरà¥\8dतनानाà¤\82_परिसनà¥\8dधयà¤\83', 'नवà¥\80नतमसमà¥\8dभनà¥\8dदिन_परिवरà¥\8dत' ],
+       'Revisiondelete'            => [ 'सà¤\82सà¥\8dà¤\95रणापाà¤\95रणमà¥\8d', 'à¤\86वà¥\83तà¥\8dतà¥\80परितà¥\8dयाà¤\97' ],
+       'Search'                    => [ 'à¤\85नà¥\8dवà¥\87षणमà¥\8d', 'शà¥\8bध' ],
+       'Shortpages'                => [ 'लà¤\98à¥\81पà¥\83षà¥\8dठानि', 'लà¤\98à¥\81पà¥\83षà¥\8dà¤\9fानि' ],
+       'Specialpages'              => [ 'विशà¥\87षपà¥\83षà¥\8dठानि', 'विशà¥\87षपà¥\83षà¥\8dà¤\9fानि' ],
+       'Statistics'                => [ 'साà¤\99à¥\8dà¤\96à¥\8dयिà¤\95à¥\80', 'साà¤\82à¤\96à¥\8dयिà¤\95à¥\80' ],
+       'Uncategorizedcategories'   => [ 'अवर्गीकृतवर्गाः', 'अवर्गीकृतवर्ग' ],
+       'Uncategorizedimages'       => [ 'à¤\85वरà¥\8dà¤\97à¥\80à¤\95à¥\83तà¤\9aितà¥\8dराणि', 'à¤\85वरà¥\8dà¤\97à¥\80à¤\95à¥\83तसà¤\82à¤\9aिà¤\95ा', 'à¤\85वरà¥\8dà¤\97à¥\80à¤\95à¥\83तà¤\9aितà¥\8dरानि' ],
+       'Uncategorizedpages'        => [ 'à¤\85वरà¥\8dà¤\97à¥\80à¤\95à¥\83तपà¥\83षà¥\8dठानि', 'à¤\85वरà¥\8dà¤\97à¥\80à¤\95à¥\83तपà¥\83षà¥\8dà¤\9fानि' ],
        'Uncategorizedtemplates'    => [ 'अवर्गीकृतफलकानि' ],
-       'Undelete'                  => [ 'प्रत्यादिश्_परित्याग' ],
-       'Unlockdb'                  => [ 'विवृतविदाद्वारंतालक' ],
-       'Unusedcategories'          => [ 'अप्रयूक्तवर्ग' ],
-       'Unusedimages'              => [ 'अप्रयूक्तसंचिका' ],
-       'Unusedtemplates'           => [ 'अप्रयूक्तबिंबधर' ],
-       'Unwatchedpages'            => [ 'अनिरिक्षीतपृष्ठ' ],
-       'Upload'                    => [ 'भारंन्यस्यति' ],
-       'Userlogin'                 => [ 'सदस्यप्रवेशन' ],
-       'Userlogout'                => [ 'सदस्यबहिर्गमन' ],
-       'Userrights'                => [ 'योजकआधिकार' ],
-       'Version'                   => [ 'आवृत्ती' ],
-       'Wantedcategories'          => [ 'प्रार्थितवर्ग' ],
-       'Wantedfiles'               => [ 'प्रार्थितसंचिका' ],
-       'Wantedpages'               => [ 'प्रार्थितपृष्टानि' ],
-       'Wantedtemplates'           => [ 'प्रार्थितफलकानि' ],
-       'Watchlist'                 => [ 'निरीक्षा_सूची' ],
-       'Whatlinkshere'             => [ 'किमपृष्ठ_सम्बद्धंकरोति' ],
-       'Withoutinterwiki'          => [ 'आन्तरविकिहीन' ],
+       'Undelete'                  => [ 'पà¥\81नसà¥\8dसà¥\8dथापनमà¥\8d', 'पà¥\8dरतà¥\8dयादिशà¥\8d_परितà¥\8dयाà¤\97' ],
+       'Unlockdb'                  => [ 'दतà¥\8dताà¤\82शà¥\8bदà¥\8dà¤\98ाà¤\9fनमà¥\8d', 'विवà¥\83तविदादà¥\8dवारà¤\82तालà¤\95' ],
+       'Unusedcategories'          => [ 'à¤\85पà¥\8dरयà¥\81à¤\95à¥\8dतवरà¥\8dà¤\97ाà¤\83', 'à¤\85पà¥\8dरयà¥\82à¤\95à¥\8dतवरà¥\8dà¤\97' ],
+       'Unusedimages'              => [ 'à¤\85पà¥\8dरयà¥\81à¤\95à¥\8dतà¤\9aितà¥\8dराणि', 'à¤\85पà¥\8dरयà¥\82à¤\95à¥\8dतसà¤\82à¤\9aिà¤\95ा' ],
+       'Unusedtemplates'           => [ 'à¤\85पà¥\8dरयà¥\81à¤\95à¥\8dतफलà¤\95ानि', 'à¤\85पà¥\8dरयà¥\82à¤\95à¥\8dतबिà¤\82बधर' ],
+       'Unwatchedpages'            => [ 'à¤\85निरà¥\80à¤\95à¥\8dषितपà¥\83षà¥\8dठानि', 'à¤\85निरिà¤\95à¥\8dषà¥\80तपà¥\83षà¥\8dठ' ],
+       'Upload'                    => [ 'à¤\89पारà¥\8bपणमà¥\8d', 'भारà¤\82नà¥\8dयसà¥\8dयति' ],
+       'Userlogin'                 => [ 'सदसà¥\8dयपà¥\8dरवà¥\87शà¤\83', 'सदसà¥\8dयपà¥\8dरवà¥\87शन' ],
+       'Userlogout'                => [ 'सदसà¥\8dयनिरà¥\8dà¤\97मनमà¥\8d', 'सदसà¥\8dयबहिरà¥\8dà¤\97मन' ],
+       'Userrights'                => [ 'सदसà¥\8dयाधिà¤\95ाराà¤\83', 'यà¥\8bà¤\9cà¤\95à¤\86धिà¤\95ार' ],
+       'Version'                   => [ 'सà¤\82सà¥\8dà¤\95रणमà¥\8d', 'à¤\86वà¥\83तà¥\8dतà¥\80' ],
+       'Wantedcategories'          => [ 'वाà¤\9eà¥\8dà¤\9bितवरà¥\8dà¤\97ाà¤\83', 'पà¥\8dरारà¥\8dथितवरà¥\8dà¤\97' ],
+       'Wantedfiles'               => [ 'वाà¤\9eà¥\8dà¤\9bितसà¤\9eà¥\8dà¤\9aिà¤\95ाà¤\83', 'पà¥\8dरारà¥\8dथितसà¤\82à¤\9aिà¤\95ा' ],
+       'Wantedpages'               => [ 'वाà¤\9eà¥\8dà¤\9bितपà¥\83षà¥\8dठानि', 'पà¥\8dरारà¥\8dथितपà¥\83षà¥\8dà¤\9fानि' ],
+       'Wantedtemplates'           => [ 'वाà¤\9eà¥\8dà¤\9bितफलà¤\95ानि', 'पà¥\8dरारà¥\8dथितफलà¤\95ानि' ],
+       'Watchlist'                 => [ 'निरीक्षा_सूची', 'निरीक्षासूचिः' ],
+       'Whatlinkshere'             => [ 'à¤\95िमतà¥\8dर_सà¤\81लà¥\8dलà¤\97à¥\8dनमà¥\8d', 'à¤\95िमपà¥\83षà¥\8dठ_समà¥\8dबदà¥\8dधà¤\82à¤\95रà¥\8bति' ],
+       'Withoutinterwiki'          => [ 'à¤\85नà¥\8dतरà¥\8dविà¤\95िपरिसनà¥\8dधिहà¥\80नमà¥\8d', 'à¤\86नà¥\8dतरविà¤\95िहà¥\80न' ],
 ];
 
 $magicWords = [
index d88d5e9..0670454 100644 (file)
@@ -187,13 +187,7 @@ TEXT
                                }
                                # cl_type will be wrong for lots of pages if cl_collation is 0,
                                # so let's update it while we're here.
-                               if ( $title->getNamespace() == NS_CATEGORY ) {
-                                       $type = 'subcat';
-                               } elseif ( $title->getNamespace() == NS_FILE ) {
-                                       $type = 'file';
-                               } else {
-                                       $type = 'page';
-                               }
+                               $type = MWNamespace::getCategoryLinkType( $title->getNamespace() );
                                $newSortKey = $collation->getSortKey(
                                        $title->getCategorySortkey( $prefix ) );
                                if ( $verboseStats ) {
index d0c52d8..cafc1bc 100644 (file)
@@ -706,12 +706,6 @@ return [
                'group' => 'jquery.ui',
        ],
 
-       /* json2 */
-       'json' => [
-               'deprecated' => 'Use of the "json" module is deprecated since MediaWiki 1.29.0',
-               'targets' => [ 'desktop', 'mobile' ],
-       ],
-
        /* Moment.js */
 
        'moment' => [
index 7d4ed53..d38adcd 100644 (file)
         * @inheritdoc
         */
        mw.ForeignStructuredUpload.BookletLayout.prototype.getText = function () {
-               var language = mw.config.get( 'wgContentLanguage' );
+               var language = mw.config.get( 'wgContentLanguage' ),
+                       categories = this.categoriesWidget.getItems().map( function ( item ) {
+                               return item.data;
+                       } );
                this.upload.clearDescriptions();
                this.upload.addDescription( language, this.descriptionWidget.getValue() );
                this.upload.setDate( this.dateWidget.getValue() );
                this.upload.clearCategories();
-               this.upload.addCategories( this.categoriesWidget.getItemsData() );
+               this.upload.addCategories( categories );
                return this.upload.getText();
        };
 
                mw.ForeignStructuredUpload.BookletLayout.parent.prototype.clear.call( this );
 
                this.ownWorkCheckbox.setSelected( false );
-               this.categoriesWidget.setItemsFromData( [] );
+               this.categoriesWidget.setValue( [] );
                this.dateWidget.setValue( '' ).setValidityFlag( true );
        };
 
index 7721275..284d338 100644 (file)
                                border: 1px solid @colorGray10;
                                border-left-width: 0;
                                border-radius: 0 0 @borderRadius 0;
+                               // Using the 'left' value from
+                               // .oo-ui-buttonElement-frameless.oo-ui-iconElement >
+                               // .oo-ui-buttonElement-button > .oo-ui-iconElement-icon
+                               padding-right: 0.35714286em;
 
                                display: block;
                                text-align: right;
index 907c535..c7db7c6 100644 (file)
         * @inheritdoc
         */
        mw.rcfilters.ui.FilterTagMultiselectWidget.prototype.onChangeTags = function () {
-               // Parent method
-               mw.rcfilters.ui.FilterTagMultiselectWidget.parent.prototype.onChangeTags.call( this );
+               // If initialized, call parent method.
+               if ( this.controller.isInitialized() ) {
+                       mw.rcfilters.ui.FilterTagMultiselectWidget.parent.prototype.onChangeTags.call( this );
+               }
 
                this.emptyFilterMessage.toggle( this.isEmpty() );
        };
index 65860ea..1b37ec3 100644 (file)
@@ -54,3 +54,9 @@
 .mw-changeslist-legend.mw-collapsed + h4 + div > table.mw-changeslist-line:first-child {
        clear: right;
 }
+
+/* Hide RCFilters highlight containers if RCFilters is not enabled.
+   This is overridden in mw.ui.rcfilters.ChangesListWrapperWidget.less if RCFilters is enabled. */
+.mw-rcfilters-ui-highlights {
+       display: none;
+}
index 15e2def..1b91a87 100644 (file)
@@ -575,4 +575,34 @@ class MWNamespaceTest extends MediaWikiTestCase {
        private function assertDifferentSubject( $ns1, $ns2, $msg = '' ) {
                $this->assertFalse( MWNamespace::subjectEquals( $ns1, $ns2 ), $msg );
        }
+
+       public function provideGetCategoryLinkType() {
+               return [
+                       [ NS_MAIN, 'page' ],
+                       [ NS_TALK, 'page' ],
+                       [ NS_USER, 'page' ],
+                       [ NS_USER_TALK, 'page' ],
+
+                       [ NS_FILE, 'file' ],
+                       [ NS_FILE_TALK, 'page' ],
+
+                       [ NS_CATEGORY, 'subcat' ],
+                       [ NS_CATEGORY_TALK, 'page' ],
+
+                       [ 100, 'page' ],
+                       [ 101, 'page' ],
+               ];
+       }
+
+       /**
+        * @dataProvider provideGetCategoryLinkType
+        * @covers MWNamespace::getCategoryLinkType
+        *
+        * @param int $index
+        * @param string $expected
+        */
+       public function testGetCategoryLinkType( $index, $expected ) {
+               $actual = MWNamespace::getCategoryLinkType( $index );
+               $this->assertSame( $expected, $actual, "NS $index" );
+       }
 }
index 93c7ed3..cf48215 100644 (file)
@@ -5,6 +5,7 @@ use MediaWiki\Interwiki\InterwikiLookup;
 use MediaWiki\Linker\LinkRenderer;
 use MediaWiki\Linker\LinkRendererFactory;
 use MediaWiki\MediaWikiServices;
+use MediaWiki\Preferences\PreferencesFactory;
 use MediaWiki\Services\DestructibleService;
 use MediaWiki\Services\SalvageableService;
 use MediaWiki\Services\ServiceDisabledException;
@@ -12,8 +13,10 @@ use MediaWiki\Shell\CommandFactory;
 use MediaWiki\Storage\BlobStore;
 use MediaWiki\Storage\BlobStoreFactory;
 use MediaWiki\Storage\NameTableStore;
+use MediaWiki\Storage\RevisionFactory;
 use MediaWiki\Storage\RevisionLookup;
 use MediaWiki\Storage\RevisionStore;
+use MediaWiki\Storage\RevisionStoreFactory;
 use MediaWiki\Storage\SqlBlobStore;
 
 /**
@@ -305,8 +308,6 @@ class MediaWikiServicesTest extends MediaWikiTestCase {
 
        public function provideGetService() {
                // NOTE: This should list all service getters defined in ServiceWiring.php.
-               // NOTE: For every test case defined here there should be a corresponding
-               // test case defined in provideGetters().
                return [
                        'BootstrapConfig' => [ 'BootstrapConfig', Config::class ],
                        'ConfigFactory' => [ 'ConfigFactory', ConfigFactory::class ],
@@ -346,10 +347,23 @@ class MediaWikiServicesTest extends MediaWikiTestCase {
                        'BlobStore' => [ 'BlobStore', BlobStore::class ],
                        '_SqlBlobStore' => [ '_SqlBlobStore', SqlBlobStore::class ],
                        'RevisionStore' => [ 'RevisionStore', RevisionStore::class ],
+                       'RevisionStoreFactory' => [ 'RevisionStoreFactory', RevisionStoreFactory::class ],
                        'RevisionLookup' => [ 'RevisionLookup', RevisionLookup::class ],
+                       'RevisionFactory' => [ 'RevisionFactory', RevisionFactory::class ],
+                       'ContentModelStore' => [ 'ContentModelStore', NameTableStore::class ],
+                       'SlotRoleStore' => [ 'SlotRoleStore', NameTableStore::class ],
                        'HttpRequestFactory' => [ 'HttpRequestFactory', HttpRequestFactory::class ],
                        'CommentStore' => [ 'CommentStore', CommentStore::class ],
                        'ChangeTagDefStore' => [ 'ChangeTagDefStore', NameTableStore::class ],
+                       'ConfiguredReadOnlyMode' => [ 'ConfiguredReadOnlyMode', ConfiguredReadOnlyMode::class ],
+                       'ReadOnlyMode' => [ 'ReadOnlyMode', ReadOnlyMode::class ],
+                       'UploadRevisionImporter' => [ 'UploadRevisionImporter', UploadRevisionImporter::class ],
+                       'OldRevisionImporter' => [ 'OldRevisionImporter', OldRevisionImporter::class ],
+                       'WikiRevisionOldRevisionImporterNoUpdates' =>
+                               [ 'WikiRevisionOldRevisionImporterNoUpdates', ImportableOldRevisionImporter::class ],
+                       'ExternalStoreFactory' => [ 'ExternalStoreFactory', ExternalStoreFactory::class ],
+                       'PreferencesFactory' => [ 'PreferencesFactory', PreferencesFactory::class ],
+                       'ActorMigration' => [ 'ActorMigration', ActorMigration::class ],
                ];
        }
 
@@ -378,4 +392,15 @@ class MediaWikiServicesTest extends MediaWikiTestCase {
                }
        }
 
+       public function testDefaultServiceWiringServicesHaveTests() {
+               global $IP;
+               $testedServices = array_keys( $this->provideGetService() );
+               $allServices = array_keys( include $IP . '/includes/ServiceWiring.php' );
+               $this->assertEquals(
+                       [],
+                       array_diff( $allServices, $testedServices ),
+                       'The following services have not been added to MediaWikiServicesTest::provideGetService'
+               );
+       }
+
 }
diff --git a/tests/phpunit/includes/Storage/RevisionStoreFactoryTest.php b/tests/phpunit/includes/Storage/RevisionStoreFactoryTest.php
new file mode 100644 (file)
index 0000000..a5c18ac
--- /dev/null
@@ -0,0 +1,131 @@
+<?php
+
+namespace MediaWiki\Tests\Storage;
+
+use ActorMigration;
+use CommentStore;
+use MediaWiki\Logger\LoggerFactory;
+use MediaWiki\Storage\NameTableStore;
+use MediaWiki\Storage\RevisionStore;
+use MediaWiki\Storage\RevisionStoreFactory;
+use MediaWiki\Storage\SqlBlobStore;
+use MediaWikiTestCase;
+use WANObjectCache;
+use Wikimedia\Rdbms\LoadBalancer;
+use Wikimedia\TestingAccessWrapper;
+
+class RevisionStoreFactoryTest extends MediaWikiTestCase {
+
+       public function testValidConstruction_doesntCauseErrors() {
+               new RevisionStoreFactory(
+                       $this->getMockLoadBalancer(),
+                       $this->getMockSqlBlobStore(),
+                       $this->getHashWANObjectCache(),
+                       $this->getMockCommentStore(),
+                       $this->getMockNameTableStore(),
+                       $this->getMockNameTableStore(),
+                       MIGRATION_OLD,
+                       ActorMigration::newMigration(),
+                       LoggerFactory::getInstance( 'someInstance' ),
+                       true
+               );
+               $this->assertTrue( true );
+       }
+
+       public function provideWikiIds() {
+               yield [ true ];
+               yield [ false ];
+               yield [ 'somewiki' ];
+               yield [ 'somewiki', MIGRATION_OLD , false ];
+               yield [ 'somewiki', MIGRATION_NEW , true ];
+       }
+
+       /**
+        * @dataProvider provideWikiIds
+        */
+       public function testGetRevisionStore(
+               $wikiId,
+               $mcrMigrationStage = MIGRATION_OLD,
+               $contentHandlerUseDb = true
+       ) {
+               $lb = $this->getMockLoadBalancer();
+               $blobStore = $this->getMockSqlBlobStore();
+               $cache = $this->getHashWANObjectCache();
+               $commentStore = $this->getMockCommentStore();
+               $contentModelStore = $this->getMockNameTableStore();
+               $slotRoleStore = $this->getMockNameTableStore();
+               $actorMigration = ActorMigration::newMigration();
+               $logger = LoggerFactory::getInstance( 'someInstance' );
+
+               $factory = new RevisionStoreFactory(
+                       $lb,
+                       $blobStore,
+                       $cache,
+                       $commentStore,
+                       $contentModelStore,
+                       $slotRoleStore,
+                       $mcrMigrationStage,
+                       $actorMigration,
+                       $logger,
+                       $contentHandlerUseDb
+               );
+
+               $store = $factory->getRevisionStore( $wikiId );
+               $wrapper = TestingAccessWrapper::newFromObject( $store );
+
+               // ensure the correct object type is returned
+               $this->assertInstanceOf( RevisionStore::class, $store );
+
+               // ensure the RevisionStore is for the given wikiId
+               $this->assertSame( $wikiId, $wrapper->wikiId );
+
+               // ensure all other required services are correctly set
+               $this->assertSame( $lb, $wrapper->loadBalancer );
+               $this->assertSame( $blobStore, $wrapper->blobStore );
+               $this->assertSame( $cache, $wrapper->cache );
+               $this->assertSame( $commentStore, $wrapper->commentStore );
+               $this->assertSame( $contentModelStore, $wrapper->contentModelStore );
+               $this->assertSame( $slotRoleStore, $wrapper->slotRoleStore );
+               $this->assertSame( $mcrMigrationStage, $wrapper->mcrMigrationStage );
+               $this->assertSame( $actorMigration, $wrapper->actorMigration );
+               $this->assertSame( $logger, $wrapper->logger );
+               $this->assertSame( $contentHandlerUseDb, $store->getContentHandlerUseDB() );
+       }
+
+       /**
+        * @return \PHPUnit_Framework_MockObject_MockObject|NameTableStore
+        */
+       private function getMockNameTableStore() {
+               return $this->getMockBuilder( NameTableStore::class )
+                       ->disableOriginalConstructor()->getMock();
+       }
+
+       /**
+        * @return \PHPUnit_Framework_MockObject_MockObject|LoadBalancer
+        */
+       private function getMockLoadBalancer() {
+               return $this->getMockBuilder( LoadBalancer::class )
+                       ->disableOriginalConstructor()->getMock();
+       }
+
+       /**
+        * @return \PHPUnit_Framework_MockObject_MockObject|SqlBlobStore
+        */
+       private function getMockSqlBlobStore() {
+               return $this->getMockBuilder( SqlBlobStore::class )
+                       ->disableOriginalConstructor()->getMock();
+       }
+
+       /**
+        * @return \PHPUnit_Framework_MockObject_MockObject|CommentStore
+        */
+       private function getMockCommentStore() {
+               return $this->getMockBuilder( CommentStore::class )
+                       ->disableOriginalConstructor()->getMock();
+       }
+
+       private function getHashWANObjectCache() {
+               return new WANObjectCache( [ 'cache' => new \HashBagOStuff() ] );
+       }
+
+}
index 2a962b7..79f7b96 100644 (file)
@@ -11,11 +11,14 @@ class MapCacheLRUTest extends PHPUnit\Framework\TestCase {
         * @covers MapCacheLRU::toArray()
         * @covers MapCacheLRU::getAllKeys()
         * @covers MapCacheLRU::clear()
+        * @covers MapCacheLRU::getMaxSize()
+        * @covers MapCacheLRU::setMaxSize()
         */
        function testArrayConversion() {
                $raw = [ 'd' => 4, 'c' => 3, 'b' => 2, 'a' => 1 ];
                $cache = MapCacheLRU::newFromArray( $raw, 3 );
 
+               $this->assertEquals( 3, $cache->getMaxSize() );
                $this->assertSame( true, $cache->has( 'a' ) );
                $this->assertSame( true, $cache->has( 'b' ) );
                $this->assertSame( true, $cache->has( 'c' ) );
@@ -43,6 +46,27 @@ class MapCacheLRUTest extends PHPUnit\Framework\TestCase {
                        [],
                        $cache->toArray()
                );
+
+               $cache = MapCacheLRU::newFromArray( [ 'd' => 4, 'c' => 3, 'b' => 2, 'a' => 1 ], 4 );
+               $cache->setMaxSize( 3 );
+               $this->assertSame(
+                       [ 'c' => 3, 'b' => 2, 'a' => 1 ],
+                       $cache->toArray()
+               );
+       }
+
+       /**
+        * @covers MapCacheLRU::serialize()
+        * @covers MapCacheLRU::unserialize()
+        */
+       function testSerialize() {
+               $cache = MapCacheLRU::newFromArray( [ 'd' => 4, 'c' => 3, 'b' => 2, 'a' => 1 ], 10 );
+               $string = serialize( $cache );
+               $ncache = unserialize( $string );
+               $this->assertSame(
+                       [ 'd' => 4, 'c' => 3, 'b' => 2, 'a' => 1 ],
+                       $ncache->toArray()
+               );
        }
 
        /**
@@ -114,4 +138,75 @@ class MapCacheLRUTest extends PHPUnit\Framework\TestCase {
                        $cache->toArray()
                );
        }
+
+       /**
+        * @covers MapCacheLRU::has()
+        * @covers MapCacheLRU::get()
+        * @covers MapCacheLRU::set()
+        */
+       public function testExpiry() {
+               $raw = [ 'a' => 1, 'b' => 2, 'c' => 3 ];
+               $cache = MapCacheLRU::newFromArray( $raw, 3 );
+
+               $now = microtime( true );
+               $cache->setMockTime( $now );
+
+               $cache->set( 'd', 'xxx' );
+               $this->assertTrue( $cache->has( 'd', 30 ) );
+               $this->assertEquals( 'xxx', $cache->get( 'd' ) );
+
+               $now += 29;
+               $this->assertTrue( $cache->has( 'd', 30 ) );
+               $this->assertEquals( 'xxx', $cache->get( 'd' ) );
+
+               $now += 1.5;
+               $this->assertFalse( $cache->has( 'd', 30 ) );
+               $this->assertEquals( 'xxx', $cache->get( 'd' ) );
+       }
+
+       /**
+        * @covers MapCacheLRU::hasField()
+        * @covers MapCacheLRU::getField()
+        * @covers MapCacheLRU::setField()
+        */
+       public function testFields() {
+               $raw = [ 'a' => 1, 'b' => 2, 'c' => 3 ];
+               $cache = MapCacheLRU::newFromArray( $raw, 3 );
+
+               $now = microtime( true );
+               $cache->setMockTime( $now );
+
+               $cache->setField( 'PMs', 'Tony Blair', 'Labour' );
+               $cache->setField( 'PMs', 'Margaret Thatcher', 'Tory' );
+               $this->assertTrue( $cache->hasField( 'PMs', 'Tony Blair', 30 ) );
+               $this->assertEquals( 'Labour', $cache->getField( 'PMs', 'Tony Blair' ) );
+
+               $now += 29;
+               $this->assertTrue( $cache->hasField( 'PMs', 'Tony Blair', 30 ) );
+               $this->assertEquals( 'Labour', $cache->getField( 'PMs', 'Tony Blair' ) );
+
+               $now += 1.5;
+               $this->assertFalse( $cache->hasField( 'PMs', 'Tony Blair', 30 ) );
+               $this->assertEquals( 'Labour', $cache->getField( 'PMs', 'Tony Blair' ) );
+
+               $this->assertEquals(
+                       [ 'Tony Blair' => 'Labour', 'Margaret Thatcher' => 'Tory' ],
+                       $cache->get( 'PMs' )
+               );
+
+               $cache->set( 'MPs', [
+                       'Edwina Currie' => 1983,
+                       'Neil Kinnock' => 1970
+               ] );
+               $this->assertEquals(
+                       [
+                               'Edwina Currie' => 1983,
+                               'Neil Kinnock' => 1970
+                       ],
+                       $cache->get( 'MPs' )
+               );
+
+               $this->assertEquals( 1983, $cache->getField( 'MPs', 'Edwina Currie' ) );
+               $this->assertEquals( 1970, $cache->getField( 'MPs', 'Neil Kinnock' ) );
+       }
 }
index c8940e5..c9fa320 100644 (file)
@@ -18,7 +18,7 @@ class ProcessCacheLRUTest extends PHPUnit\Framework\TestCase {
         * Compare against an array so we get the cache content difference.
         */
        protected function assertCacheEmpty( $cache, $msg = 'Cache should be empty' ) {
-               $this->assertAttributeEquals( [], 'cache', $cache, $msg );
+               $this->assertEquals( 0, $cache->getEntriesCount(), $msg );
        }
 
        /**
@@ -256,13 +256,11 @@ class ProcessCacheLRUTest extends PHPUnit\Framework\TestCase {
  * Overrides some ProcessCacheLRU methods and properties accessibility.
  */
 class ProcessCacheLRUTestable extends ProcessCacheLRU {
-       public $cache = [];
-
        public function getCache() {
-               return $this->cache;
+               return $this->cache->toArray();
        }
 
        public function getEntriesCount() {
-               return count( $this->cache );
+               return count( $this->cache->toArray() );
        }
 }
index 4a9f6cc..8a95ae7 100644 (file)
@@ -137,4 +137,13 @@ class MultiWriteBagOStuffTest extends MediaWikiTestCase {
 
                $this->assertSame( 'special', $cache->makeGlobalKey( 'a', 'b' ) );
        }
+
+       public function testDuplicateStoreAdd() {
+               $bag = new HashBagOStuff();
+               $cache = new MultiWriteBagOStuff( [
+                       'caches' => [ $bag, $bag ],
+               ] );
+
+               $this->assertTrue( $cache->add( 'key', 1, 30 ) );
+       }
 }
index 63cf02f..e0364c4 100644 (file)
@@ -1,5 +1,6 @@
 <?php
 
+use MediaWiki\MediaWikiServices;
 use MediaWiki\Storage\RevisionSlotsUpdate;
 use Wikimedia\TestingAccessWrapper;
 
@@ -1028,6 +1029,9 @@ more stuff
                // Use the confirmed group for user2 to make sure the user is different
                $user2 = $this->getTestUser( [ 'confirmed' ] )->getUser();
 
+               // make sure we can test autopatrolling
+               $this->setMwGlobals( 'wgUseRCPatrol', true );
+
                // TODO: MCR: test rollback of multiple slots!
                $page = $this->newPage( __METHOD__ );
 
@@ -1085,61 +1089,21 @@ more stuff
                        "rollback did not revert to the correct revision" );
                $this->assertEquals( "one\n\ntwo", $page->getContent()->getNativeData() );
 
-               // TODO: MCR: assert origin once we write slot data
-               // $mainSlot = $page->getRevision()->getRevisionRecord()->getSlot( 'main' );
-               // $this->assertTrue( $mainSlot->isInherited(), 'isInherited' );
-               // $this->assertSame( $rev2->getId(), $mainSlot->getOrigin(), 'getOrigin' );
-       }
-
-       /**
-        * @covers WikiPage::doRollback
-        * @covers WikiPage::commitRollback
-        */
-       public function testDoRollback_simple() {
-               $admin = $this->getTestSysop()->getUser();
-
-               $text = "one";
-               $page = $this->newPage( __METHOD__ );
-               $page->doEditContent(
-                       ContentHandler::makeContent( $text, $page->getTitle(), CONTENT_MODEL_WIKITEXT ),
-                       "section one",
-                       EDIT_NEW,
-                       false,
-                       $admin
-               );
-               $rev1 = $page->getRevision();
-
-               $user1 = $this->getTestUser()->getUser();
-               $text .= "\n\ntwo";
-               $page = new WikiPage( $page->getTitle() );
-               $page->doEditContent(
-                       ContentHandler::makeContent( $text, $page->getTitle(), CONTENT_MODEL_WIKITEXT ),
-                       "adding section two",
-                       0,
-                       false,
-                       $user1
+               $rc = MediaWikiServices::getInstance()->getRevisionStore()->getRecentChange(
+                       $page->getRevision()->getRevisionRecord()
                );
 
-               # now, try the rollback
-               $token = $admin->getEditToken( 'rollback' );
-               $errors = $page->doRollback(
-                       $user1->getName(),
-                       "testing revert",
-                       $token,
-                       false,
-                       $details,
-                       $admin
+               $this->assertNotNull( $rc, 'RecentChanges entry' );
+               $this->assertEquals(
+                       RecentChange::PRC_AUTOPATROLLED,
+                       $rc->getAttribute( 'rc_patrolled' ),
+                       'rc_patrolled'
                );
 
-               if ( $errors ) {
-                       $this->fail( "Rollback failed:\n" . print_r( $errors, true )
-                               . ";\n" . print_r( $details, true ) );
-               }
-
-               $page = new WikiPage( $page->getTitle() );
-               $this->assertEquals( $rev1->getSha1(), $page->getRevision()->getSha1(),
-                       "rollback did not revert to the correct revision" );
-               $this->assertEquals( "one", $page->getContent()->getNativeData() );
+               // TODO: MCR: assert origin once we write slot data
+               // $mainSlot = $page->getRevision()->getRevisionRecord()->getSlot( 'main' );
+               // $this->assertTrue( $mainSlot->isInherited(), 'isInherited' );
+               // $this->assertSame( $rev2->getId(), $mainSlot->getOrigin(), 'getOrigin' );
        }
 
        /**