Commit graph

4171 commits

Author SHA1 Message Date
Daimona Eaytoy 1ae14697b5 Don't use globals for filter validation
Some of them are available from the AbuseFilterViewEdit object, the
others from its config.

Change-Id: I8495c8cc03ef86919b325798a2c08ce7c4df277f
2018-07-05 19:57:30 +02:00
jenkins-bot b86208d381 Merge "Add phan seccheck to composer and remove deprecated module" 2018-07-05 17:34:38 +00:00
Translation updater bot 97904a38b7 Localisation updates from https://translatewiki.net.
Change-Id: I47dc7c15e4d2ed525bbd85246a3d2b06f4c0f1ac
2018-07-03 22:16:24 +02:00
jenkins-bot a85e8f5588 Merge "Abstract methods in ViewEdit related to filter saving" 2018-07-02 22:18:37 +00:00
Translation updater bot 735e8466b8 Localisation updates from https://translatewiki.net.
Change-Id: I82293aa87794c8a922f5d5a36131df250177800b
2018-07-02 22:10:17 +02:00
Daimona Eaytoy f9687ad678 Abstract methods in ViewEdit related to filter saving
Actually, it seems like I almost got it right at the first try. I tested
every validation scenario and it worked as espected, so ready for
review.

Bug: T193596
Change-Id: I7fd1798030d83292ce46543e25c0c431ec345a28
2018-07-02 20:27:05 +02:00
Daimona Eaytoy ca91e854ed Bump equivset to 1.3 to avoid PHP fatal error
While trying to fix the fatal error reported in the task, I first tried
to bump equivset to a more recent version, and it seems to have fixed
it. I'm not sure whether this could lead to regressions, further
investigation coming.

Bug: T189560
Change-Id: I92bf98157a2b656a892e1d05deb4868c42e27fcd
2018-07-02 13:51:31 +02:00
jenkins-bot 8d9a564aee Merge "Add colon to "Action type" field on Special:AbuseFilter/test" 2018-07-01 21:43:40 +00:00
Translation updater bot f1a661a132 Localisation updates from https://translatewiki.net.
Change-Id: I97ae16e57c087f7b2474aecbb3b7f0f2ea268b38
2018-07-01 22:06:01 +02:00
Translation updater bot d0a00ce049 Localisation updates from https://translatewiki.net.
Change-Id: I039e2a4f8fa68d7c161ab63c27cfc568f860e19c
2018-06-30 22:30:08 +02:00
Daimona Eaytoy 7104c40518 Copy levels documentation on AbuseFilterParser
doLevel- functions are currently documented in AFPToken. This patch
copies such comments on docblocks in AbuseFilterParser, the place where
this docs can really be helpful.

Change-Id: I4e47e760a56800faa9b0a1146e0d79f8955dca9a
2018-06-30 20:35:49 +02:00
Translation updater bot e645ddcdf8 Localisation updates from https://translatewiki.net.
Change-Id: Ib543b2c037fc163a541f1c960bc794ac1cb9f7d0
2018-06-29 22:24:59 +02:00
jenkins-bot cda8e588be Merge "Add min and max date selectors to AbuseLog" 2018-06-29 12:41:03 +00:00
Daimona Eaytoy f6eaba0822 Add min and max date selectors to AbuseLog
Reused code from ViewExamine and ViewTestBatch where we do the same
thing.

Bug: T99650
Change-Id: Ib33071aed69626cfa4a15435b4aef71096deba8b
2018-06-29 11:52:14 +02:00
Guycn2 b40ded69cf Add colon to "Action type" field on Special:AbuseFilter/test
(for consistency with other fields on this page)

Change-Id: I21209cd335e6d6d65378963cbef908f928c84569
2018-06-29 03:41:25 +00:00
jenkins-bot 079f760b47 Merge "Make disabled variables not overridable" 2018-06-29 01:28:36 +00:00
Daimona Eaytoy 3a1ec5d229 Add missing i18n for sanitize function
The function was added with Ic916a6f8976e486d62d65156fa2dab56a55cf22a
but doesn't have messages for the dropdown.

Change-Id: Ibd7567a2b5277f6529e796a38871846abbfb4d54
2018-06-29 00:52:19 +02:00
Daimona Eaytoy ce83417068 Make disabled variables not overridable
Disabled vars can currently be overwritten by assigning them custom
values (e.g. old_text := 'foo'). However, this shouldn't be allowed to
avoid confusion.

Change-Id: I49136bf19371aee1e8068a9ae621310e1ab97c86
2018-06-28 22:40:09 +02:00
Translation updater bot 877d8ea608 Localisation updates from https://translatewiki.net.
Change-Id: I94ab0a54d237a90ea4a06364f8395b9e2719d234
2018-06-28 22:20:47 +02:00
Translation updater bot 74f5327e3f Localisation updates from https://translatewiki.net.
Change-Id: I99fdcdff35b586fed06e14d379c7dbf23d1beb19
2018-06-27 22:17:48 +02:00
jenkins-bot 02ca0be215 Merge "Fix SQLite syntax errors" 2018-06-27 00:33:18 +00:00
jenkins-bot 8b0f289e10 Merge "Stop computing removed variables and show custom error message" 2018-06-27 00:20:38 +00:00
Translation updater bot cfc1724f13 Localisation updates from https://translatewiki.net.
Change-Id: Iff2ac997739610ec49474d9fd08654729ff07087
2018-06-26 22:13:34 +02:00
jenkins-bot 4fb0cff163 Merge "Use content language for the revdel dropdown" 2018-06-26 18:41:13 +00:00
Daimona Eaytoy 79ec4ebf8b Stop computing removed variables and show custom error message
Old_text and old_html were disabled a long time ago. With this patch,
the user will get a custom error message if trying to use them (instead
of the unrecognisedvar one), plus they'll stop appearing in /examine and
/details, unless they were computed for the examined edit (and in that case, their description message is now restored). Lastly, added a precisation to their messages.

Bug: T190698
Change-Id: Ife168522e6b1d8eb94ebbb8a16ae8831ec1dc497
2018-06-26 20:02:31 +02:00
Daimona Eaytoy 61be1e9149 Fix SQLite syntax errors
The sync up made in I026472dec2629a969c46feb046f7fe64d8ab8144 introduced
several syntax errors for SQLite installer. They should now be all fixed.

Change-Id: I5fbe8b3719abef68d2549f119720b02fdd747a06
2018-06-26 14:50:57 +02:00
Daimona Eaytoy c75bc35f7d Rename lists to arrays
Arrays were introduced with the name "lists". While it **may** look
user-friendlier and so on, it actually uses a wrong name: lists are
different from arrays. I ran a grep and I should've replaced
every occurrence, plus everything seems to work, however a double check
wouldn't be bad.

Change-Id: I6a858f02f5dd9250ba7e1abf9c6422fd98758c9e
2018-06-26 14:42:23 +02:00
Daimona Eaytoy 40d9c5b027 Use content language for the revdel dropdown
Instead of the language set in user preferences.

Bug: T198182
Change-Id: I9f105cc3c926c51686ebb65ffbfffbbc161f9868
2018-06-26 14:37:13 +02:00
jenkins-bot 240e264833 Merge "Make /test filterable by action type" 2018-06-26 01:24:16 +00:00
jenkins-bot 1481b40b5d Merge "Make buildTestConditions more flexible" 2018-06-26 01:22:35 +00:00
jenkins-bot 625f1b92cd Merge "Reduce form whitespace on Special:AbuseFilter and compact variables" 2018-06-26 01:18:04 +00:00
Daimona Eaytoy 1394da924f Make /test filterable by action type
Bug: T20288
Depends-On: I2c51b695262b132a5c7cdfab20d56e36f43c7448
Change-Id: I9887c586955c1a1b34dbe641a8f9ad34de7a2e1d
2018-06-26 00:48:09 +00:00
Daimona Eaytoy c5da9cc6df Make buildTestConditions more flexible
This way, we can specify an action and it'll return only conditions for
that specific action. This is especially thought to make results
filterable by action type.

Change-Id: I2c51b695262b132a5c7cdfab20d56e36f43c7448
2018-06-26 00:45:33 +00:00
Translation updater bot e5b0846197 Localisation updates from https://translatewiki.net.
Change-Id: I10e13e33936b8fccfe45600a982960e4b35a4d53
2018-06-25 22:22:00 +02:00
jenkins-bot 40e7f440e6 Merge "Ace: use built-in function indexToPosition" 2018-06-25 10:41:42 +00:00
Translation updater bot d4db0b49d4 Localisation updates from https://translatewiki.net.
Change-Id: I54f6b256343018d4a04b9ccecdd46cc62526195c
2018-06-24 22:25:18 +02:00
Daimona Eaytoy 3c1dae9e14 Allow users with abusefilter-view-private to use testing interface
Now the required need will be abusefilter-modify OR
abusefilter-view-private for /tools, /test and /examine.

Bug: T193903
Change-Id: I3f1a91a2cc1df2272e5d4099cefd7c649a0683d5
2018-06-24 14:10:38 +00:00
jenkins-bot c34eda8936 Merge "Introduce sanitize() function" 2018-06-24 13:53:46 +00:00
Translation updater bot 4d97779c51 Localisation updates from https://translatewiki.net.
Change-Id: I2489b2da7cd75dfdd082e6a343726b266441a0a7
2018-06-21 22:42:20 +02:00
Daimona Eaytoy fcc07db95c Reduce form whitespace on Special:AbuseFilter and compact variables
The conversion to OOUI brought some extra whitespace that creates some
problems while viewing the page, especially with specific skins. This
patch compacts four different form fields in a single one, having the
side benefit of reducing the amount of used variables.

Bug: T189425
Change-Id: I75aa83e36d12db65d8b54c76b3ea14c8c797215e
2018-06-19 12:13:29 +02:00
Translation updater bot 0e4df34261 Localisation updates from https://translatewiki.net.
Change-Id: I43d59b7b098b2fbdf7b11be0b5562dabd38b3329
2018-06-18 22:09:25 +02:00
Translation updater bot 58ed24048d Localisation updates from https://translatewiki.net.
Change-Id: I5d47cdfd497ade70800e0fa33c8256c916b0d6a7
2018-06-17 22:27:46 +02:00
Translation updater bot 9dfbd0d63b Localisation updates from https://translatewiki.net.
Change-Id: Ibdb83009f28a5649021ed053c7a90de0a720f061
2018-06-16 22:25:54 +02:00
Translation updater bot 03158e1272 Localisation updates from https://translatewiki.net.
Change-Id: I75bc6d1a4fb91ea0a32efc0a37ae10b312a12910
2018-06-15 22:35:34 +02:00
Translation updater bot c31f384f5d Localisation updates from https://translatewiki.net.
Change-Id: I5dae60f0f98a523ad3f851d88326a32e9e0e1f20
2018-06-14 22:44:15 +02:00
jenkins-bot 519db0c6fc Merge "Make the "Load filter ID:" field on Special:AbuseFilter/test wider" 2018-06-13 23:03:08 +00:00
Translation updater bot 18b46d71cb Localisation updates from https://translatewiki.net.
Change-Id: I68db4a2ea26ba7fc6a89f79f8cf3badf3791b42e
2018-06-13 22:22:27 +02:00
Bartosz Dziewoński abe72f2937 Make the "Load filter ID:" field on Special:AbuseFilter/test wider
The translation can be a lot longer in languages which have no common
abbreviation like "ID" for the word "identifier". For example, the
label currently wraps over 3 lines in Polish (pl).

Change-Id: I822aafb52bbe840c00d2f0edbaeec37e3748f96f
2018-06-13 02:32:48 +00:00
Daimona Eaytoy 29492513cf Add phan seccheck to composer and remove deprecated module
Seccheck is currently being executed as non-voting, but it always
succeeds because AbuseFilter is not requiring it in composer. Instead,
let's add it: tests will start to fail, but we'll be able to see how
things are going with it. As a bonus, remove the mediawiki.api.parse
module, which is deprecated in 1.32 and replaced by mediawiki.api
(already loaded).

Change-Id: I094a8af4f97c03f8b538ede00420b123de25138a
2018-06-12 15:37:03 +02:00
Translation updater bot e2232714f8 Localisation updates from https://translatewiki.net.
Change-Id: Iaa5e133700405433dae57dfcb9da0c6727ff25b4
2018-06-11 22:33:20 +02:00