Page MenuHomePhabricator

Minerva test builds are failing after recent Selenium upgrades
Open, Needs TriagePublicBUG REPORT

Description

Steps to replicate the issue (include links if applicable):

What happens?:
Latest build has failed

Error: Cannot submit login form
    at async LoginPage.login (/src/node_modules/wdio-mediawiki/LoginPage.js:38:3)
    at async LoginPage.loginAdmin (/src/node_modules/wdio-mediawiki/LoginPage.js:52:3)
    at async iAmLoggedIn (/src/tests/selenium/features/step_definitions/common_steps.js:51:2)
    at async iAmLoggedIntoTheMobileWebsite (/src/tests/selenium/features/step_definitions/common_steps.js:57:2)
    at async Context.<anonymous> (/src/tests/selenium/specs/watchstar.js:16:3)

This suggests an issue with logging in to the beta cluster.

What should have happened instead?:
Test should be green

Software version (on Special:Version page; skip for WMF-hosted wikis like Wikipedia):

Other information (browser name/version, screenshots, etc.):
Likely relates to T293084 T389536 as these changed around same time.

Details

Related Changes in Gerrit:

Event Timeline

I'm not sure at first glance what might be wrong, but one thing worth emphasizing: before last week's changes, tests were not waiting for async assertions. So, failing assertions did not cause test failures, which in turn means the test might have been broken before our changes for all we know.

Anyway. wdio-mediawiki does not give us a video recording of the before(Each) hooks (T389901). And there are no interesting logs. So, I followed https://www.mediawiki.org/wiki/Selenium/Getting_Started/Run_tests_targeting_Beta_cluster to run the test locally. Sure enough, it cannot login: the page shows a captcha and selenium doesn't know about it.

Sure enough, it cannot login: the page shows a captcha and selenium doesn't know about it.

Actually, that might have been because I made too many attempts too quickly. But well, selenium tests are parallelized and have retries, so... And it was failing because the on-wiki docs have just an example username and password, of course. So I created https://meta.wikimedia.beta.wmflabs.org/wiki/Special:Contributions/T389889 and tried again. Here's what I got:

image.png (372×2 px, 36 KB)

(for searching: "No active login attempt is in progress for your session."). I tried logging in from the browser and it worked. Then again via selenium and again it failed.

Jdlrobson subscribed.

Seems like an issue with beta cluster and CentralAuth? I had a similar issue logging in on mobile today.

Change #1132750 had a related patch set uploaded (by Jdlrobson; author: Jdlrobson):

[mediawiki/skins/MinervaNeue@master] Login via desktop site

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

Change #1132750 merged by jenkins-bot:

[mediawiki/skins/MinervaNeue@master] Login via desktop site

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