Commit graph

7305 commits

Author SHA1 Message Date
jenkins-bot 28962b985e Merge "prefs: Remove trailing full stop from message" 2024-12-02 15:48:34 +00:00
Translation updater bot 5e5216040b
Localisation updates from https://translatewiki.net.
Change-Id: I786024a98025a5aa8f4a08ea7d08fa810cf0536c
2024-12-02 08:21:54 +01:00
libraryupgrader 2befcd258d build: Updating jsdoc to 4.0.4
Change-Id: I104e750cd5ee6fa1ea80d38b7508900fe79ff27a
2024-12-02 01:13:36 +00:00
Reedy 153c5753c9 prefs: Remove trailing full stop from message
More consistent

Change-Id: I53227c090e997653caaa18b81461b9cffcf91ffc
2024-12-01 00:20:07 +00:00
Translation updater bot c39878c78c
Localisation updates from https://translatewiki.net.
Change-Id: I369abb0a351efd3b89dcca61844fa5875858582c
2024-11-29 08:31:04 +01:00
Tim Starling 105f2a3845 Fix installer error when the task is run a second time
Fix task idempotency. Check if a table exists before running the schema
patch.

Bug: T352113
Change-Id: If6f0930ea327df35fe118d4a08993c6383f9d579
2024-11-28 14:54:42 +11:00
jenkins-bot 441ca70fbf Merge "selenium: Replace Node.js Assert library with WebdriverIO Expect library" 2024-11-27 12:16:19 +00:00
Translation updater bot 95a84c8447
Localisation updates from https://translatewiki.net.
Change-Id: I540949da7a8849f7dcc582c8cf05d1afbfccc0bb
2024-11-26 08:16:30 +01:00
Translation updater bot e962ab70d8
Localisation updates from https://translatewiki.net.
Change-Id: Ic605597ebea08237fec6980c89b381c3ebe83e5f
2024-11-25 08:23:14 +01:00
jenkins-bot 4897e2f2a6 Merge "Move addWiki.php special case to an installer task" 2024-11-22 10:38:32 +00:00
Željko Filipin 23ac1201a5 selenium: Replace Node.js Assert library with WebdriverIO Expect library
Assertions from Expect library are more readable that assertions from Assert library.

Bug: T325740
Change-Id: I8c31444538670e1500574415cec3a4d54d3798b4
2024-11-21 14:20:21 +01:00
jenkins-bot 30921ae5fe Merge "DiscussionParser: Don't construct Users with invalid names" 2024-11-21 12:24:57 +00:00
jenkins-bot c532845d48 Merge "DiscussionParserTest: Add some test case names" 2024-11-21 10:47:12 +00:00
jenkins-bot 4786e85782 Merge "SeenTime: Actually use an in-process cache" 2024-11-21 08:13:21 +00:00
Translation updater bot 7cd9f81828
Localisation updates from https://translatewiki.net.
Change-Id: I4afccc558aa24b9bdcb6caff717971fb7cb3411c
2024-11-21 08:21:45 +01:00
Bartosz Dziewoński 39be79c1b0 SeenTime: Actually use an in-process cache
It doesn't work if every call to cache() returns
a different CachedBagOStuff :')

I found this thanks to log warnings I saw locally:

  SQLBagOStuff.WARNING: Duplicate get():
  "mediawiki:echo:seen:alert:time:1" fetched 2 times
  SQLBagOStuff.WARNING: Duplicate get():
  "mediawiki:echo:seen:message:time:1" fetched 2 times

Change-Id: I9a920de88275c1297942b064cc635d5c25424fd2
2024-11-21 03:00:19 +01:00
Bartosz Dziewoński 124162fee4 DiscussionParser: Don't construct Users with invalid names
The comment said "don't validate the username - anon (IP) is fine!"
– but it also allowed invalid names, not just IPs, and those are not
really fine.

Also add more test cases and remove some unused test code.

Bug: T380242
Change-Id: Id98f14a0663f33eb5e45045bcd2df6a1e1f52de6
2024-11-20 21:04:34 +01:00
Tim Starling 3a45c2600b Move addWiki.php special case to an installer task
Bug: T352113
Depends-On: Ie7c466012d8d5644b1398452e3077416ab0270c5
Change-Id: I752edd8daaebb91a4bd9a7797747ade96d537526
2024-11-20 11:00:45 +11:00
Bartosz Dziewoński 09daeb5ba2 DiscussionParserTest: Add some test case names
PHPUnit will display them if the tests fail.

Change-Id: Iff695d801819e13c238929912433e6a97e14ec54
2024-11-19 23:58:21 +01:00
Translation updater bot 0a50bd16cd
Localisation updates from https://translatewiki.net.
Change-Id: I2653f400f40a3285e8af73a0f428382cb5cb1ca9
2024-11-19 08:17:44 +01:00
Translation updater bot cc0d2c1451
Localisation updates from https://translatewiki.net.
Change-Id: I2550e63d1156e143318e50e5973c085e500cbe36
2024-11-18 08:23:42 +01:00
Translation updater bot 4821d45e60
Localisation updates from https://translatewiki.net.
Change-Id: I374c9eb3e05586ffe7793c2d719bbccd0b00e0ff
2024-11-15 08:44:50 +01:00
jenkins-bot 149727038d Merge "Disallow anonymous non-IP agents, handle truncated names" 2024-11-14 16:19:19 +00:00
jenkins-bot eab588bcf0 Merge "selenium: Delete tests disabled more than two years ago" 2024-11-14 12:05:58 +00:00
Matěj Suchánek 11b9e66f9f Disallow anonymous non-IP agents, handle truncated names
Why:
* Echo stores agents by their user id or by the name if the user
  is not registered. This works for IPs since the "event_agent_ip"
  field has limit of 39 bytes (32× [0-9A-F] + 7× colon for IPv6).
* However, it's possible to hold a user identity that is not
  an IP address, but the user name has not been or cannot be
  registered (e.g., external users). Echo wouldn't validate this
  and would attempt to insert the user name into "event_agent_ip",
  possibly causing silent truncation and data corruption.

What:
* Do not let events with such agents be saved. For now, log an
  error in the production. Wikibase, the only known source of this
  problem, has already been fixed.
* In runtime, replace every possibly corrupted user name with
  a placeholder to avoid unexpected null values and exceptions
  in production.

Bug: T367638
Change-Id: Ic2bd218b10651d13da9e9aea54dd2d668a33d946
Depends-On: I03b4367355dc5a3fc0c14aad5fdf19fbcd0caa3d
Depends-On: I92eb93983e81708b289e9f7d837884d539dade0b
2024-11-14 11:44:19 +01:00
jenkins-bot eff1de4fdf Merge "Explicitly call DeferredUpdates::tryOpportunisticExecute() in ThankYouEditTest" 2024-11-12 17:32:54 +00:00
Translation updater bot dc0ff7e07d
Localisation updates from https://translatewiki.net.
Change-Id: Ieaa5e8290eef38220c526a8f8e6c9a183f5a0172
2024-11-12 08:17:49 +01:00
Translation updater bot 7a0b8d27e0
Localisation updates from https://translatewiki.net.
Change-Id: I8c0d71ced10918fa8e332e6e27f115f5e60990e2
2024-11-11 08:22:34 +01:00
Aaron Schulz 88ab531e17 Explicitly call DeferredUpdates::tryOpportunisticExecute() in ThankYouEditTest
Change-Id: I423f9a856fddab30e691d78cbcd0b70a292e3916
2024-11-07 12:16:46 -08:00
Translation updater bot 6b09de87db
Localisation updates from https://translatewiki.net.
Change-Id: Id8b159f2163e4a70dfc7ba95bd992e1c87c3a735
2024-11-07 08:18:37 +01:00
Translation updater bot 921cfcc165
Localisation updates from https://translatewiki.net.
Change-Id: I5a97aaa588ff592af366897959996853adb4dfb0
2024-11-06 08:22:19 +01:00
Translation updater bot f8a1081bb9
Localisation updates from https://translatewiki.net.
Change-Id: I04b96d365ede126a1eedafa8d8961722f5e9df6f
2024-11-05 08:32:28 +01:00
jenkins-bot 07a52928f8 Merge "Handle hidden revisions in user page edit notification" 2024-11-04 19:12:38 +00:00
Translation updater bot 9c3b3a8384
Localisation updates from https://translatewiki.net.
Change-Id: I9e4e7ccf22f89b1c4209491f3639417284db543e
2024-11-04 08:21:32 +01:00
libraryupgrader 60a7af8ab1 build: Updating mediawiki/mediawiki-codesniffer to 45.0.0
Change-Id: I5399cbf72f728c4453e3dba08f97645e69a6c282
2024-11-02 07:16:27 +00:00
Ammarpad b80f4294b5 Handle hidden revisions in user page edit notification
Bug: T378799
Change-Id: Ie68e024625c640f46e6af21a2829b33fbd57ec8a
2024-11-01 09:31:17 +01:00
jenkins-bot e6a51beca1 Merge "Avoid event insertion if possible" 2024-10-30 15:06:30 +00:00
Željko Filipin 6db6e95252 selenium: Delete tests disabled more than two years ago
Bug: T280652
Change-Id: I9bdff690e3a8dc0d04c093dad7603cfdd3737a50
2024-10-28 17:52:47 +01:00
Translation updater bot d322fde727
Localisation updates from https://translatewiki.net.
Change-Id: I22ca50ab28668a29fcfc2fa97ce37d6698f63754
2024-10-28 08:22:19 +01:00
jenkins-bot b58122fa3e Merge "special: Check login permissions before calling execute method" 2024-10-28 02:55:18 +00:00
Ammarpad 4303ab5f71 special: Check login permissions before calling execute method
Calling the parent method first means the form has to be built (as
well as various other things) and then it cannot be shown because
of permission and the user is redirected.

This also lead to confusing behavior where some code paths are
reached even though the user cannot actually access the page.

Change-Id: If354d98f9e51acef38cac114a7704d28c148017b
2024-10-27 10:03:09 +01:00
jenkins-bot 570d326543 Merge "fix ::getTruncatedSectionTitle() return type" 2024-10-26 22:19:15 +00:00
Andre Klapper 4da4dad97b Use explicit nullable type on parameter arguments (for PHP 8.4)
Implicitly marking parameter $... as nullable is deprecated in PHP
8.4. The explicit nullable type must be used instead.

Bug: T376276
Change-Id: I251cb37401c37242f493816b6f70ab61a64a4c32
2024-10-26 15:05:13 +02:00
Umherirrender 2edd88a166 Use type-declaration on api module constructor
Parent class constructor gets type-declaration in 1145328459
Remove simple doc-blocks without further information

Change-Id: I0ab283cd0510d8e85e93752a5ee7d65320a4ec2b
2024-10-25 19:14:31 +02:00
Translation updater bot f5173fbd78
Localisation updates from https://translatewiki.net.
Change-Id: Ice483859780ca575bd04c6ab88fc607babd435d2
2024-10-25 09:47:51 +02:00
jenkins-bot 052dc0a3ef Merge "Fix for Watchlist Notifications for deleted pages created in 1.35" 2024-10-25 00:13:25 +00:00
Ammarpad 0a677f4675 fix ::getTruncatedSectionTitle() return type
This method can return false if getParsedSectionTitle() returns false

Both Language::embedBidi and Language::truncateForVisual return
non-string primitives unchanged if they're passed to them as first
argument.

Ideally the Language methods arguments should be string-typed but
I am not sure how easy that change would be now, so better to
document the possibility here.

Change-Id: I7e2856862d6508ecd1aa57ad99b92942bc4d7bed
2024-10-24 22:46:00 +00:00
Reedy a76cc44a60 SpecialNotificationsMarkRead: Don't pass null to explode()
Bug: T377920
Change-Id: I426c76dbf2e8da4563e93fefe6bd628faa0e13b7
2024-10-23 15:16:04 +00:00
Translation updater bot 7ff17f90ee
Localisation updates from https://translatewiki.net.
Change-Id: I1a4629c91ae5f97896379254348866963a720606
2024-10-21 09:20:01 +02:00
Umherirrender 7e5eceb5a6 Use namespaced classes
Changes to the use statements done automatically via script

Change-Id: Iab065a2005acccfe05cc827fdafc7861687d053d
2024-10-20 00:55:03 +02:00