Commit graph

6319 commits

Author SHA1 Message Date
Daimona Eaytoy 25d1abde0b Fix hook name
Dashes are mapped to underscores, but following the "modern" convention,
the hook name should be pure PascalCase.

Bug: T275798
Change-Id: I77909b3ee772b983c7933f3b82230476772bd3b5
2021-03-08 16:15:23 +00:00
Vadim Kovalenko 62376f437e Replace UserIdentity::getUserId with ::getId
Bug: T275482
Change-Id: Ie9fd52005ca1eb264dc791a2f87d7308a9e8810e
2021-03-08 09:18:49 -05:00
Daimona Eaytoy 6ba8e93537 Create distinct builders for plain and ace editor
Change-Id: I9d2b7572fed6e0b3660d3b0d5dad324d6b75fde9
2021-03-08 09:44:58 +00:00
Translation updater bot 7356f87082 Localisation updates from https://translatewiki.net.
Change-Id: Ia323cd056d4ce166fe00253d34ddc2ab1b741dac
2021-03-08 08:44:51 +01:00
jenkins-bot 12f4e81964 Merge "Simplify AbuseFilterBlockTest" 2021-03-06 09:23:26 +00:00
Daimona Eaytoy 92ecccbdc7 Simplify AbuseFilterBlockTest
Requires injecting a temporary block factory, and excluding
ManualLogEntry::insert from the test, but it's now much cleaner and
quicker.

It still cannot be a unit test due to the usage of User.

Change-Id: Iba9732d6d79733b31b45eb4d0187b1c8a82499dc
2021-03-05 14:18:01 +00:00
Translation updater bot 51f37697dc Localisation updates from https://translatewiki.net.
Change-Id: I89853907ba659a8b715622e386db41c97eeef3bd
2021-03-05 08:54:53 +01:00
libraryupgrader ebea8cd3de build: Updating eslint-config-wikimedia to 0.18.2
Change-Id: I83981fb720ee219230f9f6094c18fdf29d7f4ba0
2021-03-05 04:35:46 +00:00
Translation updater bot 17cf903cd4 Localisation updates from https://translatewiki.net.
Change-Id: Iffa9ae7a3620ef16f6de04cf38ce13d9d711429f
2021-03-04 08:37:05 +01:00
Translation updater bot 507e3fb0c5 Localisation updates from https://translatewiki.net.
Change-Id: Id111612a538f205ac19d9bad761cc94e6f1110d2
2021-03-02 08:48:17 +01:00
Daimona Eaytoy 124031fe09 Stop using deprecated User::addGroup in tests
Bug: T276094
Change-Id: I299f89fbb4a4f6ba36ef4b77987bda9f2159d311
2021-03-01 15:28:08 +01:00
Translation updater bot d518c0f60c Localisation updates from https://translatewiki.net.
Change-Id: Id543fd03b70ef4d3ef6639dd1510c10bffc0e9fa
2021-03-01 08:49:36 +01:00
jenkins-bot 50334c27ce Merge "Use a different message for unprivileged users" 2021-02-28 14:05:08 +00:00
jenkins-bot ef4a5c4115 Merge "Make FilterProfiler independent of DeferredUpdate" 2021-02-28 13:18:51 +00:00
Matěj Suchánek 709803eb46 Make FilterProfiler independent of DeferredUpdate
Schedule the deferred update from FilterRunner, just like
we do with EmergencyCache.

Change-Id: I121211bb02a77c191001d11d4af3796e8572967e
2021-02-28 12:03:05 +01:00
jenkins-bot 66f8e44295 Merge "Reject filters with invalid groups" 2021-02-27 20:07:29 +00:00
Daimona Eaytoy 3365a648f2 Reject filters with invalid groups
It is currently possible to save a filter with an invalid group, if you
manually change the form data. So prevent this by validating the group
before saving.

Change-Id: I03f80b8c6ab583a357273f7b2679a424ac784db7
2021-02-27 16:01:09 +00:00
jenkins-bot 34a2660ad2 Merge "Use independent stats for emergency disable" 2021-02-26 18:06:16 +00:00
Matěj Suchánek b8ac52c51c Use independent stats for emergency disable
Bug: T264629
Change-Id: I64b611243b6a4c136b82b09f2ccf588d1c3e3426
2021-02-26 18:10:49 +01:00
Translation updater bot 9f1ef6bf3d Localisation updates from https://translatewiki.net.
Change-Id: I894ae8afb29415e07f34955fe39c07add4de643e
2021-02-25 08:37:48 +01:00
Translation updater bot 550a0936fc Localisation updates from https://translatewiki.net.
Change-Id: Ia4e98950c04acb33189bf5fa695261402fa2ab8d
2021-02-24 08:50:35 +01:00
Translation updater bot d224021c89 Localisation updates from https://translatewiki.net.
Change-Id: Ic69954193f63b65e14ec1d00e7a6af8194b685a4
2021-02-23 08:47:00 +01:00
jenkins-bot 1f3597f925 Merge "Update hit counts in a DeferredUpdate" 2021-02-23 06:34:17 +00:00
jenkins-bot 1b6e209ce6 Merge "Create a new method for authorizing access to test tools" 2021-02-22 18:00:06 +00:00
jenkins-bot 63a9c86607 Merge "Improve test coverage metrics" 2021-02-22 17:00:23 +00:00
jenkins-bot 54c56139a9 Merge "Avoid using User ::getCanonicalName" 2021-02-22 16:56:12 +00:00
jenkins-bot ea6a6ab4fc Merge "Fix StatsdDataFactory injection" 2021-02-22 16:56:09 +00:00
daniel 63a497fb56 Don't set actor on UserIdentityValue in tests.
The actor ID is being removed from UserIdentityValue. Non-zero values
are triggering a deprecation warning now.

Needed-By: I9925906d11e47efaec3c1f48d5cb3f9896a982c1
Change-Id: Id60e56e70f6e4b44f49887d9e5ae5a23b1fd19a2
2021-02-22 11:30:54 +00:00
Matěj Suchánek 569c02f3ae Fix StatsdDataFactory injection
This was an obvious mistake and contradiction to
what the above comment stated.

Bug: T275369
Change-Id: Idf0c012151738fd842101586ab5c3e2656a86db2
2021-02-22 12:08:50 +01:00
Translation updater bot cc3dbe149d Localisation updates from https://translatewiki.net.
Change-Id: I1f5f9b45ad3d7f2e80fc5d0b4e90e2b15e6e58b0
2021-02-22 08:49:55 +01:00
vladshapik dcd038e613 Avoid using User ::getCanonicalName
Remove using of User::getCanonicalName since this method will be hard-deprecated. Now it is soft-deprecated

Bug: T275030
Change-Id: I3ce1199f18276096279ce3c80f63e53d023a0f5a
2021-02-21 23:16:40 +02:00
Matěj Suchánek c2376efddc Improve test coverage metrics
Change-Id: I1618883e3ade7dde538242fb51a36c22999df76d
2021-02-21 09:59:52 +01:00
jenkins-bot b050e36843 Merge "Align arg counting between the parsers" 2021-02-21 03:37:52 +00:00
Daimona Eaytoy 2470bea0d9 Update hit counts in a DeferredUpdate
Bug: T274455
Change-Id: Iadd383f150c5f9b736e37bfd8bdad56298f3d8d5
2021-02-21 03:15:16 +00:00
Matěj Suchánek 4f1a63107d Use a different message for unprivileged users
Everyone can examine generated variables but not everyone
can test filters. Concerns Special:AbuseFilter/examine.

Change-Id: I9c205a0f1d9a7fdf15c4998d43983b9fa37f4694
2021-02-20 17:55:09 +01:00
Matěj Suchánek 5d4025d8c9 Create a new method for authorizing access to test tools
This commit doesn't change any permissions for anybody.
It's the first step to achieve what the task asks for.

Bug: T242821
Change-Id: I8060ca926e6769b11d470fe4037854cda496000d
2021-02-20 17:54:35 +01:00
jenkins-bot b02594a8aa Merge "Avoid using Title in addNavigationLinks" 2021-02-20 14:52:51 +00:00
jenkins-bot 8575201ab2 Merge "Do not serialize RunnerData to array in FilterRunner" 2021-02-20 14:47:15 +00:00
Daimona Eaytoy 2bb5c3c7b5 Align arg counting between the parsers
1 - Change the structure of if/elseif for readability
2 - In the old parser, if there's an empty argument, never add it (the
new parser was already doing that).

Bug: T156095
Bug: T156096
Change-Id: I4237b1a0ba01e7ce04dcc945f7daf34612fcf07d
2021-02-20 14:33:56 +00:00
Matěj Suchánek ca806b46b7 Avoid using Title in addNavigationLinks
Simple TitleValue object will do the same job.
I verified LinkRenderer localizes the targets.

Change-Id: Ia25659947da1d2d7e5557884b2ab9153c9c1bc43
2021-02-19 19:00:01 +01:00
Translation updater bot fa0fb1e84b Localisation updates from https://translatewiki.net.
Change-Id: I9fa983c28a3ea7b3098a84328c239bdbcc67bb7e
2021-02-18 08:42:07 +01:00
Translation updater bot eeb90040a9 Localisation updates from https://translatewiki.net.
Change-Id: I4fd12b0457d3409a20ee216f96f197e0bc4c1ad1
2021-02-17 08:41:36 +01:00
Translation updater bot 552dd86729 Localisation updates from https://translatewiki.net.
Change-Id: Ic8345610534de54a67b2688f9aba68e662b82ab9
2021-02-16 08:28:56 +01:00
Translation updater bot ec9cd9a7e0 Localisation updates from https://translatewiki.net.
Change-Id: I187e09baa3bec5cd150dc4fea063627c58374b3d
2021-02-15 10:03:28 +01:00
Daimona Eaytoy e64049c30b Create dedicated types of parser exceptions
Introduce a clear distinction between internal exceptions and
user-visible exceptions, leaving AFPException as base abstract class.

Later, it should be possible to narrow some types around, e.g. in
ParserStatus (that might work with user-visible exceptions only).

Also a future TODO is putting all the exceptions in their own namespace
(probably ...\Parser\Exception).

Change-Id: I4e33a45117f0a3e73af03cc1e3f2734beaf2b5e1
2021-02-12 13:56:02 +00:00
Matěj Suchánek c18e4a4a5f Do not serialize RunnerData to array in FilterRunner
Change-Id: Ia803042224959e516bc14bdc034421b8e80390a8
2021-02-12 14:03:50 +01:00
jenkins-bot 431226ac39 Merge "Serialize all data for edit stash" 2021-02-12 13:01:10 +00:00
Translation updater bot 8f19ca5a87 Localisation updates from https://translatewiki.net.
Change-Id: I2b21158f8d11a375bca0eb31d322a0f5a33b9c60
2021-02-12 08:50:36 +01:00
jenkins-bot 3d7da7aa29 Merge "Check response code and prevent exception in worker-abusefilter" 2021-02-12 00:59:50 +00:00
Daimona Eaytoy 607be2d5bb Check response code and prevent exception in worker-abusefilter
Bug: T274401
Change-Id: I53be8e91c8d4e85df8062504de19929994f56f15
2021-02-12 00:01:51 +00:00