Click in the URL above or follow the following steps:
- Go to [[pt:Special:Sandbox]]
- Select the action "abusefiltercheckmatch" in the drop-down menu
- Type in the filter field: length(user_name)>0
- Type in the vars field: {"user_name":"Foo"}
After this, click in "Make the request".
Expected result
{
"abusefiltercheckmatch": {
"result": true
}}
Actual result
{
"abusefiltercheckmatch": {
"result": false
}}
A similar test with e.g. the filter "user_name===null" and the same JSON in the vars field gives
{
"abusefiltercheckmatch": {
"result": true
}}
So, it seems AbuseFilter is not setting the variables properly.
Notes:
- If you don't have the appropriate user rights you'll see something like
{
"servedby": "mw1141",
"error": {
"code": "unknownerror",
"info": "Unknown error: \"permissiondenied\""
}}
- In case I'm using the wrong syntax to test this, maybe this bug could be reused to request an improved documentation for this API?
Version: unspecified
Severity: normal
URL: https://pt.wikipedia.org/wiki/Especial:ApiSandbox#action=abusefiltercheckmatch&format=json&filter=length(user_name)%3E0&vars=%7B%22user_name%22%3A%22Foo%22%7D