Commit graph

2060 commits

Author SHA1 Message Date
Nemoralis a01cc2f2f8 Added Talysh namespaces
Bug: T367009
Change-Id: I5dd53d1d7f535169772833828aac5fe01dcdb6a9
2024-09-11 17:36:14 +00:00
Siddharth VP c08452684c Rename SyntaxHighlight RL module
Bug: T368166
Depends-On: I999937c1f6303ecc64adb6285e73a9ce10f67bd8
Change-Id: I68d13d6d3fed7c70d795b0864bf5fb9ef1409c0a
2024-09-09 19:35:26 +00:00
Ebrahim Byagowi 27136f2afa Avoid use of deprecated wfGetUrlUtils
Change-Id: Ia36e0cf4a390f32fad7da55a503ac15afa85317a
2024-09-08 09:47:06 +03:30
Translation updater bot 484338c20d
Localisation updates from https://translatewiki.net.
Change-Id: I3ca2ad1cc8b9bee16f10af115f3b32a7b2437e5a
2024-09-02 09:21:31 +02:00
libraryupgrader 8f4409c633 build: Updating micromatch to 4.0.8
* https://github.com/advisories/GHSA-952p-6rrq-rcjv

Change-Id: Iecb078280bd2e2b1698501d7374025618d6a5142
2024-08-31 07:19:52 +00:00
James D. Forrester bb71303a81 Replace use of deprecated global URL functions with wfGetUrlUtils()
This is a quick fix rather than the proper DI fix.

Bug: T319340
Change-Id: I9e3bd0049b28efc634e1f394a487f86e27ef9e0d
2024-08-29 13:35:12 -04:00
thiemowmde 40ebea2313 Make use of MainConfigNames constants in tests
Change-Id: I55aa25268b9d2f48f90b6f79ed4309c9b2355bd9
2024-08-27 20:36:11 +00:00
thiemowmde 5ced07c366 Improve a few PHPDoc type hints
Mostly unspecific arrays that can be made more specific. This patch
intentionally doesn't touch any code, only comments.

Change-Id: I5b4690e6160c6c543f9fcb2f62c41f6329d48bdb
2024-08-27 16:54:41 +00:00
thiemowmde ffafba0695 Remove meaningless return true from hook handler functions
Returning true is the same as returning nothing. It's only meaningful
when a hook handler can also return false. Some actually do this.
I'm not touching these.

See Icccf60b for the reasoning why the added `@return void` are
beneficial.

Change-Id: I6de7addee853ff183058e6c84e87a5b275c785e8
2024-08-27 08:47:46 +00:00
James D. Forrester 289c7004e0 build: Update MediaWiki requirement to 1.43
All extensions in the MediaWiki tarball are expected to track MediaWiki's release directly.

Change-Id: I22ba3c032454a8a68331b1e373a353585569359f
2024-08-24 14:38:32 +00:00
C. Scott Ananian 13b7e5ab31 Add title.content alias for Title::getContent()
No other access in the Title class contains a `get` prefix, so this
makes the title methods consistent.

Bug: T373047
Change-Id: I4a3a7498462b7b3b6143dc61f529e526ccb112e2
2024-08-22 11:30:26 -04:00
Translation updater bot 9c4fc5a95c
Localisation updates from https://translatewiki.net.
Change-Id: Ife509bc2a69828bb34ab689773a3908dd3914fa5
2024-08-19 09:24:55 +02:00
Translation updater bot ee1383994c
Localisation updates from https://translatewiki.net.
Change-Id: Ie9d452501298d0c925e4e7cd2dc4f60a683d87ea
2024-08-14 09:23:38 +02:00
libraryupgrader 94b4f0463f build: Updating mediawiki/mediawiki-codesniffer to 44.0.0
Change-Id: Ic23a06fd70f599665371fa35e10cb4a1ca26caac
2024-08-12 16:16:21 +00:00
Translation updater bot a769c7410f
Localisation updates from https://translatewiki.net.
Change-Id: I400f98094ec979815c371de58aedfd741ccdb98f
2024-08-08 09:20:34 +02:00
dreamrimmer 22a86e47b1 Remove alias for the Module namespace in Hindi
Bug: T366235
Change-Id: I33ce7a5a9844ca031c675e4c8d7ca67da473701e
2024-08-07 18:33:29 +00:00
Siddharth VP a414aba445 Expose page categories to Lua
Added `categories` property in the lua title class which fetches page
categories. Analogous to getContent() which fetches page content. This
increments the expensive function count.

This enables category-specific editnotices (T85372) and other use-cases.

Bug: T50175
Change-Id: Ie8e0762c537374e6086abe9f9916b8200582776a
2024-08-07 16:50:07 +00:00
Translation updater bot db4691da48
Localisation updates from https://translatewiki.net.
Change-Id: Ic856b0d7efe0b0bc73540ceedb0d1941ea19b551
2024-08-06 09:48:36 +02:00
Amir E. Aharoni df6c79969d Add namespace translations in Iban (iba)
Provided by Song GK at
https://translatewiki.net/w/i.php?title=User_talk:Song_GK&oldid=12540720#Namespaces

Bug: T367991
Change-Id: Idc62fcbdc89dd20a2f56f07c5550020805bfbd46
2024-07-27 07:06:37 +00:00
Translation updater bot ec0b80e57e
Localisation updates from https://translatewiki.net.
Change-Id: Ib7bf8da35df80073a7d1d2a604ceaf01d80be0f7
2024-07-26 09:46:36 +02:00
Translation updater bot 7f39028936
Localisation updates from https://translatewiki.net.
Change-Id: I9f6aa8ac83dd8b6efc9d6b779cea294ea15c3ce9
2024-07-16 09:41:17 +02:00
Mark A. Hershberger c684be1e52 Capture stderr from ‘lua -v' to get the version number.
Bug: T368832
Change-Id: Iff6e908686ee0e81088a81316927d1b250e6af1a
2024-07-08 21:11:23 +00:00
Translation updater bot cb93053fa3
Localisation updates from https://translatewiki.net.
Change-Id: I9c2c0f96cde633c61e9b78fead81106674fb22d2
2024-07-08 09:33:54 +02:00
Translation updater bot 849c72b537
Localisation updates from https://translatewiki.net.
Change-Id: Ida02a8d63a50a0f0b43038fa39953d2b8619b5cb
2024-07-01 09:26:18 +02:00
libraryupgrader 9573bab523 build: Updating npm dependencies
* eslint-config-wikimedia: 0.28.0 → 0.28.2
* grunt-stylelint: 0.20.0 → 0.20.1
* stylelint-config-wikimedia: 0.17.1 → 0.17.2

Change-Id: I8907069eeecff4030b860a9770144146a1ccc95c
2024-06-21 23:09:17 +00:00
Bartosz Dziewoński ce1fa91c54 Don't depend on Message implementation details
You're not really supposed to know how Message represents the
parameters internally.

Change-Id: I5767dcc96af77b21655609cb9ce43bcaf9e07e19
2024-06-17 16:25:22 +00:00
Harsh Rathod b4a7d5c8ca Localize "Module" namespace to Hindi
Made the earlier semantically-correct Hindi localization an alias
and added the suggested Hindi localization preferred by the Hindi
Wikipedia community members the primary Hindi localization.

Bug: T366235
Followup-To: I811594311abb4e1d3e44ce3b284d11f72836cbdd
Change-Id: I2f8c7b1dfe22f210773507e86f4b12edd3fd196b
2024-06-17 16:14:21 +00:00
Translation updater bot f2ad2dbb20
Localisation updates from https://translatewiki.net.
Change-Id: Ie6f581a58ebfb889c045f244a8dba4dbb1517f4f
2024-06-17 09:32:41 +02:00
Translation updater bot 72c0a01e35
Localisation updates from https://translatewiki.net.
Change-Id: Id93957cde6050b6f2988efc6cd235837faa0ac65
2024-06-13 09:29:07 +02:00
Umherirrender db8f22c1d4 Use namespaced classes
Changes to the use statements done automatically via script

Change-Id: Iedad37d75aee4d2a6960ab20148f813c6cf7061a
2024-06-10 20:41:43 +02:00
Translation updater bot 27d2b58cb7 Localisation updates from https://translatewiki.net.
Change-Id: Ic875d509ef6c9ca6cc06eb691ed1accf3c4adf59
2024-06-10 09:56:05 +02:00
libraryupgrader d369d37057 build: Updating npm dependencies
* eslint-config-wikimedia: 0.27.0 → 0.28.0
* grunt-stylelint: 0.19.0 → 0.20.0
* stylelint-config-wikimedia: 0.16.1 → 0.17.1

Change-Id: Ib3d5ebfc33a4d17e1c63d601ba136989866616c5
2024-06-08 03:02:14 +00:00
Harsh Rathod 78a58560f5 Localize "Module" namespace to Hindi
Bug: T366235
Change-Id: I811594311abb4e1d3e44ce3b284d11f72836cbdd
2024-06-05 03:31:51 +00:00
Translation updater bot 031104f285 Localisation updates from https://translatewiki.net.
Change-Id: I45f89ed0cac747dface6fd02d786a01097eb477f
2024-06-03 09:32:53 +02:00
Translation updater bot 9d230e5233 Localisation updates from https://translatewiki.net.
Change-Id: I0bb176cc73b5119d4bdeae73b1560d7acecc1c62
2024-05-28 09:31:15 +02:00
Translation updater bot 73765466f3 Localisation updates from https://translatewiki.net.
Change-Id: Ifd2de00ece3bffd72d7de965129eb12d0a11910d
2024-05-27 09:29:52 +02:00
theknightwho acd7ec66ea Avoid modules that should return false wrongly returning true
When modules are first loaded by `require` in package.lua, it checks
for a return value with `if res then`. If that check fails, the module
will be cached with the default value `true` at line 109, and that
value is then returned.

That check should be changed to `if res ~= nil then`, because
otherwise a module with a return value of `false` will be cached with
the value `true`.

This also necessitates a corresponding change to the check at line 93,
which is when `package.loaded` is initially checked to see if a package
has been loaded before, as that value could be `false`.

Bug: T362045
Change-Id: Id42e26a922c13971c25ed8654e822dc6fdcb6ca7
2024-05-24 02:10:41 +00:00
theknightwho fc3104e9c6 Optimisations for mw.clone
`mw.clone` is called on the global table for each new `{{#invoke:}}`,
which is a major contributor to loading times on large pages. This
change introduces various speed optimisations that make it around
15% faster:

* `recursiveClone` is declared outside of the main function, to avoid
  generating a new closure each time `mw.clone` is called.
* This means `tableRefs` has to be passed as an argument to
  `recursiveClone` instead of being an upvalue, which also decreases
  access time.
* `recursiveClone` is only called after a `type` then `tableRefs` check
  confirms a value is an unseen table, meaning it's only called when
  needed, not for every key/value pair (which add noticeable overhead
  when cloning large tables).
* `getmetable` is only called once, not twice, by using a local
  variable.
* `tableRefs[elt]` is only accessed once, by using a ternary operator.
* Any global accesses have been replaced by local ones.

Bug: T357199
Change-Id: I51593a971f0be728255723ca300d1ce692ead256
2024-05-24 02:08:41 +00:00
Translation updater bot df7dee0e7c Localisation updates from https://translatewiki.net.
Change-Id: I6da01c5c313ce7e04491bc025cd375ed5b398b33
2024-05-20 09:26:04 +02:00
libraryupgrader 2e6cf9cafe build: Updating grunt-banana-checker to 0.13.0
Change-Id: I258c02573ddbefd0be087a9dba2738fadc935fec
2024-05-19 01:09:51 +00:00
Bartosz Dziewoński c6b1f32dff Update parser tests for new heading HTML
Bug: T13555
Depends-On: I1180169a8e83af834c2984ba16089e6277f2a8dd
Change-Id: I4d2be132e63aff7bf8953f0f371e806a834db10d
2024-05-16 16:35:58 +00:00
Translation updater bot 7c41511282 Localisation updates from https://translatewiki.net.
Change-Id: Ia426a54450c80a3b01fd6d78b167602417c14286
2024-05-16 09:27:24 +02:00
theknightwho a091b46d65 Use correct variable for error message in mw.loadJsonData
`mw.loadJsonData` in mw.lua throws an error if the input argument is
not a string. The error message should refer to the type of the input
argument `module`, not that of the variable `arg` (which is usually
undeclared, giving the type `nil`).

This also necessitates updating test `mw.loadJsonData, bad title (1)`
in CommonTests.lua, which checks for the error message if the input
is the number 0; the correct message should say "got number", not
"got nil".

Bug: T364987
Change-Id: I8362e91489a8ddc4c890e2799892f692c497c9b9
2024-05-15 14:05:32 +01:00
Translation updater bot c7036c9dc0 Localisation updates from https://translatewiki.net.
Change-Id: I4809c91a49d4131372909ecf0d237694081fa52a
2024-05-15 09:22:12 +02:00
Wandji69 a7111aac69 Use ObjectCacheFactory instead of deprecated ObjectCache method
Bug: T363770
Change-Id: I416c511ef22afde3d519f66818c9b64e0ef21178
2024-05-14 20:07:42 +00:00
SD0001 9ec60453f7 Revert "Localisation updates from https://translatewiki.net."
This reverts commit 551f90ba86.

Reason for revert: trailing whitespace in i18n message is causing builds to fail. Example: https://integration.wikimedia.org/ci/job/mwgate-node18/15679/console

Bug: T364727
Change-Id: I88fc8cd7b22d119089aeeb70f50042b3662ee929
2024-05-14 20:07:14 +00:00
Translation updater bot 551f90ba86 Localisation updates from https://translatewiki.net.
Change-Id: If755f652b21af2cd8560ad15bd81b34904fd0f95
2024-05-13 09:27:54 +02:00
libraryupgrader fec711cbb2 build: Updating dependencies
composer:
* mediawiki/minus-x: 1.1.1 → 1.1.3

npm:
* grunt-banana-checker: 0.11.1 → 0.12.0

Change-Id: Ifd2ceb4be1f3dc5a414b5c9946450f3bd822e68c
2024-05-10 22:19:13 +00:00
Translation updater bot 3f881a1919 Localisation updates from https://translatewiki.net.
Change-Id: I1012746f98b116d1b50d03c6e65188bca24e56c4
2024-05-06 09:26:30 +02:00
wfan fed1972733 Migrate MediaWiki.scribunto.traces.* to statslib
Bug: T359275
Change-Id: Idd234bbb34747b4557dcded73eace69131a2566a
2024-05-04 22:40:52 -07:00