Merge "Replace call_user_func_array(), part 2"
authorjenkins-bot <jenkins-bot@gerrit.wikimedia.org>
Sat, 9 Jun 2018 14:25:26 +0000 (14:25 +0000)
committerGerrit Code Review <gerrit@wikimedia.org>
Sat, 9 Jun 2018 14:25:26 +0000 (14:25 +0000)
47 files changed:
.travis.yml
RELEASE-NOTES-1.31
includes/DummyLinker.php
includes/GlobalFunctions.php
includes/Linker.php
includes/Message.php
includes/MovePage.php
includes/Xml.php
includes/http/CurlHttpRequest.php
includes/interwiki/Interwiki.php
includes/libs/HashRing.php
includes/libs/rdbms/ChronologyProtector.php
includes/linker/LinkRenderer.php
includes/poolcounter/PoolCounterRedis.php
includes/specials/SpecialPrefixindex.php
includes/specials/SpecialProtectedpages.php
includes/specials/SpecialProtectedtitles.php
includes/specials/pagers/ProtectedPagesPager.php
includes/specials/pagers/ProtectedTitlesPager.php
languages/Language.php
languages/data/CrhExceptions.php
languages/i18n/bg.json
languages/i18n/bn.json
languages/i18n/cu.json
languages/i18n/fa.json
languages/i18n/gor.json
languages/i18n/he.json
languages/i18n/hu.json
languages/i18n/inh.json
languages/i18n/lfn.json
languages/i18n/nap.json
languages/i18n/oc.json
languages/i18n/pa.json
languages/i18n/pms.json
languages/i18n/ru.json
languages/i18n/skr-arab.json
languages/i18n/sq.json
languages/i18n/sw.json
languages/i18n/ta.json
languages/i18n/to.json
languages/i18n/wa.json
languages/i18n/zh-hans.json
maintenance/populateInterwiki.php
tests/phpunit/includes/interwiki/InterwikiTest.php
tests/phpunit/includes/libs/HashRingTest.php
tests/phpunit/includes/libs/IEUrlExtensionTest.php
tests/phpunit/languages/classes/LanguageCrhTest.php

index 73e4af5..e15fc55 100644 (file)
@@ -37,6 +37,9 @@ matrix:
       php: hhvm-3.21
     - env: dbtype=mysql dbuser=root
       php: hhvm-3.18
+  allow_failures:
+    - php: hhvm-3.24
+    - php: hhvm-3.21
 
 services:
   - mysql
index c98f663..ade45b0 100644 (file)
@@ -11,6 +11,8 @@ production.
 * (T196185) Don't allow setting $wgDBmysql5 in the installer.
 * (T196125) php-memcached 3.0 (provided with PHP 7.0) is now supported.
 * (T182366) UploadBase::checkXMLEncodingMissmatch() now works on PHP 7.1+
+* (T118683) Fix exception from &$user deref on HHVM in the TitleMoveComplete hook.
+* (T196672) The mtime of extension.json files is now able to be zero
 
 === Changes since MediaWiki 1.31.0-rc.0 ===
 * (T33223) Drop archive.ar_text and ar_flags.
index 9aa6aeb..7958420 100644 (file)
@@ -107,7 +107,7 @@ class DummyLinker {
                Title $title,
                $file,
                $label = '',
-               $alt,
+               $alt = '',
                $align = 'right',
                $params = [],
                $framed = false,
index 6b4e4ee..335451e 100644 (file)
@@ -1336,7 +1336,7 @@ function wfGetLangObj( $langcode = false ) {
  * This function replaces all old wfMsg* functions.
  *
  * @param string|string[]|MessageSpecifier $key Message key, or array of keys, or a MessageSpecifier
- * @param string ...$params Normal message parameters
+ * @param string|string[] ...$params Normal message parameters
  * @return Message
  *
  * @since 1.17
@@ -1359,7 +1359,7 @@ function wfMessage( $key, ...$params ) {
  * for the first message which is non-empty. If all messages are empty then an
  * instance of the first message key is returned.
  *
- * @param string|string[] ...$keys Message keys
+ * @param string ...$keys Message keys
  * @return Message
  *
  * @since 1.18
index 3ee442d..6634127 100644 (file)
@@ -504,7 +504,7 @@ class Linker {
         * @param string $manualthumb
         * @return string
         */
-       public static function makeThumbLinkObj( Title $title, $file, $label = '', $alt,
+       public static function makeThumbLinkObj( Title $title, $file, $label = '', $alt = '',
                $align = 'right', $params = [], $framed = false, $manualthumb = ""
        ) {
                $frameParams = [
index fb6dcc5..84ab7ca 100644 (file)
@@ -1128,7 +1128,7 @@ class Message implements MessageSpecifier, Serializable {
         *
         * @return string
         */
-       protected function replaceParameters( $message, $type = 'before', $format ) {
+       protected function replaceParameters( $message, $type, $format ) {
                // A temporary marker for $1 parameters that is only valid
                // in non-attribute contexts. However if the entire message is escaped
                // then we don't want to use it because it will be mangled in all contexts
index 3210ba8..614ea7d 100644 (file)
@@ -415,7 +415,9 @@ class MovePage {
                        new AtomicSectionUpdate(
                                $dbw,
                                __METHOD__,
-                               function () use ( $params ) {
+                               // Hold onto $user to avoid HHVM bug where it no longer
+                               // becomes a reference (T118683)
+                               function () use ( $params, &$user ) {
                                        Hooks::run( 'TitleMoveComplete', $params );
                                }
                        )
index 4f2720e..af38740 100644 (file)
@@ -124,11 +124,11 @@ class Xml {
         * content you have is already valid xml.
         *
         * @param string $element Element name
-        * @param array $attribs Array of attributes
+        * @param array|null $attribs Array of attributes
         * @param string $contents Content of the element
         * @return string
         */
-       public static function tags( $element, $attribs = null, $contents ) {
+       public static function tags( $element, $attribs, $contents ) {
                return self::openElement( $element, $attribs ) . $contents . "</$element>";
        }
 
index a8fbed0..f457b21 100644 (file)
@@ -149,13 +149,6 @@ class CurlHttpRequest extends MWHttpRequest {
                        return false;
                }
 
-               if ( version_compare( PHP_VERSION, '5.6.0', '<' ) ) {
-                       if ( strval( ini_get( 'open_basedir' ) ) !== '' ) {
-                               $this->logger->debug( "Cannot follow redirects when open_basedir is set\n" );
-                               return false;
-                       }
-               }
-
                return true;
        }
 }
index 657849a..e6a943d 100644 (file)
@@ -66,6 +66,7 @@ class Interwiki {
         * @return bool Whether it exists
         */
        public static function isValidInterwiki( $prefix ) {
+               wfDeprecated( __METHOD__, '1.28' );
                return MediaWikiServices::getInstance()->getInterwikiLookup()->isValidInterwiki( $prefix );
        }
 
@@ -78,6 +79,7 @@ class Interwiki {
         * @return Interwiki|null|bool
         */
        public static function fetch( $prefix ) {
+               wfDeprecated( __METHOD__, '1.28' );
                return MediaWikiServices::getInstance()->getInterwikiLookup()->fetch( $prefix );
        }
 
@@ -88,6 +90,7 @@ class Interwiki {
         * @since 1.26
         */
        public static function invalidateCache( $prefix ) {
+               wfDeprecated( __METHOD__, '1.28' );
                MediaWikiServices::getInstance()->getInterwikiLookup()->invalidateCache( $prefix );
        }
 
@@ -101,6 +104,7 @@ class Interwiki {
         * @since 1.19
         */
        public static function getAllPrefixes( $local = null ) {
+               wfDeprecated( __METHOD__, '1.28' );
                return MediaWikiServices::getInstance()->getInterwikiLookup()->getAllPrefixes( $local );
        }
 
index 3b9c24d..251fa88 100644 (file)
 /**
  * Convenience class for weighted consistent hash rings
  *
+ * This deterministically maps "keys" to a set of "locations" while avoiding clumping
+ *
+ * Each location is represented by a number of nodes on a ring proportionate to the ratio
+ * of its weight compared to the total location weight. Note positions are deterministically
+ * derived from the hash of the location name. Nodes are responsible for the portion of the
+ * ring, counter-clockwise, up until the next node. Locations are responsible for all portions
+ * of the ring that the location's nodes are responsible for.
+ *
+ * A location that is temporarily "ejected" is said to be absent from the "live" ring.
+ * If no location ejections are active, then the base ring and live ring are identical.
+ *
  * @since 1.22
  */
-class HashRing {
-       /** @var array (location => weight) */
-       protected $sourceMap = [];
-       /** @var array (location => (start, end)) */
-       protected $ring = [];
+class HashRing implements Serializable {
+       /** @var string Hashing algorithm for hash() */
+       protected $algo;
+       /** @var int[] Non-empty (location => integer weight) */
+       protected $weightByLocation;
+       /** @var int[] Map of (location => UNIX timestamp) */
+       protected $ejectExpiryByLocation;
 
-       /** @var HashRing|null */
+       /** @var array[] Non-empty list of (float, node name, location name) */
+       protected $baseRing;
+       /** @var array[] Non-empty list of (float, node name, location name) */
        protected $liveRing;
-       /** @var array (location => UNIX timestamp) */
-       protected $ejectionExpiries = [];
-       /** @var int UNIX timestamp */
-       protected $ejectionNextExpiry = INF;
 
-       const RING_SIZE = 268435456; // 2^28
+       /** @var float Number of positions on the ring */
+       const RING_SIZE = 4294967296.0; // 2^32
+       /** @var integer Overall number of node groups per server */
+       const HASHES_PER_LOCATION = 40;
+       /** @var integer Number of nodes in a node group */
+       const SECTORS_PER_HASH = 4;
+
+       const KEY_POS = 0;
+       const KEY_LOCATION = 1;
+
+       /** @var int Consider all locations */
+       const RING_ALL = 0;
+       /** @var int Only consider "live" locations */
+       const RING_LIVE = 1;
 
        /**
-        * @param array $map (location => weight)
+        * Make a consistent hash ring given a set of locations and their weight values
+        *
+        * @param int[] $map Map of (location => weight)
+        * @param string $algo Hashing algorithm listed in hash_algos() [optional]
+        * @param int[] $ejections Map of (location => UNIX timestamp) for ejection expiries
+        * @since 1.31
         */
-       public function __construct( array $map ) {
-               $map = array_filter( $map, function ( $w ) {
-                       return $w > 0;
-               } );
-               if ( !count( $map ) ) {
-                       throw new UnexpectedValueException( "Ring is empty or all weights are zero." );
-               }
-               $this->sourceMap = $map;
-               // Sort the locations based on the hash of their names
-               $hashes = [];
-               foreach ( $map as $location => $weight ) {
-                       $hashes[$location] = sha1( $location );
-               }
-               uksort( $map, function ( $a, $b ) use ( $hashes ) {
-                       return strcmp( $hashes[$a], $hashes[$b] );
-               } );
-               // Fit the map to weight-proportionate one with a space of size RING_SIZE
-               $sum = array_sum( $map );
-               $standardMap = [];
-               foreach ( $map as $location => $weight ) {
-                       $standardMap[$location] = (int)floor( $weight / $sum * self::RING_SIZE );
+       public function __construct( array $map, $algo = 'sha1', array $ejections = [] ) {
+               $this->init( $map, $algo, $ejections );
+       }
+
+       /**
+        * @param int[] $map Map of (location => integer)
+        * @param string $algo Hashing algorithm
+        * @param int[] $ejections Map of (location => UNIX timestamp) for ejection expires
+        */
+       protected function init( array $map, $algo, array $ejections ) {
+               if ( !in_array( $algo, hash_algos(), true ) ) {
+                       throw new RuntimeException( __METHOD__ . ": unsupported '$algo' hash algorithm." );
                }
-               // Build a ring of RING_SIZE spots, with each location at a spot in location hash order
-               $index = 0;
-               foreach ( $standardMap as $location => $weight ) {
-                       // Location covers half-closed interval [$index,$index + $weight)
-                       $this->ring[$location] = [ $index, $index + $weight ];
-                       $index += $weight;
+
+               $weightByLocation = array_filter( $map );
+               if ( $weightByLocation === [] ) {
+                       throw new UnexpectedValueException( "No locations with non-zero weight." );
+               } elseif ( min( $map ) < 0 ) {
+                       throw new InvalidArgumentException( "Location weight cannot be negative." );
                }
-               // Make sure the last location covers what is left
-               end( $this->ring );
-               $this->ring[key( $this->ring )][1] = self::RING_SIZE;
+
+               $this->algo = $algo;
+               $this->weightByLocation = $weightByLocation;
+               $this->ejectExpiryByLocation = $ejections;
+               $this->baseRing = $this->buildLocationRing( $this->weightByLocation, $this->algo );
        }
 
        /**
@@ -82,11 +104,10 @@ class HashRing {
         *
         * @param string $item
         * @return string Location
+        * @throws UnexpectedValueException
         */
        final public function getLocation( $item ) {
-               $locations = $this->getLocations( $item, 1 );
-
-               return $locations[0];
+               return $this->getLocations( $item, 1 )[0];
        }
 
        /**
@@ -94,46 +115,83 @@ class HashRing {
         *
         * @param string $item
         * @param int $limit Maximum number of locations to return
-        * @return array List of locations
+        * @param int $from One of the RING_* class constants
+        * @return string[] List of locations
+        * @throws UnexpectedValueException
         */
-       public function getLocations( $item, $limit ) {
-               $locations = [];
-               $primaryLocation = null;
-               $spot = hexdec( substr( sha1( $item ), 0, 7 ) ); // first 28 bits
-               foreach ( $this->ring as $location => $range ) {
-                       if ( count( $locations ) >= $limit ) {
-                               break;
-                       }
-                       // The $primaryLocation is the location the item spot is in.
-                       // After that is reached, keep appending the next locations.
-                       if ( ( $range[0] <= $spot && $spot < $range[1] ) || $primaryLocation !== null ) {
-                               if ( $primaryLocation === null ) {
-                                       $primaryLocation = $location;
-                               }
-                               $locations[] = $location;
-                       }
+       public function getLocations( $item, $limit, $from = self::RING_ALL ) {
+               if ( $from === self::RING_ALL ) {
+                       $ring = $this->baseRing;
+               } elseif ( $from === self::RING_LIVE ) {
+                       $ring = $this->getLiveRing();
+               } else {
+                       throw new InvalidArgumentException( "Invalid ring source specified." );
                }
-               // If more locations are requested, wrap-around and keep adding them
-               reset( $this->ring );
+
+               // Locate this item's position on the hash ring
+               $position = $this->getItemPosition( $item );
+               $itemNodeIndex = $this->findNodeIndexForPosition( $position, $ring );
+
+               $locations = [];
+               $currentIndex = $itemNodeIndex;
                while ( count( $locations ) < $limit ) {
-                       $location = key( $this->ring );
-                       if ( $location === $primaryLocation ) {
-                               break; // don't go in circles
+                       $nodeLocation = $ring[$currentIndex][self::KEY_LOCATION];
+                       if ( !in_array( $nodeLocation, $locations, true ) ) {
+                               // Ignore other nodes for the same locations already added
+                               $locations[] = $nodeLocation;
+                       }
+                       $currentIndex = $this->getNextClockwiseNodeIndex( $currentIndex, $ring );
+                       if ( $currentIndex === $itemNodeIndex ) {
+                               break; // all nodes visited
                        }
-                       $locations[] = $location;
-                       next( $this->ring );
                }
 
                return $locations;
        }
 
        /**
-        * Get the map of locations to weight (ignores 0-weight items)
+        * @param float $position
+        * @param array[] $ring Either the base or live ring
+        * @return int|null
+        */
+       private function findNodeIndexForPosition( $position, $ring ) {
+               $count = count( $ring );
+               if ( $count === 0 ) {
+                       return null;
+               }
+               $lowPos = 0;
+               $highPos = $count;
+               while ( true ) {
+                       $midPos = intval( ( $lowPos + $highPos ) / 2 );
+                       if ( $midPos === $count ) {
+                               return 0;
+                       }
+                       $midVal = $ring[$midPos][self::KEY_POS];
+                       $midMinusOneVal = $midPos === 0 ? 0 : $ring[$midPos - 1][self::KEY_POS];
+
+                       if ( $position <= $midVal && $position > $midMinusOneVal ) {
+                               return $midPos;
+                       }
+
+                       if ( $midVal < $position ) {
+                               $lowPos = $midPos + 1;
+                       } else {
+                               $highPos = $midPos - 1;
+                       }
+
+                       if ( $lowPos > $highPos ) {
+                               return 0;
+                       }
+               }
+       }
+
+       /**
+        * Get the map of locations to weight (does not include zero weight items)
         *
-        * @return array
+        * @return int[]
         */
        public function getLocationWeights() {
-               return $this->sourceMap;
+               return $this->weightByLocation;
        }
 
        /**
@@ -142,53 +200,19 @@ class HashRing {
         * @param string $location
         * @param int $ttl Seconds
         * @return bool Whether some non-ejected locations are left
+        * @throws UnexpectedValueException
         */
        public function ejectFromLiveRing( $location, $ttl ) {
-               if ( !isset( $this->sourceMap[$location] ) ) {
+               if ( !isset( $this->weightByLocation[$location] ) ) {
                        throw new UnexpectedValueException( "No location '$location' in the ring." );
                }
-               $expiry = time() + $ttl;
-               $this->liveRing = null; // stale
-               $this->ejectionExpiries[$location] = $expiry;
-               $this->ejectionNextExpiry = min( $expiry, $this->ejectionNextExpiry );
 
-               return ( count( $this->ejectionExpiries ) < count( $this->sourceMap ) );
-       }
+               $expiry = $this->getCurrentTime() + $ttl;
+               $this->ejectExpiryByLocation[$location] = $expiry;
 
-       /**
-        * Get the "live" hash ring (which does not include ejected locations)
-        *
-        * @return HashRing
-        * @throws UnexpectedValueException
-        */
-       protected function getLiveRing() {
-               $now = time();
-               if ( $this->liveRing === null || $this->ejectionNextExpiry <= $now ) {
-                       $this->ejectionExpiries = array_filter(
-                               $this->ejectionExpiries,
-                               function ( $expiry ) use ( $now ) {
-                                       return ( $expiry > $now );
-                               }
-                       );
-                       if ( count( $this->ejectionExpiries ) ) {
-                               $map = array_diff_key( $this->sourceMap, $this->ejectionExpiries );
-                               $this->liveRing = count( $map ) ? new self( $map ) : false;
-
-                               $this->ejectionNextExpiry = min( $this->ejectionExpiries );
-                       } else { // common case; avoid recalculating ring
-                               $this->liveRing = clone $this;
-                               $this->liveRing->ejectionExpiries = [];
-                               $this->liveRing->ejectionNextExpiry = INF;
-                               $this->liveRing->liveRing = null;
-
-                               $this->ejectionNextExpiry = INF;
-                       }
-               }
-               if ( !$this->liveRing ) {
-                       throw new UnexpectedValueException( "The live ring is currently empty." );
-               }
+               $this->liveRing = null; // invalidate ring cache
 
-               return $this->liveRing;
+               return ( count( $this->ejectExpiryByLocation ) < count( $this->weightByLocation ) );
        }
 
        /**
@@ -198,8 +222,8 @@ class HashRing {
         * @return string Location
         * @throws UnexpectedValueException
         */
-       public function getLiveLocation( $item ) {
-               return $this->getLiveRing()->getLocation( $item );
+       final public function getLiveLocation( $item ) {
+               return $this->getLocations( $item, 1, self::RING_LIVE )[0];
        }
 
        /**
@@ -207,20 +231,200 @@ class HashRing {
         *
         * @param string $item
         * @param int $limit Maximum number of locations to return
-        * @return array List of locations
+        * @return string[] List of locations
         * @throws UnexpectedValueException
         */
-       public function getLiveLocations( $item, $limit ) {
-               return $this->getLiveRing()->getLocations( $item, $limit );
+       final public function getLiveLocations( $item, $limit ) {
+               return $this->getLocations( $item, $limit, self::RING_LIVE );
        }
 
        /**
-        * Get the map of "live" locations to weight (ignores 0-weight items)
+        * Get the map of "live" locations to weight (does not include zero weight items)
         *
-        * @return array
+        * @return int[]
         * @throws UnexpectedValueException
         */
        public function getLiveLocationWeights() {
-               return $this->getLiveRing()->getLocationWeights();
+               $now = $this->getCurrentTime();
+
+               return array_diff_key(
+                       $this->weightByLocation,
+                       array_filter(
+                               $this->ejectExpiryByLocation,
+                               function ( $expiry ) use ( $now ) {
+                                       return ( $expiry > $now );
+                               }
+                       )
+               );
+       }
+
+       /**
+        * @param int[] $weightByLocation
+        * @param string $algo Hashing algorithm
+        * @return array[]
+        */
+       private function buildLocationRing( array $weightByLocation, $algo ) {
+               $locationCount = count( $weightByLocation );
+               $totalWeight = array_sum( $weightByLocation );
+
+               $ring = [];
+               // Assign nodes to all locations based on location weight
+               $claimed = []; // (position as string => (node, index))
+               foreach ( $weightByLocation as $location => $weight ) {
+                       $ratio = $weight / $totalWeight;
+                       // There $locationCount * (HASHES_PER_LOCATION * 4) nodes available;
+                       // assign a few groups of nodes to this location based on its weight.
+                       $nodesQuartets = intval( $ratio * self::HASHES_PER_LOCATION * $locationCount );
+                       for ( $qi = 0; $qi < $nodesQuartets; ++$qi ) {
+                               // For efficiency, get 4 points per hash call and 4X node count.
+                               // If $algo is MD5, then this matches that of with libketama.
+                               // See https://github.com/RJ/ketama/blob/master/libketama/ketama.c
+                               $positions = $this->getNodePositionQuartet( "{$location}-{$qi}" );
+                               foreach ( $positions as $gi => $position ) {
+                                       $node = ( $qi * self::SECTORS_PER_HASH + $gi ) . "@$location";
+                                       $posKey = (string)$position; // large integer
+                                       if ( isset( $claimed[$posKey] ) ) {
+                                               // Disallow duplicates for sanity (name decides precedence)
+                                               if ( $claimed[$posKey]['node'] > $node ) {
+                                                       continue;
+                                               } else {
+                                                       unset( $ring[$claimed[$posKey]['index']] );
+                                               }
+                                       }
+                                       $ring[] = [
+                                               self::KEY_POS => $position,
+                                               self::KEY_LOCATION => $location
+                                       ];
+                                       $claimed[$posKey] = [ 'node' => $node, 'index' => count( $ring ) - 1 ];
+                               }
+                       }
+               }
+               // Sort the locations into clockwise order based on the hash ring position
+               usort( $ring, function ( $a, $b ) {
+                       if ( $a[self::KEY_POS] === $b[self::KEY_POS] ) {
+                               throw new UnexpectedValueException( 'Duplicate node positions.' );
+                       }
+
+                       return ( $a[self::KEY_POS] < $b[self::KEY_POS] ? -1 : 1 );
+               } );
+
+               return $ring;
+       }
+
+       /**
+        * @param string $item Key
+        * @return float Ring position; integral number in [0, self::RING_SIZE - 1]
+        */
+       private function getItemPosition( $item ) {
+               // If $algo is MD5, then this matches that of with libketama.
+               // See https://github.com/RJ/ketama/blob/master/libketama/ketama.c
+               $octets = substr( hash( $this->algo, (string)$item, true ), 0, 4 );
+               if ( strlen( $octets ) != 4 ) {
+                       throw new UnexpectedValueException( __METHOD__ . ": {$this->algo} is < 32 bits." );
+               }
+
+               return (float)sprintf( '%u', unpack( 'V', $octets )[1] );
+       }
+
+       /**
+        * @param string $nodeGroupName
+        * @return float[] Four ring positions on [0, self::RING_SIZE - 1]
+        */
+       private function getNodePositionQuartet( $nodeGroupName ) {
+               $octets = substr( hash( $this->algo, (string)$nodeGroupName, true ), 0, 16 );
+               if ( strlen( $octets ) != 16 ) {
+                       throw new UnexpectedValueException( __METHOD__ . ": {$this->algo} is < 128 bits." );
+               }
+
+               $positions = [];
+               foreach ( unpack( 'V4', $octets ) as $signed ) {
+                       $positions[] = (float)sprintf( '%u', $signed );
+               }
+
+               return $positions;
+       }
+
+       /**
+        * @param int $i Valid index for a node in the ring
+        * @param array[] $ring Either the base or live ring
+        * @return int Valid index for a node in the ring
+        */
+       private function getNextClockwiseNodeIndex( $i, $ring ) {
+               if ( !isset( $ring[$i] ) ) {
+                       throw new UnexpectedValueException( __METHOD__ . ": reference index is invalid." );
+               }
+
+               $next = $i + 1;
+
+               return ( $next < count( $ring ) ) ? $next : 0;
+       }
+
+       /**
+        * Get the "live" hash ring (which does not include ejected locations)
+        *
+        * @return array[]
+        * @throws UnexpectedValueException
+        */
+       protected function getLiveRing() {
+               if ( !$this->ejectExpiryByLocation ) {
+                       return $this->baseRing; // nothing ejected
+               }
+
+               $now = $this->getCurrentTime();
+
+               if ( $this->liveRing === null || min( $this->ejectExpiryByLocation ) <= $now ) {
+                       // Live ring needs to be regerenated...
+                       $this->ejectExpiryByLocation = array_filter(
+                               $this->ejectExpiryByLocation,
+                               function ( $expiry ) use ( $now ) {
+                                       return ( $expiry > $now );
+                               }
+                       );
+
+                       if ( count( $this->ejectExpiryByLocation ) ) {
+                               // Some locations are still ejected from the ring
+                               $liveRing = [];
+                               foreach ( $this->baseRing as $i => $nodeInfo ) {
+                                       $location = $nodeInfo[self::KEY_LOCATION];
+                                       if ( !isset( $this->ejectExpiryByLocation[$location] ) ) {
+                                               $liveRing[] = $nodeInfo;
+                                       }
+                               }
+                       } else {
+                               $liveRing = $this->baseRing;
+                       }
+
+                       $this->liveRing = $liveRing;
+               }
+
+               if ( !$this->liveRing ) {
+                       throw new UnexpectedValueException( "The live ring is currently empty." );
+               }
+
+               return $this->liveRing;
+       }
+
+       /**
+        * @return int UNIX timestamp
+        */
+       protected function getCurrentTime() {
+               return time();
+       }
+
+       public function serialize() {
+               return serialize( [
+                       'algorithm' => $this->algo,
+                       'locations' => $this->weightByLocation,
+                       'ejections' => $this->ejectExpiryByLocation
+               ] );
+       }
+
+       public function unserialize( $serialized ) {
+               $data = unserialize( $serialized );
+               if ( is_array( $data ) ) {
+                       $this->init( $data['locations'], $data['algorithm'], $data['ejections'] );
+               } else {
+                       throw new UnexpectedValueException( __METHOD__ . ": unable to decode JSON." );
+               }
        }
 }
index f5cef9e..72ca590 100644 (file)
@@ -43,6 +43,8 @@ class ChronologyProtector implements LoggerAwareInterface {
        protected $key;
        /** @var string Hash of client parameters */
        protected $clientId;
+       /** @var string[] Map of client information fields for logging */
+       protected $clientInfo;
        /** @var int|null Expected minimum index of the last write to the position store */
        protected $waitForPosIndex;
        /** @var int Max seconds to wait on positions to appear */
@@ -81,6 +83,9 @@ class ChronologyProtector implements LoggerAwareInterface {
                        : md5( $client['ip'] . "\n" . $client['agent'] );
                $this->key = $store->makeGlobalKey( __CLASS__, $this->clientId, 'v2' );
                $this->waitForPosIndex = $posIndex;
+
+               $this->clientInfo = $client + [ 'clientId' => '' ];
+
                $this->logger = new NullLogger();
        }
 
@@ -308,7 +313,7 @@ class ChronologyProtector implements LoggerAwareInterface {
                                                [
                                                        'cpPosIndex' => $this->waitForPosIndex,
                                                        'waitTimeMs' => $waitedMs
-                                               ]
+                                               ] + $this->clientInfo
                                        );
                                } else {
                                        $this->logger->warning(
@@ -317,7 +322,7 @@ class ChronologyProtector implements LoggerAwareInterface {
                                                        'cpPosIndex' => $this->waitForPosIndex,
                                                        'indexReached' => $indexReached,
                                                        'waitTimeMs' => $waitedMs
-                                               ]
+                                               ] + $this->clientInfo
                                        );
                                }
                        } else {
index 160d2d1..87d7e0a 100644 (file)
@@ -245,7 +245,7 @@ class LinkRenderer {
         * @return string
         */
        public function makePreloadedLink(
-               LinkTarget $target, $text = null, $classes, array $extraAttribs = [], array $query = []
+               LinkTarget $target, $text = null, $classes = '', array $extraAttribs = [], array $query = []
        ) {
                // Run begin hook
                $ret = $this->runBeginHook( $target, $text, $extraAttribs, $query, true );
index 9515f25..f5fa4c7 100644 (file)
@@ -85,7 +85,9 @@ class PoolCounterRedis extends PoolCounter {
                parent::__construct( $conf, $type, $key );
 
                $this->serversByLabel = $conf['servers'];
-               $this->ring = new HashRing( array_fill_keys( array_keys( $conf['servers'] ), 100 ) );
+
+               $serverLabels = array_keys( $conf['servers'] );
+               $this->ring = new HashRing( array_fill_keys( $serverLabels, 10 ) );
 
                $conf['redisConfig']['serializer'] = 'none'; // for use with Lua
                $this->pool = RedisConnectionPool::singleton( $conf['redisConfig'] );
index 3ca3a85..6848d2c 100644 (file)
@@ -138,11 +138,11 @@ class SpecialPrefixindex extends SpecialAllPages {
        }
 
        /**
-        * @param int $namespace Default NS_MAIN
+        * @param int $namespace
         * @param string $prefix
         * @param string $from List all pages from this name (default false)
         */
-       protected function showPrefixChunk( $namespace = NS_MAIN, $prefix, $from = null ) {
+       protected function showPrefixChunk( $namespace, $prefix, $from = null ) {
                global $wgContLang;
 
                if ( $from === null ) {
index 26f4da5..4b1b344 100644 (file)
@@ -92,7 +92,7 @@ class SpecialProtectedpages extends SpecialPage {
         *   cascadeOnly, noRedirect
         * @return string Input form
         */
-       protected function showOptions( $namespace, $type = 'edit', $level, $sizetype,
+       protected function showOptions( $namespace, $type, $level, $sizetype,
                $size, $filters
        ) {
                $formDescriptor = [
index 2770bc5..00bfba9 100644 (file)
@@ -112,7 +112,7 @@ class SpecialProtectedtitles extends SpecialPage {
         * @return string
         * @private
         */
-       function showOptions( $namespace, $type = 'edit', $level ) {
+       function showOptions( $namespace, $type, $level ) {
                $formDescriptor = [
                        'namespace' => [
                                'class' => 'HTMLSelectNamespace',
index 3b69698..0d4b5ab 100644 (file)
@@ -44,8 +44,8 @@ class ProtectedPagesPager extends TablePager {
         * @param bool $noredirect
         * @param LinkRenderer $linkRenderer
         */
-       function __construct( $form, $conds = [], $type, $level, $namespace,
-               $sizetype = '', $size = 0, $indefonly = false, $cascadeonly = false, $noredirect = false,
+       function __construct( $form, $conds, $type, $level, $namespace,
+               $sizetype, $size, $indefonly, $cascadeonly, $noredirect,
                LinkRenderer $linkRenderer
        ) {
                $this->mForm = $form;
index 8f172f8..ed437be 100644 (file)
@@ -26,7 +26,7 @@ class ProtectedTitlesPager extends AlphabeticPager {
 
        public $mForm, $mConds;
 
-       function __construct( $form, $conds = [], $type, $level, $namespace,
+       function __construct( $form, $conds, $type, $level, $namespace,
                $sizetype = '', $size = 0
        ) {
                $this->mForm = $form;
index da7bc94..321d5f8 100644 (file)
@@ -3554,7 +3554,7 @@ class Language {
         * @return string
         */
        private function truncateInternal(
-               $string, $length, $ellipsis = '...', $adjustLength = true, $measureLength, $getSubstring
+               $string, $length, $ellipsis, $adjustLength, $measureLength, $getSubstring
        ) {
                if ( !is_callable( $measureLength ) || !is_callable( $getSubstring ) ) {
                        throw new InvalidArgumentException( 'Invalid callback provided' );
@@ -4471,7 +4471,7 @@ class Language {
         * @throws MWException
         * @return string $prefix . $mangledCode . $suffix
         */
-       public static function getFileName( $prefix = 'Language', $code, $suffix = '.php' ) {
+       public static function getFileName( $prefix, $code, $suffix = '.php' ) {
                if ( !self::isValidBuiltInCode( $code ) ) {
                        throw new MWException( "Invalid language code \"$code\"" );
                }
index c759220..fcba6dc 100644 (file)
@@ -126,7 +126,6 @@ class CrhExceptions {
                'beyude' => 'бейуде', 'beyüde' => 'бейуде',
                'curat' => 'джурьат', 'cürat' => 'джурьат',
                'mesul' => 'месуль', 'mesül' => 'месуль',
-               'yetsin' => 'етсин', 'etsin' => 'етсин',
        ];
 
        # map Cyrillic to Latin and back, simple string match only (no regex)
@@ -367,7 +366,7 @@ class CrhExceptions {
                'козь' => 'köz', '-юнджи' => '-ünci', '-юнджиде' => '-üncide', '-юнджиден' => '-ünciden',
 
                # originally L2C, here swapped
-               'еÑ\82Ñ\81ин' => 'etsin', 'лÑ\8cнаÑ\8f' => 'lnaya', 'лÑ\8cное' => 'lnoye', 'лÑ\8cнÑ\8bй' => 'lnıy', 'лÑ\8cний' => 'lniy',
+               'льная' => 'lnaya', 'льное' => 'lnoye', 'льный' => 'lnıy', 'льний' => 'lniy',
                'льская' => 'lskaya', 'льский' => 'lskiy', 'льское' => 'lskoye', 'ополь' => 'opol',
                'щее' => 'şçeye', 'щий' => 'şçiy', 'щая' => 'şçaya', 'цепс' => 'tseps',
 
@@ -389,8 +388,8 @@ class CrhExceptions {
                'му([иэИЭ])' => 'mü$1',
 
                # originally L2C, here swapped
-               'роль$1' => 'rol([^ü])',
-               'усть$1' => 'üst([^ü])',
+               'роль$1' => 'rol([^ü]|'.self::WB.')',
+               'усть$1' => 'üst([^ü]|'.self::WB.')',
 
                # more prefixes
                'ком-кок' => 'köm-kök',
@@ -460,6 +459,10 @@ class CrhExceptions {
                        '/'.self::WB.'Джонкю'.self::WB.'/u' => 'Cönkü',
                        '/'.self::WB.'ДЖОНКЮ'.self::WB.'/u' => 'CÖNKÜ',
 
+                       '/'.self::WB.'куркчи/u' => 'kürkçi',
+                       '/'.self::WB.'Куркчи/u' => 'Kürkçi',
+                       '/'.self::WB.'КУРКЧИ/u' => 'KÜRKÇI',
+
                        '/'.self::WB.'устке'.self::WB.'/u' => 'üstke',
                        '/'.self::WB.'Устке'.self::WB.'/u' => 'Üstke',
                        '/'.self::WB.'УСТКЕ'.self::WB.'/u' => 'ÜSTKE',
@@ -615,13 +618,21 @@ class CrhExceptions {
                        '/'.self::WB.'Mer'.self::WB.'/u' => 'Мэр',
                        '/'.self::WB.'MER'.self::WB.'/u' => 'МЭР',
 
-                       '/'.self::WB.'джонк/u' => 'cönk',
-                       '/'.self::WB.'Джонк/u' => 'Cönk',
-                       '/'.self::WB.'ДЖОНК/u' => 'CÖNK',
+                       '/'.self::WB.'cönk/u' => 'джонк',
+                       '/'.self::WB.'Cönk/u' => 'Джонк',
+                       '/'.self::WB.'CÖNK/u' => 'ДЖОНК',
 
-                       '/'.self::WB.'куркчи/u' => 'kürkçi',
-                       '/'.self::WB.'Куркчи/u' => 'Kürkçi',
-                       '/'.self::WB.'КУРКЧИ/u' => 'KÜRKÇI',
+                       # (y)etsin -> етсин/этсин
+                       # note that target starts with CYRILLIC е/Е!
+                       '/yetsin/u' => 'етсин',
+                       '/Yetsin/u' => 'Етсин',
+                       '/YETSİN/u' => 'ЕТСИН',
+
+                       # note that target starts with LATIN e/E!
+                       # (other transformations will determine CYRILLIC е/э as needed)
+                       '/etsin/u' => 'eтсин',
+                       '/Etsin/u' => 'Eтсин',
+                       '/ETSİN/u' => 'EТСИН',
 
                        # буква Ё - первый заход
                        # расставляем Ь после согласных
@@ -666,10 +677,6 @@ class CrhExceptions {
                        '/(['.Crh::L_F.'])l(['.Crh::L_CONS_LC.']|'.self::WB.')/u' => '$1ль$2',
                        '/(['.Crh::L_F_UC.'])L(['.Crh::L_CONS.']|'.self::WB.')/u' => '$1ЛЬ$2',
 
-                       '/etsin'.self::WB.'/u' => 'етсин',
-                       '/Etsin'.self::WB.'/u' => 'Етсин',
-                       '/ETSİN'.self::WB.'/u' => 'ЕТСИН',
-
                        # относятся к началу слова
                        '/'.self::WB.'ts/u' => 'ц',
                        '/'.self::WB.'T[sS]/u' => 'Ц',
index 0e77bdc..21fefcb 100644 (file)
        "version-other": "Други",
        "version-mediahandlers": "Обработчици на медия",
        "version-hooks": "Куки",
-       "version-parser-extensiontags": "Ð\95Ñ\82икеÑ\82и от парсерни разширения",
+       "version-parser-extensiontags": "Тагове от парсерни разширения",
        "version-parser-function-hooks": "Куки в парсерни функции",
        "version-hook-name": "Име на куката",
        "version-hook-subscribedby": "Ползвана от",
index 8ad5aed..7e76d0e 100644 (file)
        "anontalkpagetext": "----\n<em>এটি একটি বেনামী ব্যবহারকারীর আলাপের পাতা, যিনি এখনও কোন অ্যাকাউন্ট তৈরি করেননি, কিংবা তিনি অ্যাকাউন্টটি ব্যবহার করছেন না।</em>\nআমরা তাই সাংখ্যিক আইপি ঠিকানা ব্যবহার করে তাঁকে শনাক্ত করছি।\nএকাধিক ব্যবহারকারী এরকম একটি আইপি ঠিকানা ব্যবহার করতে পারেন।\nআপনি যদি একজন বেনামী ব্যবহারকারী হয়ে থাকেন এবং যদি অনুভব করেন যে আপনার প্রতি অপ্রাসঙ্গিক মন্তব্য করা হয়েছে, তাহলে অন্যান্য বেনামী ব্যবহারকারীর সাথে ভবিষ্যতে বিভ্রান্তি এড়াতে অনুগ্রহ করে [[Special:CreateAccount|একটি অ্যাকাউন্ট তৈরি করুন]] অথবা  [[Special:UserLogin|অ্যাকাউন্টে প্রবেশ করুন]]।",
        "noarticletext": "বর্তমানে এই পাতায় কোন লেখা নেই।\nআপনি চাইলে অন্যান্য পাতায় [[Special:Search/{{PAGENAME}}| এই শিরোনামটি অনুসন্ধান করতে পারেন]],\n<span class=\"plainlinks\">[{{fullurl:{{#Special:Log}}|page={{FULLPAGENAMEE}}}} এ সম্পর্কিত লগ অনুসন্ধান করতে পারেন], \nকিংবা [{{fullurl:{{FULLPAGENAME}}|action=edit}} এই পাতাটি তৈরি করতে পারেন]</span>।",
        "noarticletext-nopermission": "বর্তমানে এই পাতায় কোন লেখা নেই।\nআপনি চাইলে অন্য পাতায় [[Special:Search/{{PAGENAME}}| শিরোনামটি অনুসন্ধান করতে পারেন]], অথবা <span class=\"plainlinks\">[{{fullurl:{{#Special:Log}}|page={{FULLPAGENAMEE}}}} সম্পর্কিত লগ অনুসন্ধান করতে পারেন]</span>, কিন্তু আপনার এই পাতাটি তৈরী করার অনুমতি নেই।",
-       "missing-revision": "\"{{FULLPAGENAME}}\" এর #$1তম সংস্করণটি প্রদর্শন সম্ভব নয়।\n\nসাধারণত মুছে ফেলা হয়েছে এমন পাতার মেয়াদ উত্তীর্ণ ইতিহাস পাতার লিংক ওপেন করার কারণে এটি হতে পারে। \n[{{fullurl:{{#Special:Log}}/delete|page={{FULLPAGENAMEE}}}} অপসারণ লগে] বিস্তারিত তথ্য জানা যাবে।",
+       "missing-revision": "\"{{FULLPAGENAME}}\" এর #$1তম সংস্করণটি প্রদর্শন সম্ভব নয়।\n\nসাধারণত মুছে ফেলা হয়েছে এমন পাতার মেয়াদ উত্তীর্ণ ইতিহাসের সংযোগ অনুসরণ করার কারণে এটি হতে পারে। \n[{{fullurl:{{#Special:Log}}/delete|page={{FULLPAGENAMEE}}}} অপসারণ লগে] বিস্তারিত তথ্য জানা যাবে।",
        "userpage-userdoesnotexist": "\"<nowiki>$1</nowiki>\" নামের কোন ব্যবহারকারী অ্যাকাউন্ট নিবন্ধিত হয়নি। অনুগ্রহ করে পরীক্ষা করে দেখুন আপনি এই পাতাটি সৃষ্টি/সম্পাদনা করতে চান কি না।",
        "userpage-userdoesnotexist-view": "ব্যবহারকারী অ্যাকাউন্ট \"$1\" অনিবন্ধিত।",
        "blocked-notice-logextract": "এই ব্যবহারকারী বর্তমানে অবরুদ্ধ রয়েছেন।\nসূত্রের জন্য সাম্প্রতিক বাধাদান লগের ভুক্তিটি নিচে দেওয়া হল:",
index f258241..a6f49ec 100644 (file)
@@ -8,7 +8,8 @@
                        "ОйЛ",
                        "아라",
                        "Илья Драконов",
-                       "Vvs-dm"
+                       "Vvs-dm",
+                       "Matěj Suchánek"
                ]
        },
        "tog-oldsig": "твои нꙑнѣшьн҄ь аѵтографъ :",
        "userexists": "сѫщє польꙃєватєлꙗ имѧ пьса ⁙\nбѫди добръ · ино сѥ иꙁобрѧщи",
        "loginerror": "въхода блаꙁна",
        "createacct-error": "мѣста сътворѥниꙗ блаꙁна",
-       "loginsuccess": "'''нꙑнѣ тꙑ {{GENDER|въшьлъ|въшьла}} въ {{grammar:locative|{{SITENAME}}}} подь имьньмъ ⁖ $1 ⁖.'''",
+       "loginsuccess": "'''нꙑнѣ тꙑ {{GENDER:|въшьлъ|въшьла}} въ {{grammar:locative|{{SITENAME}}}} подь имьньмъ ⁖ $1 ⁖.'''",
        "mailmypassword": "нова таина слова оуставлѥниѥ",
        "accountcreated": "мѣсто сътворєно ѥстъ",
        "accountcreatedtext": "польꙃєватєльско мѣсто [[{{ns:User}}:$1|$1]] ([[{{ns:User talk}}:$1|бєсѣда]]) сътворєно бѣ",
index cd6217c..8f28907 100644 (file)
@@ -64,7 +64,8 @@
                        "Obzord",
                        "Alp Er Tunqa",
                        "Baloch Khan",
-                       "Fitoschido"
+                       "Fitoschido",
+                       "Alireza Ivaz"
                ]
        },
        "tog-underline": "خط کشیدن زیر پیوندها:",
        "logouttext": "'''اکنون شما ثبت خروج کرده‌اید.'''\nتوجه داشته باشید که تا حافظهٔ نهان مرورگرتان را پاک نکنید، بعضی از صفحات ممکن است همچنان به گونه‌ای نمایش یابند که انگار وارد شده‌اید.",
        "cannotlogoutnow-title": "الان امکان خروج از سامانه نیست",
        "cannotlogoutnow-text": "در زمان استفاده از $1 امکان خروج از سامانه وجود ندارد.",
-       "welcomeuser": "خوشامدید $1!",
+       "welcomeuser": "$1 به {{SITENAME}} خوش‌آمدید!",
        "welcomecreation-msg": "حساب کاربری شما ایجاد شده است.\nفراموش نکنید که [[Special:Preferences|ترجیحات {{SITENAME}}]] خود را تغییر دهید.",
        "yourname": "نام کاربری:",
        "userlogin-yourname": "نام کاربری",
        "unusedcategories": "رده‌های استفاده‌نشده",
        "unusedimages": "پرونده‌های استفاده‌نشده",
        "wantedcategories": "رده‌های مورد نیاز",
-       "wantedpages": "صÙ\81Ø­ه‌های مورد نیاز",
+       "wantedpages": "برگه‌های مورد نیاز",
        "wantedpages-summary": "فهرست صفحه‌های ناموجود با بیشترین پیوند به آنها، به استثنای صفحه‌هایی که فقط تغییرمسیر به آنها دارند. برای یک فهرست از صفحه‌های ناموجود که تغییرمسیر به آنها دارند، [[{{#special:BrokenRedirects}}|فهرست تغییرمسیرهای شکسته]] را ببینید.",
        "wantedpages-badtitle": "عنوان نامجاز در مجموعهٔ نتایج: $1",
        "wantedfiles": "پرونده‌های مورد نیاز",
index 5381285..a5dd902 100644 (file)
@@ -7,7 +7,8 @@
                        "Matma Rex",
                        "NoiX180",
                        "Zhoelyakin",
-                       "Amire80"
+                       "Amire80",
+                       "Matěj Suchánek"
                ]
        },
        "tog-underline": "Garisiyi totibawa wumbuta",
        "hidden-category-category": "Dalala wanto-wanto'o",
        "category-subcat-count": "{{PLURAL:$2|Kategori boti woluwo subkategori|Kategori boti woluwo {{PLURAL:$1|subkategori|$1 subkategori}} lonto nga'amila $2.}}",
        "category-subcat-count-limited": "Kategori boti woluwo {{PLURAL:$1|subkategori|$1 subkategori}}",
-       "category-article-count": "{{PLURAL:$2|Kategori botiye o tuwango halaman.|Woluwo {{PLURAL:$|$1 halaman}} to delomo kategori, lonto $2 nga'amila.}}",
+       "category-article-count": "{{PLURAL:$2|Kategori botiye o tuwango halaman.|Woluwo {{PLURAL:$1|$1 halaman}} to delomo kategori, lonto $2 nga'amila.}}",
        "category-article-count-limited": "Kategori boti woluwo {{PLURAL:$1|halaman|$1 halaman}} to delomo kategori",
        "category-file-count": "{{PLURAL:$2|To kategori boti woluwo berkas {{PLURAL:$1|berkas|$1 berkas}} to delomo kategori, lonto nga'amila $2}}",
        "category-file-count-limited": "Woluwo {{PLURAL:$1|berkas|S1 berkas}} to delomo kategori.",
index 37efd6e..83c151d 100644 (file)
        "thumbnail_error_remote": "הודעת שגיאה של $1:\n$2",
        "djvu_page_error": "דף ה־DjVu מחוץ לטווח",
        "djvu_no_xml": "לא ניתן היה לקבל את ה־XML עבור קובץ ה־DjVu",
-       "thumbnail-temp-create": "×\9c×\90 ×\94צ×\9c×\99×\97×\94 ×\99צ×\99רת ×§×\95×\91×¥ ×ª×\9e×\95× ×\94 ×\9e×\9e×\95×\96ערת זמני",
+       "thumbnail-temp-create": "×\9c×\90 ×\94×\99×\99ת×\94 ×\90פשר×\95ת ×\9c×\99צ×\95ר ×\90ת ×§×\95×\91×¥ ×\94ת×\9e×\95× ×\94 ×\94×\9e×\9e×\95×\96ערת ×\94זמני",
        "thumbnail-dest-create": "לא הייתה אפשרות לשמור את התמונה הממוזערת אל יעדה",
        "thumbnail_invalid_params": "פרמטרים שגויים לתמונה הממוזערת",
        "thumbnail_toobigimagearea": "קובץ בגודל של יותר מ־$1",
        "thumbnail_dest_directory": "לא ניתן היה ליצור את תיקיית היעד",
        "thumbnail_image-type": "סוג התמונה אינו נתמך",
-       "thumbnail_gd-library": "הגדרת הספריה GD אינה שלמה: חסרה הפונקציה $1",
+       "thumbnail_gd-library": "×\94×\92×\93רת ×\94ספר×\99×\99×\94 GD ×\90×\99× ×\94 ×©×\9c×\9e×\94: ×\97סר×\94 ×\94פ×\95נקצ×\99×\94 $1",
        "thumbnail_image-size-zero": "נראה שקובץ התמונה הוא בגודל אפס.",
        "thumbnail_image-missing": "נראה שהקובץ הבא חסר: $1",
        "thumbnail_image-failure-limit": "היו לאחרונה ניסיונות רבים מדי ($1 או יותר) ליצור את התמונה הממוזערת הזאת. נא לנסות שוב מאוחר יותר.",
index 2f14407..97b169e 100644 (file)
        "botpasswords-restriction-failed": "A botjelszó-korlátozások megakadályozzák ezt a bejelentkezést.",
        "botpasswords-invalid-name": "A megadott felhasználónév nem tartalmazza a botjelszó-elválasztót („$1”).",
        "botpasswords-not-exist": "A(z) „$1” felhasználó nem rendelkezik „$2” nevű botjelszóval.",
+       "botpasswords-needs-reset": "„$1” {{GENDER:$1|felhasználó}} „$2” botjának jelszavát vissza kell állítani.",
        "resetpass_forbidden": "A jelszavak nem változtathatók meg",
        "resetpass_forbidden-reason": "A jelszavakat nem változtathatóak meg: $1",
        "resetpass-no-info": "Be kell jelentkezned, hogy közvetlenül elérd ezt a lapot.",
        "rcfilters-watchlist-showupdated": "Az újabb változtatások, amiket még nem néztél meg, <strong>vastagítva</strong> láthatók, kitöltött jelzőkkel.",
        "rcfilters-preference-label": "A friss változtatások fejlesztett változatának elrejtése",
        "rcfilters-preference-help": "A 2017-es felületátdolgozás és minden azóta hozzáadott eszköz visszaállítása.",
+       "rcfilters-watchlist-preference-label": "A Figyelőlista fejlesztett változatának elrejtése",
+       "rcfilters-watchlist-preference-help": "A 2017-es felületátdolgozás és minden azóta hozzáadott eszköz visszaállítása.",
        "rcfilters-filter-showlinkedfrom-label": "A következő lapra hivatkozó lapok változtatásainak megjelenítése",
        "rcfilters-filter-showlinkedfrom-option-label": "A kiválasztott <strong>lapról</strong> hivatkozott lapok",
        "rcfilters-filter-showlinkedto-label": "A következő lapról hivatkozott lapok változtatásainak megjelenítése",
        "dellogpage": "Törlési napló",
        "dellogpagetext": "Itt láthatók a legutóbb törölt lapok.",
        "deletionlog": "törlési napló",
+       "log-name-create": "Laplétrehozási napló",
+       "log-description-create": "Itt láthatók a legutóbb létrehozott lapok.",
+       "logentry-create-create": "$1 {{GENDER:$2|létrehozta}} a következő lapot: $3",
        "reverted": "Visszaállítva a korábbi változatra",
        "deletecomment": "Ok:",
        "deleteotherreason": "További indoklás:",
        "passwordpolicies-policy-minimumpasswordlengthtologin": "A jelszónak legalább $1 karakterből kell állnia a bejelentkezéshez",
        "passwordpolicies-policy-passwordcannotmatchusername": "A jelszó nem lehet azonos a felhasználónévvel",
        "passwordpolicies-policy-passwordcannotmatchblacklist": "A jelszó nem lehet azonos a feketelistán szereplő jelszavakkal.",
-       "passwordpolicies-policy-maximalpasswordlength": "A jelszó legfeljebb $1 karakter hosszú lehet"
+       "passwordpolicies-policy-maximalpasswordlength": "A jelszó legfeljebb $1 karakter hosszú lehet",
+       "passwordpolicies-policy-passwordcannotbepopular": "A jelszó nem {{PLURAL:$1|lehet a gyakran használt jelszó|szerepelhet a(z) $1 leggyakrabban használt jelszó listáján}}"
 }
index 69b73bf..9d3187d 100644 (file)
        "undelete-search-submit": "Хьалáха",
        "namespace": "ЦIерий моттигаш:",
        "invert": "Хержар юхадаккха",
-       "tooltip-invert": "Ð\9eÑ\82Ñ\82ае ÐµÑ\80 Ð±ÐµÐ»Ð³Ð°Ð»Ð¾, Ñ\85еÑ\80жа Ñ\86IеÑ\80ий Ð°Ñ\80е Ñ\87Ñ\83 Ð° (белгалÑ\8aÑ\8fÑ\8c Ñ\8fле Ð²IаÑ\88агIÑ\8aÑ\8eвзаенна Ñ\86IеÑ\80ий Ð°Ñ\80е Ñ\87Ñ\83 Ð°), Ð¾Ð°Ð³IонаÑ\88 Ñ\82Iа Ð° Ð´Ð°Ñ\8c хувцамаш къайладоахаргдолаш",
+       "tooltip-invert": "Ð\9eÑ\82Ñ\82ае ÐµÑ\80 Ð±ÐµÐ»Ð³Ð°Ð»Ð¾, Ñ\85еÑ\80жа Ñ\86IеÑ\80ий Ð¼ÐµÑ\82Ñ\82ига Ð´Ð¾Ð°Ð·Ð¾Ð½ Ñ\87Ñ\83Ñ\85Ñ\8c (белгалÑ\8aÑ\8fÑ\8c Ñ\8fле Ð²IаÑ\88агIÑ\8aÑ\8eвзаеннаÑ\87а Ñ\86IеÑ\80ий Ð¼ÐµÑ\82Ñ\82игаÑ\88ка Ð°) Ð¾Ð°Ð³IонаÑ\88 Ñ\82Iа Ð´Ð°Ñ\8c Ð´Ð¾Ð»Ð° хувцамаш къайладоахаргдолаш",
        "namespace_association": "ВIашагIйийхка моттиг",
-       "tooltip-namespace_association": "Оттае ер белгало, иштта хержа цIерий ареца вIашагIъювзаенна дувца оттадара цIерий аре (е кхыяр) юкъейоаккхаргйолаш",
+       "tooltip-namespace_association": "Оттае ер белгало, иштта хьахержача цIерий меттигаца вIашагIъювзаенна дувцара цIерий моттиг (е кхыяр) юкъейоаккхаргйолаш",
        "blanknamespace": "(Кертера)",
        "contributions": "{{GENDER:$1|Доакъашхочун}} къахьегам",
        "contributions-title": "{{GENDER:$1|Доакъашхочун}} $1 къахьегам",
index 9e3d542..f2c9726 100644 (file)
@@ -12,7 +12,8 @@
                        "Angel Blaise",
                        "Fitoschido",
                        "Robin van der Vliet",
-                       "Mafcadio"
+                       "Mafcadio",
+                       "Matěj Suchánek"
                ]
        },
        "tog-underline": "Sulini de lias:",
        "logentry-delete-restore": "$1 {{GENDER:$2|restora}} paje $3 ($4)",
        "logentry-delete-restore-nocount": "$1 {{GENDER:$2|restora}} paje $3",
        "restore-count-revisions": "{{PLURAL:$|1 revisa|$1 revisas}}",
-       "restore-count-files": "{{PLURAL:$|1 fix|$1 fixes}}",
+       "restore-count-files": "{{PLURAL:$1|1 fix|$1 fixes}}",
        "logentry-delete-event": "$1 {{GENDER:$2|cambia}} la vidablia de {{PLURAL:$5|un entrada|$5 entradas}} de rejistra en $3: $4",
        "logentry-delete-revision": "$1 {{GENDER:$2|cambia}} la vidablia de {{PLURAL:$5|un revisa|$5 revisas}} en paje $3: $4",
        "logentry-delete-event-legacy": "$1 {{GENDER:$2|cambia}} la vidablia de entradas de rejistra en $3",
index 4ef38de..fb977f9 100644 (file)
@@ -16,7 +16,8 @@
                        "Nemo bis",
                        "S4b1nuz E.656",
                        "Ruthven",
-                       "Fitoschido"
+                       "Fitoschido",
+                       "Sannita"
                ]
        },
        "tog-underline": "Sottolinia 'e jonte:",
        "readonly": "Database arrestato",
        "enterlockreason": "Miette 'o mutivo 'e blocco, nzieme a 'o mumento quanno se penza ca 'o blocco se sarrà fernuto",
        "readonlytext": "Mo mmo 'o database s'è arrestato pe n'operazione semprice 'e manutenzione e nun se ponno azzeccà cagnamiente o pàggene nove. Quanno sarrà fernuta, atanno 'a paggena addeventarrà nurmale.\n\nL'ammenistratore 'e sistema c'ha fatto 'o blocco, nce dà sta spiegazione: $1",
-       "missing-article": "'O database nun trova 'o testo 'e na paggena c'adda stà, c' 'o nomme \"$1\" $2.\n\nNormalmente, chesto succere quanno s'è richiamato, a partire d' 'a cronologgia o pùre a 'o confronto tra verzione, nu cullegamento a na paggena scancellata, a nu confronto tra verziune inesistente o a nu confronto tra verziune re-pulezzate d' 'a cronologgia.\n\n'N caso cuntrario, può darse pure nu sbaglio dint'o software.\nPer piacere, mannate na mmasciata ccà all'[[Special:ListUsers/sysop|amministratore]] annummenanno l'URL 'n quistiona.",
+       "missing-article": "'O database nun trova 'o testo 'e na paggena ca c'avess' a stà, c' 'o nomme \"$1\" $2.\n\nNurmalmente, chisto succere quanno s'è richiammato na cronologgia o pùre a nu confronto tra verzione 'e a na paggena scancellata.\n\n'N caso cuntrario, può darse pure nu sbaglio dint'o software.\nPe ppiacere, mannate na mmasciata ccà all'[[Special:ListUsers/sysop|amministratore]] annummenanno l'URL 'n quistiona.",
        "missingarticle-rev": "(nummero 'e verzione: $1)",
        "missingarticle-diff": "(Diff: $1, $2)",
        "readonly_lag": "'O database s'è arrestato automaticamente pe' tramente ca 'e servers 'e database schiave sincronizzano c' 'o server masto.",
        "cascadeprotected": "Sta paggena è stata prutetta 'a 'o cangamento pecché trascluse int'a {{PLURAL:$1|sta paggena, che è prutetta|sti paggene, che songo prutette}} quann' 'a l'ozione \"ricurziva\" è attiva:\n$2",
        "namespaceprotected": "Nun avite permesso a cagnà 'e paggene dint'a stu namespace '''$1'''.",
        "customcssprotected": "Nun v'è permesso 'a cagnà sta paggena CSS, pecché cuntene 'e mpustaziune perzunale 'e n'at'utente.",
+       "customjsonprotected": "Nun v'è permesso 'a cagnà sta paggena JSON, pecché cuntene 'e mpustaziune perzunale 'e n'at'utente.",
        "customjsprotected": "Nun v'è permesso 'a cagnà sta paggena JavaScript, pecché cuntene 'e mpustaziune perzunale 'e n'at'utente.",
        "mycustomcssprotected": "Nun v'è permesso 'a cagnà sta paggena CSS.",
+       "mycustomjsonprotected": "Nun v'è permesso 'a cagnà sta paggena JSON.",
        "mycustomjsprotected": "Nun v'è licenzia pe cagnà sta paggena JavaScript.",
        "myprivateinfoprotected": "Nun v'è licenzia pe cagnà 'a nfurmaziona privata vuosta.",
        "mypreferencesprotected": "Nun v'è licenzia 'a cagnà 'e preferenze tuoje.",
        "nosuchusershort": "Nun ce stanno utente cu o nòmme \"$1\". Cuntrolla si scrivìste buòno.",
        "nouserspecified": "Tiene 'a dìcere nu nomme pricìso.",
        "login-userblocked": "Chist'utente è bloccato. Nun se può effettuà 'o login.",
-       "wrongpassword": "'A password nzertàta nun è bbona.\nPe' piacere pruvate n'ata vota.",
+       "wrongpassword": "'A password nzertàta nun è bbona. Pe' piacere, pruvate n'ata vota.",
        "wrongpasswordempty": "'A password nzertàta è abbacante.\nPe' piacere pruvate n'ata vota.",
        "passwordtooshort": "'E password hann'avé minimo {{PLURAL:$1|nu carattere|$1 carattere}}.",
        "passwordtoolong": "'E password nun ponno essere cchiù luonghe 'e {{PLURAL:$1|nu carattere|$1 carattere}}.",
-       "passwordtoopopular": "'E parole comune nun se ponno ausà pe' ve fà na password. Sciglite na password cchiù unica.",
+       "passwordtoopopular": "'E parole comune nun se ponno ausà comme password. Scigliteve na password cchiù tosta.",
        "password-name-match": "'A password adda essere diverza 'a 'o nomme utente.",
        "password-login-forbidden": "L'uso 'e stu nomme utente e password è stato proibito.",
        "mailmypassword": "Riabbìa 'a password",
        "botpasswords-existing": "Password bot esistente",
        "botpasswords-createnew": "Crèa na password bot nòva",
        "botpasswords-editexisting": "Cagna na password bot esistente",
+       "botpasswords-label-needsreset": "('a password adda esse cangiata)",
        "botpasswords-label-appid": "Nomme d' 'o bot:",
        "botpasswords-label-create": "Crèa",
        "botpasswords-label-update": "Agghiuorna",
        "botpasswords-insert-failed": "Nun se pò azzeccà 'o nomme bot \"$1\". Fosse stato già azzeccato?",
        "botpasswords-update-failed": "Se scassaje a carrecà 'o nomme bot \"$1\". È stato scancellato?",
        "botpasswords-created-title": "Password bot criata",
-       "botpasswords-created-body": "'A password bot \"$1\" 'a ll'utente \"$2\" fuje criata.",
+       "botpasswords-created-body": "'A password pe' 'o bot \"$1\" 'e ll'{{GENDER:$2|utente}} \"$2\" fuje criata.",
        "botpasswords-updated-title": "Password bot agghiurnata",
-       "botpasswords-updated-body": "'A password bot \"$1\" 'a ll'utente \"$2\" fuje agghiurnata.",
+       "botpasswords-updated-body": "'A password pe' 'o bot \"$1\" 'e ll'{{GENDER:$2|utente}} \"$2\" fuje agghiurnata.",
        "botpasswords-deleted-title": "Password bot scancellata",
-       "botpasswords-deleted-body": "'A password bot \"$1\" 'a ll'utente \"$2\" è stata scancellata.",
+       "botpasswords-deleted-body": "'A password pe' 'o bot \"$1\" 'e ll'{{GENDER:$2|utente}} \"$2\" è stata scancellata.",
        "botpasswords-newpassword": "'A password nòva pe' puté trasì cu <strong>$1</strong> è <strong>$2</strong>. <em>Pe' piacere signatevello chesto pe' ve ffà conzurtaziune future.</em> <br>('E bott viecchie addò servisse nu nomme utente comm'a chell' 'e l'utente, putite ancora ausà <strong>$3</strong> comm' 'o nomm' 'utente e <strong>$4</strong> comm' 'a password.)",
        "botpasswords-no-provider": "BotPasswordsSessionProvider nun è disponibbele.",
        "botpasswords-restriction-failed": "'E restriziune 'e password bot nun ve permettessero st'acciesso.",
        "botpasswords-invalid-name": "'O nomme utente nnecato nun cuntenesse nu spartetóre 'e bot password (\"$1\").",
        "botpasswords-not-exist": "L'utente \"$1\" nun téne na password bot chiammata \"$2\".",
+       "botpasswords-needs-reset": "'A password pe' 'o bot \"$1\" 'e ll'{{GENDER:$2|utente}} \"$2\" adda esse cangiata.",
        "resetpass_forbidden": "'E password nun se ponno cagnà",
        "resetpass_forbidden-reason": "'E password nun se ponno cagnà: $1",
        "resetpass-no-info": "Avite 'a trasì ('o login) pe ffà l'acciesso a sta paggena direttamente.",
        "savechanges": "Sarva 'e cagnamiénte",
        "publishpage": "Pubbreca paggena",
        "publishchanges": "Pubbreca 'e cagnamiente",
+       "savearticle-start": "Sarva 'a paggena...",
+       "savechanges-start": "Sarva 'e cagnamiénte...",
+       "publishpage-start": "Pubbreca 'a paggena...",
+       "publishchanges-start": "Pubbreca 'e cagnamiente...",
        "preview": "Anteprimma",
        "showpreview": "Vire anteprimma",
        "showdiff": "Fa veré 'e cagnamiente",
        "anonpreviewwarning": "''Nun avite fatto 'o login. Sarvann' 'a paggena, l'indirizzo IP d' 'o vuosto sarrà riggistrato dint'a cronologgia.''",
        "missingsummary": "'''Attenziò:''' nun s'è specificato l'oggetto 'e stu cagnamiento. Clicann' 'a \"$1\" n'ata vota 'o cagnamiento sarrà sarvato cu l'oggetto abbacante.",
        "selfredirect": "<strong>Attenziò:</strong> State crianno nu redirect a 'o stesso articolo.\nPuò darse c'avites specificato 'o pizzo sbagliato p' 'o redirect, o ca stavate cagnanno 'o pizzo sbagliato.\nSi cliccate \"$1\" n'ata vota, si criarrà 'o redirect.",
-       "missingcommenttext": "Pe' piacere scrivete nu commento ccà abbascio.",
+       "missingcommenttext": "Pe' piacere, scrivete nu commento.",
        "missingcommentheader": "<strong>Arricurdateve:</strong> nun s'è specificato l'oggetto/titolo pe stu commento. Clicann' 'a \"$1\" n'ata vota 'o cagnamiento sarrà sarvato c' 'o titolo/oggetto abbacante.",
        "summary-preview": "Anteprimma'e l'oggetto:",
        "subject-preview": "Anteprimma 'e l'oggetto:",
        "previewerrortext": "È succiesso n'errore quanno se steva a ffà pre-veré 'e cagnamiente vuoste.",
        "blockedtitle": "Utente bloccato.",
        "blockedtext": "<strong>'O nomme utente o ll'IP vuosto è stato bloccato.</strong>\n\n'O blocco è stato mpustato 'a $1. 'O mutivo d' 'o blocco è chisto: ''$2''\n\n* Abbiàta d' 'o blocco: $8\n* Ammaturità d' 'o blocco: $6\n* Tiempo 'e blocco: $7\n\nPutite cuntattà $1 o n'atu [[{{MediaWiki:Grouppage-sysop}}|ammenistratore]] pe discutere d'ô blocco.\n\nVedite c' 'a funzione \"{{int:emailuser}}\" nun è attiva si nun s'ave riggistrato 'o ndirizzo e-mail buono dint' 'e [[Special:Preferences|preferenze]] o pùre si ll'uso 'e tale funzione è stato bloccato.\n\n'O ndirizzo IP 'e mo è $3, 'o nummero ID d' 'o blocco è #$5.\nPe piacere avite 'a specificà tutte sti dettaglie quanno facite carche dumanna.",
-       "autoblockedtext": "Ll'IP vuosto è stato bloccato pecché 'o steva piglianno n'atu utente, ch'è stato bloccato pe' $1.\n\n'O mutivo d' 'o blocco è chesto:\n\n:''$2''\n\n* Abbiàta d' 'o blocco: $8\n* Ammaturità d' 'o blocco: $6\n* Tiempo 'e blocco: $7\n\nPutite cuntattà $1 o n'atu [[{{MediaWiki:Grouppage-sysop}}|ammenistratore]] pe' discutere 'o blocco.\n\nVedite c' 'a funzione 'Scrivete a ll'utente' nun è attiva si nun s'è riggistrato 'o ndirizzo e-mail buono dint' 'e [[Special:Preferences|preferenze]] o pùre si ll'uso 'e tale funzione è stato bloccato.\n\n'O ndirizzo IP attuale è $3, 'o nummero ID d' 'o blocco è #$5.\nPe' piacere avite 'e specificà tutte sti dettaglie ccà ncoppa quanno facite cocche dumanna.",
+       "autoblockedtext": "Ll'IP vuosto è stato bloccato pecché 'o steva ausanno n'atu utente, ch'è stato bloccato 'a $1.\n\n'O mutivo d' 'o blocco è chesto:\n\n:''$2''\n\n* 'O blocco è abbiate: $8\n* 'O blocco fernesce: $6\n* Tiempo 'e blocco: $7\n\nPutite cuntattà $1 o n'atu [[{{MediaWiki:Grouppage-sysop}}|ammenistratore]] pe' discutere chisto blocco.\n\nVedite c' 'a funzione \"Scrivete a ll'utente\" è attiva sule si avite messe 'nu ndirizzo e-mail buono dint' 'e vostre [[Special:Preferences|preferenze]] e si nun siete state bloccato.\n\n'O ndirizzo IP attuale vostro è $3, 'o nummero ID d' 'o blocco è #$5.\n\nPe' piacere avite 'e specificà tutte sti dettaglie ccà ncoppa quanno facite cocche dumanna.",
        "systemblockedtext": "'O nomme utente d' 'o vuosto o ll'IP address songo stati automaticamente bluccati 'a MediaWiki.\n'O mutivo fosse chesto:\n\n:<em>$2</em>\n\n* Inizio d' 'o blocco: $8\n* Ammatura 'o blocco: $6\n* Intervall' 'e blocco: $7\n\n'O indirizzo IP fusse $3.\nPe piacere, facite specifice tutt' 'e ddettaglie ccà quanno iate a fà na richiesta 'e chiarimiente.",
        "blockednoreason": "nisciuna ragione è stata indicata",
        "whitelistedittext": "Pe' cagnà 'e ppaggene è necessario $1.",
        "blocked-notice-logextract": "St'utente è bloccato mò.\nL'urdemo elemento d' 'o riggistro 'e blocche è ripurtato ccà abbascio p'avé nu riferimento:",
        "clearyourcache": "<strong>Nota:</strong> aroppo sarvate putisse necessità 'e pulezzà 'a caché d' 'o navigatóre pe' vedé 'e cagnamiente. \n*<strong>Firefox / Safari</strong>: sprémme 'o buttóne maiuscole e ffà clic ncopp'a ''Recarreca'', o pure spremme ''Ctrl-F5'' o ''Ctrl-R'' (''⌘-R'' ncopp'a Mac)\n*<strong>Google Chrome''': spremme ''Ctrl-Shift-R'' (''⌘-Shift-R'' ncopp'a nu Mac)\n*<strong>Internet Explorer</strong>: spremme 'o buttóne ''Ctrl'' pe' tramente ca faie click ncopp'a ''Refresh'', o pure spremmere ''Ctrl-F5''\n* <strong>Opera:</strong> Vaje addò 'o <em>Menu → Mpustaziune</em> (<em>Opera → Mpustaziune</em> ncopp' 'o Mac) e po' ncopp'a <em>Privacy & sicurezza → Pulezza date d' 'o browser → Immaggene e file d' 'a cache</em>.",
        "usercssyoucanpreview": "'''Cunziglio:''' spremme 'o buttone 'Vide anteprimma' pe' pruvà 'o CSS nuovo apprimma d' 'o sarvà.",
+       "userjsonyoucanpreview": "<strong>Cunziglio:</strong> premme 'o buttone \"{{int:showpreview}}\" pe' pruvà 'o JSON nuovo apprimma d' 'o sarvà.",
        "userjsyoucanpreview": "'''Cunziglio:''' spremme 'o buttone 'Vide anteprimma' pe' pruvà 'o JavaScript nuovo apprimma d' 'o sarvà.",
        "usercsspreview": "'''Arricuordate ca chest'è sulamente n'anteprimma p' 'o CSS perzunale. 'E cagnamiente nun so' state ancora sarvate!'''",
+       "userjsonpreview": "<strong>Arricuordate ca chest'è sulamente n'anteprimma p' 'o JSON perzunale. 'E cagnamiente nun so' state ancora sarvate!</strong>",
        "userjspreview": "'''Arricuordate ca chest'è sulamente n'anteprimma p' 'o JavaScript perzunale. 'E cagnamiente nun so' state ancora sarvate!'''",
        "sitecsspreview": "'''Arricuordate ca chest'è sulamente n'anteprimma p' 'o CSS. 'E cagnamiente nun so' state ancora sarvate!'''",
+       "sitejsonpreview": "<strong>Arricuordate ca chest'è sulamente n'anteprimma d' 'a configurazzione d' 'o JSON. 'E cagnamiente nun so' state ancora sarvate!</strong>",
        "sitejspreview": "'''Arricuordate ca chest'è sulamente n'anteprimma p' 'o codece JavaScript. 'E cagnamiente nun so' state ancora sarvate!'''",
-       "userinvalidconfigtitle": "'''Attenziò:''' Nun esiste nisciuna skin c' 'o nomme \"$1\". Vide ch' 'e paggene .css e .js personalezzate teneno nu titolo n minucola, p'esempio {{ns:user}}:Esempio/vector.css e nun {{ns:user}}:Esempio/Vector.css.",
+       "userinvalidconfigtitle": "<strong>Attenziò:</strong> Nun esiste nisciuna skin c' 'o nomme \"$1\". Vide ch' 'e paggene .css e .js personalezzate teneno nu titolo ca minuscola, p'esempio {{ns:user}}:Esempio/vector.css (e no {{ns:user}}:Esempio/Vector.css).",
        "updated": "(Agghiurnato)",
        "note": "'''Nota:'''",
        "previewnote": "'''Chesta è sola n'anteprimma; 'e cagnamiénte â paggena nun songo ancora sarvate!'''",
        "yourtext": "'O testo vuosto",
        "storedversion": "A verziona int'a memoria",
        "editingold": "'''Attenziò: staje cagnanno na verziona nun agghiurnata d' 'a paggena. Si 'a sarve accussì, tutte 'e cagnamiente fatte aropp'a sta verziona sarranno sperdute.'''",
+       "unicode-support-fail": "Pare ca 'o browser vostro nun tene 'o supporto pe Unicode. 'E cagnamiente nun so' state sarvate, pecché Unicode è obbligatorio 'a tenè pe mudificà 'e paggene.",
        "yourdiff": "Differenze",
        "copyrightwarning": "Pe' piacere tenite a mmente ca tutte 'e contribbute a {{SITENAME}} songo cunziderate pubbrecate dint'e térmene d'uso d' 'a licienza $2 (vedite $1 pe n'avé cchiù dettaglie).\nSi nun vulite ca 'e testi vuoste fossero cagnate e distribuite 'a uno qualunque senza lémmeto, nun 'e mannate ccà.<br />\nMannanno stu testo dichiarate pùre, sott'a responsabilità vuosta, ch'è stato scritto 'a vuje perzunalmente o pure ca è stato copiato 'a na fonte n pubblico dominio o similarmente libbera.\n'''Nun mannate materiale prutetto 'a copyright senz'avé autorizzaziona!'''",
        "copyrightwarning2": "Pe' piacere tenite a mmente ca tutte 'e contribbute a {{SITENAME}} se ponno cagnà, alterà, o distribbuì pe l'ati cuntribbuttòre.\n\nSi nun vulite ca 'e teste vuoste fossero cagnàte spenzieratamente, nun 'e mannate ccà.<br />\nMannanno stu testo dichiarate pùre, sott'a responsabilità vosta, ch'è stato scritto 'a vuje perzunalmente o pure ca è stato copiato 'a na fonte n pubblico dominio o similarmente libbera (vedete $1 pe' n'avé dettaglie).\n'''Nun mannate materiale prutetto 'a copyright senza n'avé autorizzaziona!'''",
        "longpageerror": "'''Errore: 'o testo mannato è luongo {{PLURAL:$1|1|$1}} kilobyte, ch'è cchiù grosso d' 'a diminziona massima cunzentita ({{PLURAL:$2|1|$2}} kilobyte).'''\n'O testo nun se pò sarvà.",
        "readonlywarning": "<strong>Attenziò</strong>: 'o database è bloccato pe se ffà 'a manutenzione. P' 'o mumento nun se ponno sarvà 'e cagnamiente fatte.\nPe' nun 'e sperdere, copia sti cuntenute dint'a nu file 'e testo e sarvatillo pe' tramente c'aspiette 'o sblocco d' 'o database.\n\nL'ammenistratore 'e sistema ca mpustaje 'o blocco ave scritto sta spiegazione: $1.",
        "protectedpagewarning": "'''Attenziò: sta paggena è stata bloccata 'n modo tale ca sulamente l'utente ch' 'e privilegge d'ammenistratore 'a ponno cagnà.'''\nL'urdemo elemento d' 'o riggistro è scritto ccà abbascio pe' n'avé riferimento:",
-       "semiprotectedpagewarning": "'''Nota:''' Sta paggena è stata bloccata 'n modo ca sulamente l'utente riggistrate 'a ponno cagnà.\nL'urdemo elemento d' 'o riggistro è scritto ccà abbascio pe n'avé nfurmazione:",
+       "semiprotectedpagewarning": "<strong>Nota:</strong> Sta paggena è stata bloccata 'n modo ca sulamente l'utente autoconfermati 'a ponno cagnà. L'urdemo elemento d' 'o riggistro è scritto ccà abbascio pe n'avé nfurmazione:",
        "cascadeprotectedwarning": "<strong>Attenziò:</strong> Sta paggena è stata bloccata 'n modo ca sulamente l'utente ch' 'e [[Special:ListGroupRights|privilegge specifiche]] 'a ponno cagnà. Chesto succiere pecché 'a paggena è appennuta dint'a {{PLURAL:$1|la paggena innecata ccà abbascio, ch'è stata prutetta|'e paggene innecate ccà abbascio, che so' state prutette}} sciglienno 'a prutezione \"ricurziva\":",
        "titleprotectedwarning": "'''Attenziò: sta paggena è stata bloccata 'n modo ca fossero necessarie [[Special:ListGroupRights|deritte specifici]] p' 'a crià.'''\nL'urdemo elemento d' 'o riggistro è riportato ccà abbascio pe nfurmazione:",
        "templatesused": "{{PLURAL:$1|Template|Templates}} ausate 'a chesta paggena:",
        "contentmodelediterror": "Vuje nun putite cagnà sta verziona pecché 'o mudello d' 'e cuntenute è <code>$1</code>, ca cagnasse nu poco nfacc' 'o mudello d' 'a paggena  <code>$2</code> 'e mo.",
        "recreate-moveddeleted-warn": "'''Attenziò: staje a crià na paggena scancellata già.'''\n\nVire si è bbuono 'e cuntinuà a cagnà sta paggena. L'elenco ch' 'e relative scancellamiente e spustamente s'è scritto ccà abbascio pe' ffà comodo:",
        "moveddeleted-notice": "Sta paggena è stata scancellata.\n'A lista d' 'e relative scancellamiente e spustamente sta cca 'bbascio pe' n'avé 'nfurmazione.",
-       "moveddeleted-notice-recent": "Scusate, sta mmasciata è stata scancellata mo mo (dint'a sti 24 ore).\n\nL'aziune 'e scancellazione e spustamento pe' sta paggena so dispunibbele ccà p' 'a cumpretezza.",
+       "moveddeleted-notice-recent": "Scusate, sta paggena è stata scancellata mo mo (dint'a sti 24 ore).\n\nTutte l'azziune 'e scancellazione e spustamento pe' sta paggena so dispunibbele ccà pe' cumpretezza.",
        "log-fulllog": "Vide log sano",
        "edit-hook-aborted": "'O cagnamiento è stato annullato 'a 'o «hook».\nNun dette spiegazione nisciuna.",
        "edit-gone-missing": "Nun se può agghiurnà 'a paggena.\nPare ch' 'è stata scancellata.",
        "postedit-confirmation-created": "'A paggena è stata criata.",
        "postedit-confirmation-restored": "'A paggena è stata arripigliata.",
        "postedit-confirmation-saved": "'O cagnamiento è stato sarvato.",
+       "postedit-confirmation-published": "'E cagnamiente so' state pubbricate.",
        "edit-already-exists": "Nun se può crià na paggena nova.\nEsiste già.",
        "defaultmessagetext": "Mmasciata 'e testo predefinita",
        "content-failed-to-parse": "Nun se può analizzare $2 p' 'o mudello $1: $3",
index b2250c5..0810158 100644 (file)
@@ -20,7 +20,8 @@
                        "Fitoschido",
                        "Vriullop",
                        "Unuaiga",
-                       "Guilhelma"
+                       "Guilhelma",
+                       "Matěj Suchánek"
                ]
        },
        "tog-underline": "Soslinhar los ligams :",
        "title-invalid-characters": "Lo títol  de la pagina demandada conten de caractèrs invalids : « $1 ».",
        "title-invalid-relative": "Lo títol conten un camin relatiu. Los títols relatius (./, ../) son pas valids perque los navigadors web pòdon pas sovent i arribar.",
        "title-invalid-magic-tilde": "Lo títol de la pagina sollicitada conten una sequéncia de tildas pas valida (<nowiki>~~~</nowiki>).",
-       "title-invalid-too-long": "Lo títol de la pagina sollicitada es tròp long. A pas d’excedir  $ 1  {{PLURALA:$1|byte|bytes}} en codificacion UTF-8.",
+       "title-invalid-too-long": "Lo títol de la pagina sollicitada es tròp long. A pas d’excedir $1 {{PLURAL:$1|byte|bytes}} en codificacion UTF-8.",
        "title-invalid-leading-colon": "Lo títol de la pagina sollicitada conten dos ponches a la debuta.",
        "perfcached": "Las donadas seguendas son en cache e benlèu, son pas a jorn. Un maximum de {{PLURAL:$1|un resultat|$1 resultats}} es disponible dins lo cache.",
        "perfcachedts": "Las donadas seguendas son en cache e benlèu, son pas a jorn. Un maximum de {{PLURAL:$1|un resultat|$1 resultats}} es disponible dins lo cache.",
index 621a0af..e9ed794 100644 (file)
@@ -26,7 +26,8 @@
                        "Tow",
                        "Sony dandiwal",
                        "Stephanecbisson",
-                       "Fitoschido"
+                       "Fitoschido",
+                       "Matěj Suchánek"
                ]
        },
        "tog-underline": "ਲਿੰਕ ਹੇਠ-ਲਾਈਨ:",
        "newpageletter": "ਨ",
        "boteditletter": "ਬੋਟ",
        "number_of_watching_users_pageview": "[$1 ਵੇਖ ਰਹੇ ਹਨ {{PLURAL:$1|ਯੂਜ਼ਰ}}]",
-       "rc-change-size-new": "$1 {{PLURAL:$|ਬਾਈਟ|ਬਾਈਟਾਂ}} ਤਬਦੀਲੀ ਤੋਂ ਬਾਅਦ",
+       "rc-change-size-new": "$1 {{PLURAL:$1|ਬਾਈਟ|ਬਾਈਟਾਂ}} ਤਬਦੀਲੀ ਤੋਂ ਬਾਅਦ",
        "newsectionsummary": "/* $1 */ ਨਵਾਂ ਭਾਗ",
        "rc-enhanced-expand": "ਵੇਰਵੇ ਵੇਖਾਓ",
        "rc-enhanced-hide": "ਵੇਰਵਾ ਲੁਕਾਓ",
index ef43e18..3f5a2e7 100644 (file)
@@ -19,7 +19,8 @@
                        "Macofe",
                        "Matma Rex",
                        "Fitoschido",
-                       "Paolo Castellina"
+                       "Paolo Castellina",
+                       "Matěj Suchánek"
                ]
        },
        "tog-underline": "Anliure con la sotliniadura",
        "largefileserver": "St'archivi-sì a resta pì gròss che lòn che la màchina sentral a përmet.",
        "emptyfile": "L'archivi che a l'ha pen-a carià a smija veujd.\nSòn a podrìa esse rivà përchè che chiel a l'ha scrivù mal ël nòm dl'archivi midem.\nPër piasì che a contròla se a l'é pro cost l'archivi che a veul carié.",
        "windows-nonascii-filename": "Sta wiki-sì a manten pa ij nòm d'archivi con caràter speciaj.",
-       "fileexists": "N'archivi con ës nòm-sì a-i é già, për piasì che a contròla <strong>[[:$1]]</strong> se {{GENDER|a}} l'é pa sigur dë vorèj cangelo.\n[[$1|thumb]]",
+       "fileexists": "N'archivi con ës nòm-sì a-i é già, për piasì che a contròla <strong>[[:$1]]</strong> se {{GENDER:|a}} l'é pa sigur dë vorèj cangelo.\n[[$1|thumb]]",
        "filepageexists": "La pàgina ëd descrission për st'archivi-sì a l'é già stàita creà an <strong>[[:$1]]</strong>, mach ch'a-i é gnun archivi ch'as ciama parèj.\nLòn ch'a buta për somari as ës-ciairerà nen ant la pàgina ëd descrission.\nPër podèj buté sò somari a l'ha da modifichesse la pàgina a man.\n[[$1|thumb]]",
        "fileexists-extension": "N'archivi con ës nòm-sì a-i é già: [[$2|thumb]]\n* Nòm dl'archivi ch'as carìa: <strong>[[:$1]]</strong>\n* Nòm dl'archivi ch'a-i é già: <strong>[[:$2]]</strong>\nVeul-lo dle vire dovré un nòm pi esplìssit?",
        "fileexists-thumbnail-yes": "L'archivi a jë smija a na ''figurin-a''. [[$1|thumb]]\nPër piasì, ch'a contròla l'archivi <strong>[[:$1]]</strong>.\nS'a l'é la midema figura a amzura pijn-a, a veul dì ch'a fa nen dë manca dë carié na figurin-a.",
index e0846b2..87c820f 100644 (file)
        "rcfilters-watchlist-showupdated": "Изменения страниц, которые вы не посещали с того момента, как они изменились, выделены <strong>жирным</strong> и отмечены полным маркером.",
        "rcfilters-preference-label": "Скрыть улучшенную версию «Свежих правок»",
        "rcfilters-preference-help": "Откатывает редизайн интерфейса 2017 года и все инструменты, добавленные с тех пор.",
+       "rcfilters-watchlist-preference-label": "Скрыть улучшенную версию Списка наблюдения",
+       "rcfilters-watchlist-preference-help": "Отменяет редизайн интерфейса 2017 года и все инструменты, добавленные тогда и позднее.",
        "rcfilters-filter-showlinkedfrom-label": "Показать правки на ссылаемых страницах",
        "rcfilters-filter-showlinkedfrom-option-label": "<strong>Страницы, на которые ссылается</strong> выбранная",
        "rcfilters-filter-showlinkedto-label": "Показать правки на ссылающихся страницах",
        "apisandbox-continue": "Продолжить",
        "apisandbox-continue-clear": "Очистить",
        "apisandbox-continue-help": "{{int:apisandbox-continue}} [https://www.mediawiki.org/wiki/API:Query#Continuing_queries продолжит] последний запрос; {{int:apisandbox-continue-clear}} очистит связанные с продолжением параметры.",
-       "apisandbox-param-limit": "Введите <kbd>максимальное</kbd> использование максимального предела.",
+       "apisandbox-param-limit": "Введите <kbd>max</kbd> для использования максимального предела.",
        "apisandbox-multivalue-all-namespaces": "$1 (Все пространства имён)",
        "apisandbox-multivalue-all-values": "$1 (Все значения)",
        "booksources": "Источники книг",
        "dellogpage": "Журнал удалений",
        "dellogpagetext": "Ниже приведён журнал последних удалений.",
        "deletionlog": "журнал удалений",
+       "log-name-create": "Журнал создания страниц",
+       "log-description-create": "Ниже приведён список самых свежих созданий страниц.",
+       "logentry-create-create": "$1 {{GENDER:$2|создал|создала}} страницу $3",
        "reverted": "Откачено к ранней версии",
        "deletecomment": "Причина:",
        "deleteotherreason": "Другая причина/дополнение:",
index aa14a38..7e80c08 100644 (file)
        "delete-legend": "مٹاؤ",
        "historyaction-submit": "ݙِکھاؤ",
        "dellogpage": "مٹاوݨ آلی لاگ",
+       "log-name-create": "ورقہ بݨاوݨ آلی لاگ",
        "deletecomment": "سبب:",
        "rollbacklink": "واپس",
        "rollbacklinkcount": "واپس $1 {{PLURAL:$1|تبدیلی|تبدیلیاں}}",
index bb34091..4896672 100644 (file)
@@ -36,7 +36,8 @@
                        "Denisa",
                        "Fanjiayi",
                        "Fitoschido",
-                       "Luanibraj"
+                       "Luanibraj",
+                       "Matěj Suchánek"
                ]
        },
        "tog-underline": "Nënvizimi i lidhjes:",
        "importlogpage": "Regjistri i importeve",
        "importlogpagetext": "Importimet administrative të faqeve me historik redaktimi nga wiki-t e tjera.",
        "import-logentry-upload-detail": "$1 {{PLURAL:$1|version|versione}} u importuan",
-       "import-logentry-interwiki-detail": "$1 {{PLURAL:$!1|version|versione}} u importuan nga $2",
+       "import-logentry-interwiki-detail": "$1 {{PLURAL:$1|version|versione}} u importuan nga $2",
        "javascripttest": "Duke testuar JavaScript",
        "javascripttest-pagetext-unknownaction": "Veprim i panjohur \"$1\".",
        "javascripttest-qunit-intro": "Shiko [$1 dokumentacionin e testimit] në mediawiki.org.",
index fafb19f..38f8e66 100644 (file)
        "whatlinkshere-page": "Ukurasa:",
        "linkshere": "Kurasa zifuatazo zimeunganishwa na '''$1''':",
        "nolinkshere": "Hakuna kurasa zilizounganishwa na '''$2'''.",
-       "nolinkshere-ns": "!!FUZZY!!!!FUZZY!!Hakuna kurasa zilizounganishwa na '''$2''' katika eneo la wiki lililochaguliwa.",
+       "nolinkshere-ns": "Hakuna kurasa zilizounganishwa na '''$2''' katika eneo la wiki lililochaguliwa.",
        "isredirect": "elekeza ukurasa",
        "istemplate": "jumuisho",
        "isimage": "kiungo cha faili",
index 891f425..ea4f828 100644 (file)
@@ -52,7 +52,8 @@
                        "Info-farmer",
                        "Rakeshonwiki",
                        "Kaartic",
-                       "Fitoschido"
+                       "Fitoschido",
+                       "Matěj Suchánek"
                ]
        },
        "tog-underline": "அடிக்கோடிட்டத்தை இணை:",
        "nmembers": "$1 {{PLURAL:$1|உறுப்பினர்|உறுப்பினர்கள்}}",
        "nmemberschanged": "$1 → $2 {{PLURAL:$2|உறுப்பினர்|உறுப்பினர்கள்}}",
        "nrevisions": "{{PLURAL:$1|ஒரு திருத்தம்|$1 திருத்தங்கள்}}",
-       "nimagelinks": "$1 {{PLURAL:$!|பக்கத்தில்|பக்கங்களில்}} பயன்படுத்தப்பட்டது",
+       "nimagelinks": "$1 {{PLURAL:$1|பக்கத்தில்|பக்கங்களில்}} பயன்படுத்தப்பட்டது",
        "ntransclusions": "$1 {{PLURAL:$1|பக்கத்தில்|பக்கங்களில்}} பயன்படுத்தப்பட்டது",
        "specialpage-empty": "இந்தப் புகாருக்குகந்த முடிவுகள் எதுவுமில்லை.",
        "lonelypages": "உறவிலிப் பக்கங்கள்",
index 882964e..422b905 100644 (file)
        "sp-contributions-talk": "Alea",
        "whatlinkshere": "Ngaahi fehokotaki ki heni",
        "whatlinkshere-page": "Peesi:",
-       "linkshere": "!!FUZZY!!ʻOku fehokotaki ki heni ʻa e ngaahi peesi:",
-       "nolinkshere": "!!FUZZY!!ʻOku ʻikai ha ngaahi kupu fehokotaki ki heni.",
+       "linkshere": "ʻOku fehokotaki ki heni ʻa e ngaahi peesi:",
+       "nolinkshere": "ʻOku ʻikai ha ngaahi kupu fehokotaki ki heni.",
        "isredirect": "Peesi leʻei",
        "istemplate": "kātoi",
        "whatlinkshere-links": "← fehokotaki",
index 125e1d1..de47edf 100644 (file)
@@ -17,7 +17,7 @@
        "tog-newpageshidepatrolled": "Èn nén mostrer el djivêye des novelès pådjes les cenes dedja patrouyeyes",
        "tog-hidecategorization": "Èn nén mostrer les categorijhaedjes des pådjes",
        "tog-extendwatchlist": "Ragrandi l' djivêye po mostrer tos les candjmints, nén seulmint les dierins",
-       "tog-usenewrc": "Relére par pådje dins les dierins candjmints et l' djivêye des shuvous (i fåt JavaScript)",
+       "tog-usenewrc": "Rashonner par pådje dins les dierins candjmints et l' djivêye des shuvous (i fåt JavaScript)",
        "tog-numberheadings": "Limerotaedje otomatike des tites",
        "tog-showtoolbar": "Mostrer l' bår d' usteyes e môde candjmint",
        "tog-editondblclick": "Candjî les pådjes avou on dobe-clitch",
@@ -36,7 +36,7 @@
        "tog-enotifminoredits": "M' emiler eto po les ptits candjmints des pådjes u des fitchîs",
        "tog-enotifrevealaddr": "Mostrer mi adresse emile dins les emiles di notifiaedje",
        "tog-shownumberswatching": "Mostrer l' nombe d' uzeus ki shuvèt l' pådje",
-       "tog-oldsig": "Siné pol moumint:",
+       "tog-oldsig": "Siné pol moumint :",
        "tog-fancysig": "Sinateure avou do tecse wiki (sins loyén otomatike)",
        "tog-uselivepreview": "Eployî l' préveyaedje abeye",
        "tog-forceeditsummary": "M' advierti cwand dji lai vude on rascourti",
@@ -46,6 +46,7 @@
        "tog-watchlisthideliu": "Èn nén mostrer les candjmints fwait pa des uzeus edjîstrés",
        "tog-watchlisthideanons": "Èn nén mostrer les candjmints fwait pa des uzeus anonimes",
        "tog-watchlisthidepatrolled": "Èn nén mostrer les candjmints ddja patrouyîs",
+       "tog-watchlisthidecategorization": "Catchî l' categorijhaedje des pådjes",
        "tog-ccmeonemails": "M' evoyî ene copeye des emiles ki dj' evoye ås ôtes",
        "tog-diffonly": "Èn nén håyner l' contnou del pådje pa dzo l' pådje des diferinces",
        "tog-showhiddencats": "Mostrer les categoreyes mucheyes",
        "tog-useeditwarning": "M' advierti cwand dji cwite ene pådje k' a des candjmints nén schapés",
        "underline-always": "Tofer",
        "underline-never": "Måy",
-       "underline-default": "Valixhance do betchteu",
+       "underline-default": "Valixhance del pea u do betchteu",
        "editfont-style": "Stîle del fonte pol boesse di tecse",
+       "editfont-sansserif": "Fonte Sans-serif",
+       "editfont-serif": "Fonte Serif",
        "sunday": "dimegne",
        "monday": "londi",
        "tuesday": "mårdi",
        "searcharticle": "Potchî",
        "history": "Istwere del pådje",
        "history_short": "Istwere",
+       "history_small": "Istwere",
        "updatedmarker": "candjî dispoy mi dierinne vizite",
        "printableversion": "Modêye sicrirece-amiståve",
        "permalink": "Hårdêye viè cisse modêye ci",
        "view": "Vey",
        "view-foreign": "Vey so $1",
        "edit": "Candjî",
+       "edit-local": "Candjî l' discrijhaedje locå",
        "create": "Ahiver",
+       "create-local": "Radjouter on discrijhaedje locå",
        "delete": "Disfacer",
        "undelete_short": "Rapexhî {{PLURAL:$1|on candjmint|$1 candjmints}}",
        "viewdeleted_short": "Vey {{PLURAL:$1|on candjmint disfacé|$1 candjmints disfacés}}",
        "copyrightpage": "{{ns:project}}:Abondroets",
        "currentevents": "Actouwålités",
        "currentevents-url": "Project:Actouwålités",
+       "disclaimers": "Adviertances",
+       "disclaimerpage": "Project: Djeneråles adviertances",
        "edithelp": "Aidance",
        "helppage-top-gethelp": "Aidance",
        "mainpage": "Mwaisse pådje",
        "mainpage-description": "Mwaisse pådje",
        "portal": "Inte di nozôtes",
        "portal-url": "Project:Inte di nozôtes",
+       "privacy": "Politike des scretès dinêyes",
+       "privacypage": "Project: Politike des scretès dinêyes",
        "badaccess": "Åk n' a nén stî avou les permissions",
        "badaccess-groups": "L' accion ki vos avoz dmandé est limitêye ås uzeus {{PLURAL:$2|do groupe|des groupes}}: $1.",
        "versionrequired": "I vs fåt l' modêye $1 di MediaWiki",
        "perfcachedts": "Les dnêyes ki shuvèt c' est ene copeye e muchete, ey elle ont stî metowes a djoû pol dierin côp li $1. Li muchete a-st on macsimom {{PLURAL:$4|d' on rzultat|di $4 rizultats}}.",
        "viewsource": "Vey côde sourdant",
        "viewsource-title": "Côde sourdant di «$1»",
-       "viewsourcetext": "Loukîz li contnou d' l’ årtike, et s’ li rcopyî si vos vloz, por vos bouter dsu foû des fyis:",
-       "protectedinterface": "Cisse pådje ci dene on tecse d' eterface pol programe, eyet elle a stî protedjeye po s' waeranti siconte des abus.",
+       "viewsourcetext": "Vos ploz rwaitî et rcopyî li contnou di cisse pådje ci.",
+       "viewyourtext": "Vos ploz rwaitî et rcopyî li contnou d' <strong>vosse ovraedje</strong> so cisse pådje ci.",
+       "protectedinterface": "Cisse pådje ci dene on tecse d' eterface pol programe, eyet elle a stî protedjeye po s' waeranti siconte des abus. Po radjouter u candjî des ratournaedjes so tos les wikis, i vos fåt eployî [https://translatewiki.net/ translatewiki.net], li pordjet d' ratournaedje coinrece da MediaWiki.",
        "editinginterface": "<strong>Asteme:</strong> Vos estoz ki candje ene pådje eployeye po fé l' tecse po l' eterface do programe.\nLes candjmints ki vos frîz vont candjî l' rivnance di l' eterface po ls ôtes uzeus do wiki.",
+       "translateinterface": "Po radjouter u candjî des ratournaedjes so tos les wikis, eployîz [https://translatewiki.net/ translatewiki.net], li pordjet d' ratournaedje coinrece da MediaWiki.",
        "cascadeprotected": "Cisse pådje ci a stî protedjeye siconte des candjmints, pask' ele est eploye ådvins {{PLURAL:$1|del pådje shuvante k' est protedjeye|des pådjes shuvantes ki sont protedjeyes}} avou l' tchuze «e cascåde» en alaedje:\n$2",
        "logouttext": "<strong>Vos vs avoz dislodjî.</strong>\n\nNotez ki des pådjes k' i gn a si pôrént continouwer a vey come si vos estîz elodjî, disk' a tant ki vos vudrîz l' muchete di vosse betchteu waibe.",
        "welcomeuser": "Bénvnowe, $1!",
        "page_first": "prumî",
        "page_last": "dierin",
        "histlegend": "Tchoezi les modêyes a comparer: clitchîz so les botons radio des deus modêyes\nki vos vloz comparer et s' tchôkîz sol tape «enter» ou clitchîz sol\nboton do dzo.<br />\nLedjinde: '''({{int:cur}})''' = diferince avou l' modêye d' asteure, '''({{int:last}})''' = diferince avou l' modêye di dvant, '''{{int:minoreditletter}}''' = pitit candjmint d' rén do tot.",
-       "history-fieldset-title": "Naivyî l' istwere des candjmints",
+       "history-fieldset-title": "Cachî dins l' istwere des candjmints",
        "history-show-deleted": "Disfacés seulmint",
-       "histfirst": "li pus vî",
-       "histlast": "li dierin",
+       "histfirst": "les pus vîs",
+       "histlast": "les dierins",
        "historysize": "({{PLURAL:$1|1 octet|$1 octets}})",
        "historyempty": "(vude)",
        "history-feed-title": "Istwere des modêyes",
        "recentchanges-legend-heading": "<strong>Ledjinde:</strong>",
        "recentchanges-legend-newpage": "{{int:recentchanges-label-newpage}} (vey eto l' [[Special:NewPages|djivêye des nouvès pådjes]])",
        "recentchanges-submit": "Vey",
-       "rcnotefrom": "Chal pa dzo les candjmints dispoy li '''$2''' (disk' a '''$1''' di mostrés).",
+       "rcnotefrom": "Chal pa dzo {{PLURAL:$5|li candjmint fwait|les candjmints fwaits}} dispoy li <strong>$3, $4</strong> (afitchîs disk a <strong>$1</strong>).",
        "rclistfrom": "Mostrer les candjmints k' i gn a yeu a pårti do $3 $2",
        "rcshowhideminor": "$1 candjmints mineurs",
        "rcshowhideminor-show": "Mostrer",
        "recentchangeslinked-feed": "Candjmints aloyîs",
        "recentchangeslinked-toolbox": "Candjmints aloyîs",
        "recentchangeslinked-title": "Candjmints aloyîs a «$1»",
-       "recentchangeslinked-summary": "Çouchal c' est ene djivêye des candjmints k' ont stî fwaits dierinnmint a des pådjes aloyeyes a pårti d' ene pådje dinêye (ou mimbes d' ene categoreye dinêye).\nLes pådjes ki [[Special:Watchlist|vos shuvoz]] sont-st e '''cråssès letes'''.",
+       "recentchangeslinked-summary": "Intrez on no d' pådje po vey les candjmints k' ont stî fwaits dierinnmint a des pådjes aloyeyes a pårti u viè cisse pådje ci (po vey les mimbes d' ene categoreye dinêye, intrez {{ns:category}}:No del categoreye). Les pådjes ki [[Special:Watchlist|vos shuvoz]] et k' ont stî candjeyes sont-st e <strong>cråssès letes</strong>.",
        "recentchangeslinked-page": "No del pådje:",
        "recentchangeslinked-to": "Mostere les candjmints des pådjes avou on loyén viè l' pådje dinêye purade k' å rviè",
        "upload": "Eberweter on fitchî",
        "contributions-title": "Djivêye des ovraedjes di l' {{GENDER:$1|uzeu|uzeuse}} $1",
        "mycontris": "Mi ovraedje",
        "anoncontribs": "Mi ovraedje",
-       "contribsub2": "Po l' uzeu $1 ($2)",
+       "contribsub2": "Po {{GENDER:$3|$1}} ($2)",
        "nocontribs": "Nou candjmint di trové ki corespondreut a ç' critere la.",
        "uctop": "(dierinne)",
        "month": "dispu l' moes (et pus timpe)",
index f409dcc..5bb1a43 100644 (file)
        "whatlinkshere": "链入页面",
        "whatlinkshere-title": "链接至“$1”的页面",
        "whatlinkshere-page": "页面:",
-       "linkshere": "以下页面链接至<strong>$1</strong>:",
-       "nolinkshere": "没有页面链接至<strong>$1</strong>。",
+       "linkshere": "以下页面链接至<strong>$2</strong>:",
+       "nolinkshere": "没有页面链接至<strong>$2</strong>。",
        "nolinkshere-ns": "在所选的名字空间内没有页面链接到<strong>$2</strong>。",
        "isredirect": "重定向页面",
        "istemplate": "嵌入",
index 1b05e1e..acc66c5 100644 (file)
@@ -24,6 +24,8 @@
  * @author Katie Filbert < aude.wiki@gmail.com >
  */
 
+use MediaWiki\MediaWikiServices;
+
 require_once __DIR__ . '/Maintenance.php';
 
 class PopulateInterwiki extends Maintenance {
@@ -119,6 +121,7 @@ TEXT
                        }
                }
 
+               $lookup = MediaWikiServices::getInstance()->getInterwikiLookup();
                foreach ( $data as $d ) {
                        $prefix = $d['prefix'];
 
@@ -142,7 +145,7 @@ TEXT
                                );
                        }
 
-                       Interwiki::invalidateCache( $prefix );
+                       $lookup->invalidateCache( $prefix );
                }
 
                $this->output( "Interwiki links are populated.\n" );
index 0d41c52..947be75 100644 (file)
@@ -56,8 +56,6 @@ class InterwikiTest extends MediaWikiTestCase {
        }
 
        public function testDatabaseStorage() {
-               $this->markTestSkipped( 'Needs I37b8e8018b3 <https://gerrit.wikimedia.org/r/#/c/270555/>' );
-
                // NOTE: database setup is expensive, so we only do
                //  it once and run all the tests in one go.
                $dewiki = [
@@ -115,7 +113,7 @@ class InterwikiTest extends MediaWikiTestCase {
                $this->assertSame( true, $interwiki->isLocal(), 'isLocal' );
                $this->assertSame( false, $interwiki->isTranscludable(), 'isTranscludable' );
 
-               Interwiki::invalidateCache( 'de' );
+               $interwikiLookup->invalidateCache( 'de' );
                $this->assertNotSame( $interwiki, $interwikiLookup->fetch( 'de' ), 'invalidate cache' );
        }
 
index ba28828..acaeb02 100644 (file)
@@ -2,44 +2,72 @@
 
 /**
  * @group HashRing
+ * @covers HashRing
  */
 class HashRingTest extends PHPUnit\Framework\TestCase {
 
        use MediaWikiCoversValidator;
 
-       /**
-        * @covers HashRing
-        */
-       public function testHashRing() {
-               $ring = new HashRing( [ 's1' => 1, 's2' => 1, 's3' => 2, 's4' => 2, 's5' => 2, 's6' => 3 ] );
+       public function testHashRingSerialize() {
+               $map = [ 's1' => 3, 's2' => 10, 's3' => 2, 's4' => 10, 's5' => 2, 's6' => 3 ];
+               $ring = new HashRing( $map, 'md5' );
+
+               $serialized = serialize( $ring );
+               $ringRemade = unserialize( $serialized );
+
+               for ( $i = 0; $i < 100; $i++ ) {
+                       $this->assertEquals(
+                               $ring->getLocation( "hello$i" ),
+                               $ringRemade->getLocation( "hello$i" ),
+                               'Items placed at proper locations'
+                       );
+               }
+       }
+
+       public function testHashRingMapping() {
+               // SHA-1 based and weighted
+               $ring = new HashRing(
+                       [ 's1' => 1, 's2' => 1, 's3' => 2, 's4' => 2, 's5' => 2, 's6' => 3, 's7' => 0 ],
+                       'sha1'
+               );
+
+               $this->assertEquals(
+                       [ 's1' => 1, 's2' => 1, 's3' => 2, 's4' => 2, 's5' => 2, 's6' => 3 ],
+                       $ring->getLocationWeights(),
+                       'Normalized location weights'
+               );
 
                $locations = [];
-               for ( $i = 0; $i < 20; $i++ ) {
+               for ( $i = 0; $i < 25; $i++ ) {
                        $locations[ "hello$i"] = $ring->getLocation( "hello$i" );
                }
                $expectedLocations = [
-                       "hello0" => "s5",
+                       "hello0" => "s4",
                        "hello1" => "s6",
-                       "hello2" => "s2",
-                       "hello3" => "s5",
+                       "hello2" => "s3",
+                       "hello3" => "s6",
                        "hello4" => "s6",
                        "hello5" => "s4",
-                       "hello6" => "s5",
+                       "hello6" => "s3",
                        "hello7" => "s4",
-                       "hello8" => "s5",
-                       "hello9" => "s5",
+                       "hello8" => "s3",
+                       "hello9" => "s3",
                        "hello10" => "s3",
-                       "hello11" => "s6",
-                       "hello12" => "s1",
-                       "hello13" => "s3",
-                       "hello14" => "s3",
+                       "hello11" => "s5",
+                       "hello12" => "s4",
+                       "hello13" => "s5",
+                       "hello14" => "s2",
                        "hello15" => "s5",
-                       "hello16" => "s4",
-                       "hello17" => "s6",
-                       "hello18" => "s6",
-                       "hello19" => "s3"
+                       "hello16" => "s6",
+                       "hello17" => "s5",
+                       "hello18" => "s1",
+                       "hello19" => "s1",
+                       "hello20" => "s6",
+                       "hello21" => "s5",
+                       "hello22" => "s3",
+                       "hello23" => "s4",
+                       "hello24" => "s1"
                ];
-
                $this->assertEquals( $expectedLocations, $locations, 'Items placed at proper locations' );
 
                $locations = [];
@@ -48,12 +76,252 @@ class HashRingTest extends PHPUnit\Framework\TestCase {
                }
 
                $expectedLocations = [
-                       "hello0" => [ "s5", "s6" ],
-                       "hello1" => [ "s6", "s4" ],
-                       "hello2" => [ "s2", "s1" ],
-                       "hello3" => [ "s5", "s6" ],
-                       "hello4" => [ "s6", "s4" ],
+                       "hello0" => [ "s4", "s5" ],
+                       "hello1" => [ "s6", "s5" ],
+                       "hello2" => [ "s3", "s1" ],
+                       "hello3" => [ "s6", "s5" ],
+                       "hello4" => [ "s6", "s3" ],
                ];
                $this->assertEquals( $expectedLocations, $locations, 'Items placed at proper locations' );
        }
+
+       /**
+        * @dataProvider providor_getHashLocationWeights
+        */
+       public function testHashRingRatios( $locations, $expectedHits ) {
+               $ring = new HashRing( $locations, 'whirlpool' );
+
+               $locationStats = array_fill_keys( array_keys( $locations ), 0 );
+               for ( $i = 0; $i < 10000; ++$i ) {
+                       ++$locationStats[$ring->getLocation( "key-$i" )];
+               }
+               $this->assertEquals( $expectedHits, $locationStats );
+       }
+
+       public static function providor_getHashLocationWeights() {
+               return [
+                       [
+                               [ 'big' => 10, 'medium' => 5, 'small' => 1 ],
+                               [ 'big' => 6037, 'medium' => 3314, 'small' => 649 ]
+                       ]
+               ];
+       }
+
+       /**
+        * @dataProvider providor_getHashLocationWeights2
+        */
+       public function testHashRingRatios2( $locations, $expected ) {
+               $ring = new HashRing( $locations, 'sha1' );
+               $locationStats = array_fill_keys( array_keys( $locations ), 0 );
+               for ( $i = 0; $i < 1000; ++$i ) {
+                       foreach ( $ring->getLocations( "key-$i", 3 ) as $location ) {
+                               ++$locationStats[$location];
+                       }
+               }
+               $this->assertEquals( $expected, $locationStats );
+       }
+
+       public static function providor_getHashLocationWeights2() {
+               return [
+                       [
+                               [ 'big1' => 10, 'big2' => 10, 'big3' => 10, 'small1' => 1, 'small2' => 1 ],
+                               [ 'big1' => 929, 'big2' => 899, 'big3' => 887, 'small1' => 143, 'small2' => 142 ]
+                       ]
+               ];
+       }
+
+       public function testHashRingEjection() {
+               $map = [ 's1' => 5, 's2' => 5, 's3' => 10, 's4' => 10, 's5' => 5, 's6' => 5 ];
+               $ring = new HashRing( $map, 'md5' );
+
+               $ring->ejectFromLiveRing( 's3', 30 );
+               $ring->ejectFromLiveRing( 's6', 15 );
+
+               $this->assertEquals(
+                       [ 's1' => 5, 's2' => 5, 's4' => 10, 's5' => 5 ],
+                       $ring->getLiveLocationWeights(),
+                       'Live location weights'
+               );
+
+               for ( $i = 0; $i < 100; ++$i ) {
+                       $key = "key-$i";
+
+                       $this->assertNotEquals( 's3', $ring->getLiveLocation( $key ), 'ejected' );
+                       $this->assertNotEquals( 's6', $ring->getLiveLocation( $key ), 'ejected' );
+
+                       if ( !in_array( $ring->getLocation( $key ), [ 's3', 's6' ], true ) ) {
+                               $this->assertEquals(
+                                       $ring->getLocation( $key ),
+                                       $ring->getLiveLocation( $key ),
+                                       "Live ring otherwise matches (#$i)"
+                               );
+                               $this->assertEquals(
+                                       $ring->getLocations( $key, 1 ),
+                                       $ring->getLiveLocations( $key, 1 ),
+                                       "Live ring otherwise matches (#$i)"
+                               );
+                       }
+               }
+       }
+
+       public function testHashRingCollision() {
+               $ring1 = new HashRing( [ 0 => 1, 6497 => 1 ] );
+               $ring2 = new HashRing( [ 6497 => 1, 0 => 1 ] );
+
+               for ( $i = 0; $i < 100; ++$i ) {
+                       $this->assertEquals( $ring1->getLocation( $i ), $ring2->getLocation( $i ) );
+               }
+       }
+
+       public function testHashRingKetamaMode() {
+               // Same as https://github.com/RJ/ketama/blob/master/ketama.servers
+               $map = [
+                       '10.0.1.1:11211' => 600,
+                       '10.0.1.2:11211' => 300,
+                       '10.0.1.3:11211' => 200,
+                       '10.0.1.4:11211' => 350,
+                       '10.0.1.5:11211' => 1000,
+                       '10.0.1.6:11211' => 800,
+                       '10.0.1.7:11211' => 950,
+                       '10.0.1.8:11211' => 100
+               ];
+               $ring = new HashRing( $map, 'md5' );
+               $wrapper = \Wikimedia\TestingAccessWrapper::newFromObject( $ring );
+
+               $ketama_test = function ( $count ) use ( $wrapper ) {
+                       $baseRing = $wrapper->baseRing;
+
+                       $lines = [];
+                       for ( $key = 0; $key < $count; ++$key ) {
+                               $location = $wrapper->getLocation( $key );
+
+                               $itemPos = $wrapper->getItemPosition( $key );
+                               $nodeIndex = $wrapper->findNodeIndexForPosition( $itemPos, $baseRing );
+                               $nodePos = $baseRing[$nodeIndex][HashRing::KEY_POS];
+
+                               $lines[] = sprintf( "%u %u %s\n", $itemPos, $nodePos, $location );
+                       }
+
+                       return "\n" . implode( '', $lines );
+               };
+
+               // Known correct values generated from C code:
+               // https://github.com/RJ/ketama/blob/master/libketama/ketama_test.c
+               $expected = <<<EOT
+
+2216742351 2217271743 10.0.1.1:11211
+943901380 949045552 10.0.1.5:11211
+2373066440 2374693370 10.0.1.6:11211
+2127088620 2130338203 10.0.1.6:11211
+2046197672 2051996197 10.0.1.7:11211
+2134629092 2135172435 10.0.1.1:11211
+470382870 472541453 10.0.1.7:11211
+1608782991 1609789509 10.0.1.3:11211
+2516119753 2520092206 10.0.1.2:11211
+3465331781 3466294492 10.0.1.4:11211
+1749342675 1753760600 10.0.1.5:11211
+1136464485 1137779711 10.0.1.1:11211
+3620997826 3621580689 10.0.1.7:11211
+283385029 285581365 10.0.1.6:11211
+2300818346 2302165654 10.0.1.5:11211
+2132603803 2134614475 10.0.1.8:11211
+2962705863 2969767984 10.0.1.2:11211
+786427760 786565633 10.0.1.5:11211
+4095887727 4096760944 10.0.1.6:11211
+2906459679 2906987515 10.0.1.6:11211
+137884056 138922607 10.0.1.4:11211
+81549628 82491298 10.0.1.6:11211
+3530020790 3530525869 10.0.1.6:11211
+4231817527 4234960467 10.0.1.7:11211
+2011099423 2014738083 10.0.1.7:11211
+107620750 120968799 10.0.1.6:11211
+3979113294 3981926993 10.0.1.4:11211
+273671938 276355738 10.0.1.4:11211
+4032816947 4033300359 10.0.1.5:11211
+464234862 466093615 10.0.1.1:11211
+3007059764 3007671127 10.0.1.5:11211
+542337729 542491760 10.0.1.7:11211
+4040385635 4044064727 10.0.1.5:11211
+3319802648 3320661601 10.0.1.7:11211
+1032153571 1035085391 10.0.1.1:11211
+3543939100 3545608820 10.0.1.5:11211
+3876899353 3885324049 10.0.1.2:11211
+3771318181 3773259708 10.0.1.8:11211
+3457906597 3459285639 10.0.1.5:11211
+3028975062 3031083168 10.0.1.7:11211
+244467158 250943416 10.0.1.5:11211
+1604785716 1609789509 10.0.1.3:11211
+3905343649 3905751132 10.0.1.1:11211
+1713497623 1725056963 10.0.1.5:11211
+1668356087 1668827816 10.0.1.5:11211
+3427369836 3438933308 10.0.1.1:11211
+2515850457 2520092206 10.0.1.2:11211
+3886138983 3887390208 10.0.1.1:11211
+4019334756 4023153300 10.0.1.8:11211
+1170561012 1170785765 10.0.1.7:11211
+1841809344 1848425105 10.0.1.6:11211
+973223976 973369204 10.0.1.1:11211
+358093210 359562433 10.0.1.6:11211
+378350808 380841931 10.0.1.5:11211
+4008477862 4012085095 10.0.1.7:11211
+1027226549 1028630030 10.0.1.6:11211
+2386583967 2387706118 10.0.1.1:11211
+522892146 524831677 10.0.1.7:11211
+3779194982 3788912803 10.0.1.5:11211
+3764731657 3771312500 10.0.1.7:11211
+184756999 187529415 10.0.1.6:11211
+838351231 845886003 10.0.1.3:11211
+2827220548 2828019973 10.0.1.6:11211
+3604721411 3607668249 10.0.1.6:11211
+472866282 475506254 10.0.1.5:11211
+2752268796 2754833471 10.0.1.5:11211
+1791464754 1795042583 10.0.1.7:11211
+3029359475 3031083168 10.0.1.7:11211
+3633378211 3639985542 10.0.1.6:11211
+3148267284 3149217023 10.0.1.6:11211
+163887996 166705043 10.0.1.7:11211
+3642803426 3649125922 10.0.1.7:11211
+3901799218 3902199881 10.0.1.7:11211
+418045394 425867331 10.0.1.6:11211
+346775981 348578169 10.0.1.6:11211
+368352208 372224616 10.0.1.7:11211
+2643711995 2644259911 10.0.1.5:11211
+2032983336 2033860601 10.0.1.6:11211
+3567842357 3572867530 10.0.1.2:11211
+1024982737 1028630030 10.0.1.6:11211
+933966832 938106828 10.0.1.7:11211
+2102520899 2103402846 10.0.1.7:11211
+3537205399 3538094881 10.0.1.7:11211
+2311233534 2314593262 10.0.1.1:11211
+2500514664 2503565236 10.0.1.7:11211
+1091958846 1093484995 10.0.1.6:11211
+3984972691 3987453644 10.0.1.1:11211
+2669994439 2670911201 10.0.1.4:11211
+2846111786 2846115813 10.0.1.5:11211
+1805010806 1808593732 10.0.1.8:11211
+1587024774 1587746378 10.0.1.5:11211
+3214549588 3215619351 10.0.1.2:11211
+1965214866 1970922428 10.0.1.7:11211
+1038671000 1040777775 10.0.1.7:11211
+820820468 823114475 10.0.1.6:11211
+2722835329 2723166435 10.0.1.5:11211
+1602053414 1604196066 10.0.1.5:11211
+1330835426 1335097278 10.0.1.5:11211
+556547565 557075710 10.0.1.4:11211
+2977587884 2978402952 10.0.1.1:11211
+
+EOT;
+
+               $this->assertEquals( $expected, $ketama_test( 100 ), 'Ketama mode (diff check)' );
+
+               // Hash of known correct values from C code
+               $this->assertEquals(
+                       'c69ac9eb7a8a630c0cded201cefeaace',
+                       md5( $ketama_test( 1e5 ) ),
+                       'Ketama mode (large, MD5 check)'
+               );
+
+               // Slower, full upstream MD5 check, manually verified 3/21/2018
+               // $this->assertEquals( '5672b131391f5aa2b280936aec1eea74', md5( $ketama_test( 1e6 ) ) );
+       }
 }
index 03c7b0c..9ec660e 100644 (file)
 
 /**
  * Tests for IEUrlExtension::findIE6Extension
- * @todo tests below for findIE6Extension should be split into...
- *    ...a dataprovider and test method.
  */
 class IEUrlExtensionTest extends PHPUnit\Framework\TestCase {
 
        use MediaWikiCoversValidator;
 
-       /**
-        * @covers IEUrlExtension::findIE6Extension
-        */
-       public function testSimple() {
-               $this->assertEquals(
-                       'y',
-                       IEUrlExtension::findIE6Extension( 'x.y' ),
-                       'Simple extension'
-               );
-       }
-
-       /**
-        * @covers IEUrlExtension::findIE6Extension
-        */
-       public function testSimpleNoExt() {
-               $this->assertEquals(
-                       '',
-                       IEUrlExtension::findIE6Extension( 'x' ),
-                       'No extension'
-               );
-       }
-
-       /**
-        * @covers IEUrlExtension::findIE6Extension
-        */
-       public function testEmpty() {
-               $this->assertEquals(
-                       '',
-                       IEUrlExtension::findIE6Extension( '' ),
-                       'Empty string'
-               );
-       }
-
-       /**
-        * @covers IEUrlExtension::findIE6Extension
-        */
-       public function testQuestionMark() {
-               $this->assertEquals(
-                       '',
-                       IEUrlExtension::findIE6Extension( '?' ),
-                       'Question mark only'
-               );
-       }
-
-       /**
-        * @covers IEUrlExtension::findIE6Extension
-        */
-       public function testExtQuestionMark() {
-               $this->assertEquals(
-                       'x',
-                       IEUrlExtension::findIE6Extension( '.x?' ),
-                       'Extension then question mark'
-               );
-       }
-
-       /**
-        * @covers IEUrlExtension::findIE6Extension
-        */
-       public function testQuestionMarkExt() {
-               $this->assertEquals(
-                       'x',
-                       IEUrlExtension::findIE6Extension( '?.x' ),
-                       'Question mark then extension'
-               );
-       }
-
-       /**
-        * @covers IEUrlExtension::findIE6Extension
-        */
-       public function testInvalidChar() {
-               $this->assertEquals(
-                       '',
-                       IEUrlExtension::findIE6Extension( '.x*' ),
-                       'Extension with invalid character'
-               );
-       }
-
-       /**
-        * @covers IEUrlExtension::findIE6Extension
-        */
-       public function testInvalidCharThenExtension() {
-               $this->assertEquals(
-                       'x',
-                       IEUrlExtension::findIE6Extension( '*.x' ),
-                       'Invalid character followed by an extension'
-               );
-       }
-
-       /**
-        * @covers IEUrlExtension::findIE6Extension
-        */
-       public function testMultipleQuestionMarks() {
-               $this->assertEquals(
-                       'c',
-                       IEUrlExtension::findIE6Extension( 'a?b?.c?.d?e?f' ),
-                       'Multiple question marks'
-               );
-       }
-
-       /**
-        * @covers IEUrlExtension::findIE6Extension
-        */
-       public function testExeException() {
-               $this->assertEquals(
-                       'd',
-                       IEUrlExtension::findIE6Extension( 'a?b?.exe?.d?.e' ),
-                       '.exe exception'
-               );
-       }
-
-       /**
-        * @covers IEUrlExtension::findIE6Extension
-        */
-       public function testExeException2() {
-               $this->assertEquals(
-                       'exe',
-                       IEUrlExtension::findIE6Extension( 'a?b?.exe' ),
-                       '.exe exception 2'
-               );
-       }
-
-       /**
-        * @covers IEUrlExtension::findIE6Extension
-        */
-       public function testHash() {
-               $this->assertEquals(
-                       '',
-                       IEUrlExtension::findIE6Extension( 'a#b.c' ),
-                       'Hash character preceding extension'
-               );
-       }
-
-       /**
-        * @covers IEUrlExtension::findIE6Extension
-        */
-       public function testHash2() {
-               $this->assertEquals(
-                       '',
-                       IEUrlExtension::findIE6Extension( 'a?#b.c' ),
-                       'Hash character preceding extension 2'
-               );
-       }
-
-       /**
-        * @covers IEUrlExtension::findIE6Extension
-        */
-       public function testDotAtEnd() {
-               $this->assertEquals(
-                       '',
-                       IEUrlExtension::findIE6Extension( '.' ),
-                       'Dot at end of string'
-               );
-       }
-
-       /**
-        * @covers IEUrlExtension::findIE6Extension
-        */
-       public function testTwoDots() {
-               $this->assertEquals(
-                       'z',
-                       IEUrlExtension::findIE6Extension( 'x.y.z' ),
-                       'Two dots'
-               );
-       }
-
-       /**
-        * @covers IEUrlExtension::findIE6Extension
-        */
-       public function testScriptQuery() {
-               $this->assertEquals(
-                       'php',
-                       IEUrlExtension::findIE6Extension( 'example.php?foo=a&bar=b' ),
-                       'Script with query'
-               );
-       }
-
-       /**
-        * @covers IEUrlExtension::findIE6Extension
-        */
-       public function testEscapedScriptQuery() {
-               $this->assertEquals(
-                       '',
-                       IEUrlExtension::findIE6Extension( 'example%2Ephp?foo=a&bar=b' ),
-                       'Script with urlencoded dot and query'
-               );
-       }
-
-       /**
-        * @covers IEUrlExtension::findIE6Extension
-        */
-       public function testEscapedScriptQueryDot() {
-               $this->assertEquals(
-                       'y',
-                       IEUrlExtension::findIE6Extension( 'example%2Ephp?foo=a.x&bar=b.y' ),
-                       'Script with urlencoded dot and query with dot'
+       public function provideFindIE6Extension() {
+               return [
+                       // url, expected, message
+                       [ 'x.y', 'y', 'Simple extension' ],
+                       [ 'x', '', 'No extension' ],
+                       [ '', '', 'Empty string' ],
+                       [ '?', '', 'Question mark only' ],
+                       [ '.x?', 'x', 'Extension then question mark' ],
+                       [ '?.x', 'x', 'Question mark then extension' ],
+                       [ '.x*', '', 'Extension with invalid character' ],
+                       [ '*.x', 'x', 'Invalid character followed by an extension' ],
+                       [ 'a?b?.c?.d?e?f', 'c', 'Multiple question marks' ],
+                       [ 'a?b?.exe?.d?.e', 'd', '.exe exception' ],
+                       [ 'a?b?.exe', 'exe', '.exe exception 2' ],
+                       [ 'a#b.c', '', 'Hash character preceding extension' ],
+                       [ 'a?#b.c', '', 'Hash character preceding extension 2' ],
+                       [ '.', '', 'Dot at end of string' ],
+                       [ 'x.y.z', 'z', 'Two dots' ],
+                       [ 'example.php?foo=a&bar=b', 'php', 'Script with query' ],
+                       [ 'example%2Ephp?foo=a&bar=b', '', 'Script with urlencoded dot and query' ],
+                       [ 'example%2Ephp?foo=a.x&bar=b.y', 'y', 'Script with urlencoded dot and query with dot' ],
+               ];
+       }
+
+       /**
+        * @covers IEUrlExtension::findIE6Extension
+        * @dataProvider provideFindIE6Extension
+        */
+       public function testFindIE6Extension( $url, $expected, $message ) {
+               $this->assertEquals(
+                       $expected,
+                       IEUrlExtension::findIE6Extension( $url ),
+                       $message
                );
        }
 }
index 11c1097..84a4c46 100644 (file)
  */
 class LanguageCrhTest extends LanguageClassesTestCase {
        /**
-        * @dataProvider provideAutoConvertToAllVariants
+        * @dataProvider provideAutoConvertToAllVariantsByWord
         * @covers Language::autoConvertToAllVariants
+        *
+        * Test individual words and test minimal contextual transforms
+        * by creating test strings "<cyrillic> <latin>" and
+        * "<latin> <cyrillic>" and then converting to all variants.
         */
-       public function testAutoConvertToAllVariants( $result, $value ) {
+       public function testAutoConvertToAllVariantsByWord( $cyrl, $lat ) {
+               $value = $lat;
+               $result = [
+                       'crh'      => $value,
+                       'crh-cyrl' => $cyrl,
+                       'crh-latn' => $lat,
+                       ];
+               $this->assertEquals( $result, $this->getLang()->autoConvertToAllVariants( $value ) );
+
+               $value = $cyrl;
+               $result = [
+                       'crh'      => $value,
+                       'crh-cyrl' => $cyrl,
+                       'crh-latn' => $lat,
+                       ];
+               $this->assertEquals( $result, $this->getLang()->autoConvertToAllVariants( $value ) );
+
+               $value = $cyrl . ' ' . $lat;
+               $result = [
+                       'crh'      => $value,
+                       'crh-cyrl' => $cyrl . ' ' . $cyrl,
+                       'crh-latn' => $lat . ' ' . $lat,
+                       ];
+               $this->assertEquals( $result, $this->getLang()->autoConvertToAllVariants( $value ) );
+
+               $value = $lat . ' ' . $cyrl;
+               $result = [
+                       'crh'      => $value,
+                       'crh-cyrl' => $cyrl . ' ' . $cyrl,
+                       'crh-latn' => $lat . ' ' . $lat,
+                       ];
                $this->assertEquals( $result, $this->getLang()->autoConvertToAllVariants( $value ) );
        }
 
-       public static function provideAutoConvertToAllVariants() {
+       public static function provideAutoConvertToAllVariantsByWord() {
+               return [
+                       // general words, covering more of the alphabet
+                       [ 'рузгярнынъ', 'ruzgârnıñ' ], [ 'Париж', 'Parij' ], [ 'чёкюч', 'çöküç' ],
+                       [ 'элифбени', 'elifbeni' ], [ 'полициясы', 'politsiyası' ], [ 'хусусында', 'hususında' ],
+                       [ 'акъшамларны', 'aqşamlarnı' ], [ 'опькеленюв', 'öpkelenüv' ],
+                       [ 'кулюмсиреди', 'külümsiredi' ], [ 'айтмайджагъым', 'aytmaycağım' ],
+                       [ 'козьяшсыз', 'közyaşsız' ],
+
+                       // exception words
+                       [ 'инструменталь', 'instrumental' ], [ 'гургуль', 'gürgül' ], [ 'тюшюнмемек', 'tüşünmemek' ],
+
+                       // specific problem words
+                       [ 'куню', 'künü' ], [ 'сюргюнлиги', 'sürgünligi' ], [ 'озю', 'özü' ], [ 'этти', 'etti' ],
+                       [ 'эсас', 'esas' ], [ 'дёрт', 'dört' ], [ 'кельди', 'keldi' ], [ 'км²', 'km²' ],
+                       [ 'юзь', 'yüz' ], [ 'АКъШ', 'AQŞ' ], [ 'ШСДжБнен', 'ŞSCBnen' ], [ 'июль', 'iyül' ],
+                       [ 'ишгъаль', 'işğal' ], [ 'ишгъальджилерине', 'işğalcilerine' ], [ 'район', 'rayon' ],
+                       [ 'районынынъ', 'rayonınıñ' ], [ 'Ногъай', 'Noğay' ], [ 'Юрьтю', 'Yürtü' ],
+                       [ 'ватандан', 'vatandan' ], [ 'ком-кок', 'köm-kök' ], [ 'АКЪКЪЫ', 'AQQI' ],
+                       [ 'ДАГЪГЪА', 'DAĞĞA' ], [ '13-юнджи', '13-ünci' ], [ 'ДЖУРЬМЕК', 'CÜRMEK' ],
+                       [ 'джумлеси', 'cümlesi' ], [ 'ильи', 'ilyi' ], [ 'Ильи', 'İlyi' ], [ 'бруцел', 'brutsel' ],
+                       [ 'коцюб', 'kotsüb' ], [ 'плацен', 'platsen' ], [ 'эпицентр', 'epitsentr' ],
+
+                       // -tsin- words
+                       [ 'кетсин', 'ketsin' ], [ 'кирлетсин', 'kirletsin' ], [ 'этсин', 'etsin' ],
+                       [ 'етсин', 'yetsin' ], [ 'этсинлерми', 'etsinlermi' ], [ 'принцини', 'printsini' ],
+                       [ 'медицина', 'meditsina' ], [ 'Щетсин', 'Şçetsin' ], [ 'Щекоцины', 'Şçekotsinı' ],
+
+                       // regex pattern words
+                       [ 'коюнден', 'köyünden' ], [ 'аньге', 'ange' ],
+
+                       // multi part words
+                       [ 'эки юз', 'eki yüz' ],
+
+                       // affix patterns
+                       [ 'койнинъ', 'köyniñ' ], [ 'Авджыкойде', 'Avcıköyde' ], [ 'экваториаль', 'ekvatorial' ],
+                       [ 'Джанкой', 'Canköy' ], [ 'усть', 'üst' ], [ 'роль', 'rol' ], [ 'буюк', 'büyük' ],
+                       [ 'джонк', 'cönk' ],
+
+                       // Roman numerals vs Initials, part 1 - Roman numeral initials without spaces
+                       [ 'А.Б.Дж.Д.М. Къадырова XII', 'A.B.C.D.M. Qadırova XII' ],
+                       // Roman numerals vs Initials, part 2 - Roman numeral initials with spaces
+                       [ 'Г. Х. Ы. В. X. Л. Меметов III',  'G. H. I. V. X. L. Memetov III' ],
+
+                       // ALL CAPS, made up acronyms
+                       [ 'НЪАБ', 'ÑAB' ], [ 'КЪЫДЖ', 'QIC' ], [ 'ГЪУК', 'ĞUK' ], [ 'ДЖОТ', 'COT' ], [ 'ДЖА', 'CA' ],
+               ];
+       }
+
+       /**
+        * @dataProvider provideAutoConvertToAllVariantsByString
+        * @covers Language::autoConvertToAllVariants
+        *
+        * Run tests that require some context (like Roman numerals) or with
+        * many-to-one mappings, or other asymmetric results (like smart quotes)
+        */
+       public function testAutoConvertToAllVariantsByString( $result, $value ) {
+               $this->assertEquals( $result, $this->getLang()->autoConvertToAllVariants( $value ) );
+       }
+
+       public static function provideAutoConvertToAllVariantsByString() {
                return [
-                       [ // general words, covering more of the alphabet
-                               [
-                                       'crh'      => 'рузгярнынъ ruzgârnıñ Париж Parij',
-                                       'crh-cyrl' => 'рузгярнынъ рузгярнынъ Париж Париж',
-                                       'crh-latn' => 'ruzgârnıñ ruzgârnıñ Parij Parij',
-                               ],
-                               'рузгярнынъ ruzgârnıñ Париж Parij'
-                       ],
-                       [ // general words, covering more of the alphabet
-                               [
-                                       'crh'      => 'чёкюч çöküç элифбени elifbeni полициясы politsiyası',
-                                       'crh-cyrl' => 'чёкюч чёкюч элифбени элифбени полициясы полициясы',
-                                       'crh-latn' => 'çöküç çöküç elifbeni elifbeni politsiyası politsiyası',
-                               ],
-                               'чёкюч çöküç элифбени elifbeni полициясы politsiyası'
-                       ],
-                       [ // general words, covering more of the alphabet
-                               [
-                                       'crh'      => 'хусусында hususında акъшамларны aqşamlarnı опькеленюв öpkelenüv',
-                                       'crh-cyrl' => 'хусусында хусусында акъшамларны акъшамларны опькеленюв опькеленюв',
-                                       'crh-latn' => 'hususında hususında aqşamlarnı aqşamlarnı öpkelenüv öpkelenüv',
-                               ],
-                               'хусусында hususında акъшамларны aqşamlarnı опькеленюв öpkelenüv'
-                       ],
-                       [ // general words, covering more of the alphabet
-                               [
-                                       'crh'      => 'кулюмсиреди külümsiredi айтмайджагъым aytmaycağım козьяшсыз közyaşsız',
-                                       'crh-cyrl' => 'кулюмсиреди кулюмсиреди айтмайджагъым айтмайджагъым козьяшсыз козьяшсыз',
-                                       'crh-latn' => 'külümsiredi külümsiredi aytmaycağım aytmaycağım közyaşsız közyaşsız',
-                               ],
-                               'кулюмсиреди külümsiredi айтмайджагъым aytmaycağım козьяшсыз közyaşsız'
-                       ],
-                       [ // exception words
-                               [
-                                       'crh'      => 'инструменталь instrumental гургуль gürgül тюшюнмемек tüşünmemek',
-                                       'crh-cyrl' => 'инструменталь инструменталь гургуль гургуль тюшюнмемек тюшюнмемек',
-                                       'crh-latn' => 'instrumental instrumental gürgül gürgül tüşünmemek tüşünmemek',
-                               ],
-                               'инструменталь instrumental гургуль gürgül тюшюнмемек tüşünmemek'
-                       ],
-                       [ // recent problem words, part 1
-                               [
-                                       'crh'      => 'künü куню sürgünligi сюргюнлиги özü озю etti этти esas эсас dört дёрт',
-                                       'crh-cyrl' => 'куню куню сюргюнлиги сюргюнлиги озю озю этти этти эсас эсас дёрт дёрт',
-                                       'crh-latn' => 'künü künü sürgünligi sürgünligi özü özü etti etti esas esas dört dört',
-                               ],
-                               'künü куню sürgünligi сюргюнлиги özü озю etti этти esas эсас dört дёрт'
-                       ],
-                       [ // recent problem words, part 2
-                               [
-                                       'crh'      => 'keldi кельди km² км² yüz юзь AQŞ АКъШ ŞSCBnen ШСДжБнен iyül июль',
-                                       'crh-cyrl' => 'кельди кельди км² км² юзь юзь АКъШ АКъШ ШСДжБнен ШСДжБнен июль июль',
-                                       'crh-latn' => 'keldi keldi km² km² yüz yüz AQŞ AQŞ ŞSCBnen ŞSCBnen iyül iyül',
-                               ],
-                               'keldi кельди km² км² yüz юзь AQŞ АКъШ ŞSCBnen ШСДжБнен iyül июль'
-                       ],
-                       [ // recent problem words, part 3
-                               [
-                                       'crh'      => 'işğal ишгъаль işğalcilerine ишгъальджилерине rayon район üst усть',
-                                       'crh-cyrl' => 'ишгъаль ишгъаль ишгъальджилерине ишгъальджилерине район район усть усть',
-                                       'crh-latn' => 'işğal işğal işğalcilerine işğalcilerine rayon rayon üst üst',
-                               ],
-                               'işğal ишгъаль işğalcilerine ишгъальджилерине rayon район üst усть'
-                       ],
-                       [ // recent problem words, part 4
-                               [
-                                       'crh'      => 'rayonınıñ районынынъ Noğay Ногъай Yürtü Юрьтю vatandan ватандан',
-                                       'crh-cyrl' => 'районынынъ районынынъ Ногъай Ногъай Юрьтю Юрьтю ватандан ватандан',
-                                       'crh-latn' => 'rayonınıñ rayonınıñ Noğay Noğay Yürtü Yürtü vatandan vatandan',
-                               ],
-                               'rayonınıñ районынынъ Noğay Ногъай Yürtü Юрьтю vatandan ватандан'
-                       ],
-                       [ // recent problem words, part 5
-                               [
-                                       'crh'      => 'ком-кок köm-kök rol роль AQQI АКЪКЪЫ DAĞĞA ДАГЪГЪА 13-ünci 13-юнджи',
-                                       'crh-cyrl' => 'ком-кок ком-кок роль роль АКЪКЪЫ АКЪКЪЫ ДАГЪГЪА ДАГЪГЪА 13-юнджи 13-юнджи',
-                                       'crh-latn' => 'köm-kök köm-kök rol rol AQQI AQQI DAĞĞA DAĞĞA 13-ünci 13-ünci',
-                               ],
-                               'ком-кок köm-kök rol роль AQQI АКЪКЪЫ DAĞĞA ДАГЪГЪА 13-ünci 13-юнджи'
-                       ],
-                       [ // recent problem words, part 6
-                               [
-                                       'crh'      => 'ДЖУРЬМЕК CÜRMEK кетсин ketsin джумлеси cümlesi ильи ilyi Ильи İlyi',
-                                       'crh-cyrl' => 'ДЖУРЬМЕК ДЖУРЬМЕК кетсин кетсин джумлеси джумлеси ильи ильи Ильи Ильи',
-                                       'crh-latn' => 'CÜRMEK CÜRMEK ketsin ketsin cümlesi cümlesi ilyi ilyi İlyi İlyi',
-                               ],
-                               'ДЖУРЬМЕК CÜRMEK кетсин ketsin джумлеси cümlesi ильи ilyi Ильи İlyi'
-                       ],
-                       [ // recent problem words, part 7
-                               [
-                                       'crh'      => 'бруцел brutsel коцюб kotsüb плацен platsen эпицентр epitsentr',
-                                       'crh-cyrl' => 'бруцел бруцел коцюб коцюб плацен плацен эпицентр эпицентр',
-                                       'crh-latn' => 'brutsel brutsel kotsüb kotsüb platsen platsen epitsentr epitsentr',
-                               ],
-                               'бруцел brutsel коцюб kotsüb плацен platsen эпицентр epitsentr'
-                       ],
-                       [ // regex pattern words
-                               [
-                                       'crh'      => 'köyünden коюнден ange аньге',
-                                       'crh-cyrl' => 'коюнден коюнден аньге аньге',
-                                       'crh-latn' => 'köyünden köyünden ange ange',
-                               ],
-                               'köyünden коюнден ange аньге'
-                       ],
-                       [ // multi part words
-                               [
-                                       'crh'      => 'эки юз eki yüz',
-                                       'crh-cyrl' => 'эки юз эки юз',
-                                       'crh-latn' => 'eki yüz eki yüz',
-                               ],
-                               'эки юз eki yüz'
-                       ],
-                       [ // affix patterns
-                               [
-                                       'crh'      => 'köyniñ койнинъ Avcıköyde Авджыкойде ekvatorial экваториаль Canköy Джанкой',
-                                       'crh-cyrl' => 'койнинъ койнинъ Авджыкойде Авджыкойде экваториаль экваториаль Джанкой Джанкой',
-                                       'crh-latn' => 'köyniñ köyniñ Avcıköyde Avcıköyde ekvatorial ekvatorial Canköy Canköy',
-                               ],
-                               'köyniñ койнинъ Avcıköyde Авджыкойде ekvatorial экваториаль Canköy Джанкой'
-                       ],
                        [ // Roman numerals and quotes, esp. single-letter Roman numerals at the end of a string
                                [
                                        'crh'      => 'VI,VII IX “dört” «дёрт» XI XII I V X L C D M',
@@ -144,30 +118,6 @@ class LanguageCrhTest extends LanguageClassesTestCase {
                                ],
                                'VI,VII IX “dört” «дёрт» XI XII I V X L C D M'
                        ],
-                       [ // Roman numerals vs Initials, part 1 - Roman numeral initials without spaces
-                               [
-                                       'crh'      => 'A.B.C.D.M. Qadırova XII, А.Б.Дж.Д.М. Къадырова XII',
-                                       'crh-cyrl' => 'А.Б.Дж.Д.М. Къадырова XII, А.Б.Дж.Д.М. Къадырова XII',
-                                       'crh-latn' => 'A.B.C.D.M. Qadırova XII, A.B.C.D.M. Qadırova XII',
-                               ],
-                               'A.B.C.D.M. Qadırova XII, А.Б.Дж.Д.М. Къадырова XII'
-                       ],
-                       [ // Roman numerals vs Initials, part 2 - Roman numeral initials with spaces
-                               [
-                                       'crh'      => 'G. H. I. V. X. L. Memetov III, Г. Х. Ы. В. X. Л. Меметов III',
-                                       'crh-cyrl' => 'Г. Х. Ы. В. X. Л. Меметов III, Г. Х. Ы. В. X. Л. Меметов III',
-                                       'crh-latn' => 'G. H. I. V. X. L. Memetov III, G. H. I. V. X. L. Memetov III',
-                               ],
-                               'G. H. I. V. X. L. Memetov III, Г. Х. Ы. В. X. Л. Меметов III'
-                       ],
-                       [ // ALL CAPS, made up acronyms
-                               [
-                                       'crh'      => 'ÑAB QIC ĞUK COT НЪАБ КЪЫДЖ ГЪУК ДЖОТ CA ДЖА',
-                                       'crh-cyrl' => 'НЪАБ КЪЫДЖ ГЪУК ДЖОТ НЪАБ КЪЫДЖ ГЪУК ДЖОТ ДЖА ДЖА',
-                                       'crh-latn' => 'ÑAB QIC ĞUK COT ÑAB QIC ĞUK COT CA CA',
-                               ],
-                               'ÑAB QIC ĞUK COT НЪАБ КЪЫДЖ ГЪУК ДЖОТ CA ДЖА'
-                       ],
                        [ // Many-to-one mappings: many Cyrillic to one Latin
                                [
                                        'crh'      => 'шофер шофёр şoför корбекул корьбекул корьбекуль körbekül',