Page MenuHomePhabricator

"Invalid response from server." when using hCaptcha and Visual Editor
Closed, ResolvedPublicBUG REPORT

Description

Steps to Reproduce:

  1. Enable hCaptcha (or ReCaptcha) and configure it.
  2. Edit or create a page with Visual Editor as a user that has to see a captcha.
  3. Try to submit the edit.

Actual Results:
See Error "Invalid Response from Server", click "Dismiss" and notice you're unable to send in a edit at all.

Expected Results:
Either hCaptcha working and showing (like QuestyCaptcha does, even though buggy) or at least not throwing an error that disables users ability to send in edits.

Comment:
On the wiki page for the extension reCaptcha is mentioned to 'not work' with visual editor, but i didnt expect an error blocking users to edit to be 'not working'. I rather expected it's simply not shown.
hCaptcha does not mention it not working with visual editor at all. Given visual editor is now used out of the box, supporting it would be quite cool.

Screenshot:

image.png (535×701 px, 55 KB)

Event Timeline

D3nnis3n updated the task description. (Show Details)

I saw that task and hence assumed Visual Editor would now work with ReCaptcha, but as i noted in my OP as a "side-notice", ReCaptcha is not working either.

https://www.mediawiki.org/w/index.php?title=Extension%3AConfirmEdit&type=revision&diff=4156765&oldid=4153726

Added some documentation to say it doesn't work, for now

Probably needs something like rECOEe614050b6ab3: ConfirmEdit: Support No CAPTCHA reCAPTCHA did for VE support

I wonder why the code seems to be there for support, but the docs are as such... Out of date?

Thank you. I also added a screenshot to make clear where it happens and how it looks, hopefully that helps.
And hopefully this time my report was formatted correctly :)

Change 674913 had a related patch set uploaded (by Alistair3149; author: Alistair3149):
[mediawiki/extensions/ConfirmEdit@master] Support hCaptcha for VisualEditor

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

Submitted a patch based on the NoCaptchaReCaptcha implementation. The config flags are also refactored to not use global variables.

Change 674913 merged by jenkins-bot:

[mediawiki/extensions/ConfirmEdit@master] Support hCaptcha for VisualEditor

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

Change 681972 had a related patch set uploaded (by Alistair3149; author: Alistair3149):

[mediawiki/extensions/ConfirmEdit@REL1_35] Support hCaptcha for VisualEditor

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

Thanks for everyone's help! Cherry-picked the patch for REL1_35.

Change 681980 had a related patch set uploaded (by Reedy; author: Alistair3149):

[mediawiki/extensions/ConfirmEdit@REL1_36] Support hCaptcha for VisualEditor

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

Change 681972 merged by jenkins-bot:

[mediawiki/extensions/ConfirmEdit@REL1_35] Support hCaptcha for VisualEditor

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

Change 681980 merged by jenkins-bot:

[mediawiki/extensions/ConfirmEdit@REL1_36] Support hCaptcha for VisualEditor

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

On re-reading this bug report, I'm not sure if the patch actually fixes the issue. The description mentions an issue affecting ReCaptcha as well as HCaptcha. The patch implemented HCaptcha support, but has not touched the existing ReCaptcha code at all.

Reedy renamed this task from "Invalid response from server." when using HCaptcha and Visual Editor to "Invalid response from server." when using hCaptcha and Visual Editor.Apr 29 2021, 12:00 AM
Reedy updated the task description. (Show Details)
matmarex changed the task status from Open to Stalled.May 26 2021, 4:59 PM
matmarex removed matmarex as the assignee of this task.

Waiting for the task's author to respond whether this resolves their problem.

Hello,
thank you so much, this indeed fixes the problem and spam is gone while anonymous users can still contribute with VE active.

(I'm only using HCaptcha as ReCaptcha is ineffective, but it had the same issue. So if ReCaptcha hasn't been touched, that is still broken)

matmarex assigned this task to alistair3149.

OK, thanks for responding! I guess we should resolve this, and if anyone else is experiencing the issue with ReCaptcha, they should file a separate bug.