VisualEditor: Edits triggering CAPTCHA cannot be saved
Closed, ResolvedPublic

Description

On a CAPTCHA-triggering edit, VE does not display the CAPTCHA, instead showing an alert:

Error saving data to server: Failed request: error.

Marking critical, because VE is in use by 50% of new users at enwiki, none of whom are now able to add external links for sourcing purposes.


Version: unspecified
Severity: critical

bzimport set Reference to bz50356.
TTO created this task.Via LegacyJun 28 2013, 10:01 AM
TTO added a comment.Via ConduitJun 28 2013, 12:32 PM

(In reply to comment #0)

Error saving data to server: Failed request: error.

The same error is also seen when triggering the spam blacklist.

Jdforrester-WMF added a comment.Via ConduitJun 28 2013, 8:19 PM

This depends on MediaWiki making the CAPTCHAs available through an API, which I believe is currently not done. Timo to comment.

Krinkle added a comment.Via ConduitJun 28 2013, 10:33 PM

Right now the handling of any error results the following alert:

Error saving data to server: Failed request: {api.result}.

The only variable we use is the result code, not the error code. And though the error code varies (badtoken, hookabort, needcaptcha) the result is always "error".

Fortunately (at least) the ConfirmEdit extension, and specifically the FancyCaptcha variant (which Wikimedia uses) does provide an API and exposes the following through the EditPage/ApiEdit/ApiVisualEditor result:

{

"visualeditor": {
    "result": "error",
    "edit": {
        "captcha": {
            "type": "image",
            "mime": "image/png",
            "id": "626590462",
            "url": "//alpha.wikipedia.krinkle.dev/w/index.php?title=Special:Captcha/image&wpCaptchaId=fa4e388ad7"
        },
        "result": "Failure"
    }
}

}

So it looks like we can use this to build the UI for it.

gerritbot added a comment.Via ConduitJun 29 2013, 8:27 PM

Change 71160 had a related patch set uploaded by Krinkle:
mw: Implement support for ConfirmEdit and FancyCaptcha

https://gerrit.wikimedia.org/r/71160

gerritbot added a comment.Via ConduitJun 30 2013, 3:44 AM

Change 71160 merged by jenkins-bot:
mw: Implement support for ConfirmEdit and FancyCaptcha

https://gerrit.wikimedia.org/r/71160

Jdforrester-WMF added a comment.Via ConduitJun 30 2013, 8:47 AM

This is now fixed in master and will be deployed on Monday.

Ricordisamoa added a comment.Via ConduitMar 18 2014, 3:05 AM

[[mw:Thread:Extension talk:VisualEditor/VE and ConfirmEdit]]

Add Comment