Skip to content

Use parsoid-external-ci-access.beta.wmflabs.org for testing#1245

Closed
cscott wants to merge 3 commits intowikimedia:masterfrom
cscott:T247589
Closed

Use parsoid-external-ci-access.beta.wmflabs.org for testing#1245
cscott wants to merge 3 commits intowikimedia:masterfrom
cscott:T247589

Conversation

@cscott
Copy link
Contributor

@cscott cscott commented Mar 13, 2020

Bug: T247589

@cscott
Copy link
Contributor Author

cscott commented Mar 13, 2020

Two failing tests:
'item requests > should request page lints. no revision:' is failing for some reason, even though this works fine from CLI:

curl -d '{}' -X POST -H 'Content-Type: application/json' -H 'Host: en.wikipedia.beta.wmflabs.org' http://parsoid-external-ci-access.beta.wmflabs.org/w/rest.php/en.wikipedia.beta.wmflabs.org/v3/transform/wikitext/to/lint/User%3APchelolo%2FLintTest

curl -d '{}' -X POST -H 'Content-Type: application/json' -H 'Host: en.wikipedia.beta.wmflabs.org' http://parsoid-external-ci-access.beta.wmflabs.org/w/rest.php/en.wikipedia.beta.wmflabs.org/v3/transform/wikitext/to/lint/User%3APchelolo%2FLintTest/409437

It seems to be the redirect which is causing problems, since the redirect goes to:
https://en.wikipedia.beta.wmflabs.org/w/rest.php/en.wikipedia.beta.wmflabs.org/v3/transform/wikitext/to/lint/User%3APchelolo%2FLintTest/409437
not parsoid-external-ci-access.beta.wmflabs.org

Second failure is 'router - security > should forward cookies on request to parsoid'.
That gets an assertion error "Mocks not satisfied". Probably the mock needs to be updated?

Bug: T247589
Change-Id: I30de94cf4c4e0b03fcccae534290e0f4ca0ef751
When the parsoid_uri is not the same as the site config domain, the
"native" redirect handling for page lints will send restbase to the
wrong place.

Change-Id: I4da0a4213332af7dec850b94f7f8fad65745aa1f
@cscott
Copy link
Contributor Author

cscott commented Mar 13, 2020

Ok, this should fix the tests.

It's possible the issue with parsoid.js:getLintErrors() is a parsoid bug with how the redirect is generated.

There are some transient failures which seem to be caused by github parallelizing the tests which create and mutate https://en.wikipedia.beta.wmflabs.org/wiki/Save_test

@cscott
Copy link
Contributor Author

cscott commented Mar 13, 2020

The "prevent concurrent execution" thing doesn't actually seem to work. The page name should include node-version, cassandra-version, test-target, and test-mode to prevent conflicts, instead of trying to keep the test runs separate.

…low matrix

We were getting spurious errors in the tests which test the save API,
all of which were writing to
https://en.wikipedia.beta.wmflabs.org/wiki/Save_test
in parallel.

Change-Id: I863750730c26674882c21b391499fa2bcdeb9258
@cscott
Copy link
Contributor Author

cscott commented Mar 14, 2020

OK, this is good now.

@Pchelolo
Copy link
Contributor

Hm.. thank you for setting up the parsoid-ci-access, however with the test fixes - I'm not sure they're correct. For example the page_save test that you're setting the page via an env variable now is actually completely mocked and should be not calling real services (we were getting complaints for creating gazillion pages on beta).

I think I should just take it on from here and try to poke some other approaches to fixing those tests, there's probably just something hardcoded somewhere, nock is not a very user-friendly library to debug..

@Pchelolo
Copy link
Contributor

Superseded by #1248 - mostly same code, thank you @cscott, just changed the save_api to actually use the mocks - we have switched that off cause parsoid and MW was sharing the domain and we couldn't use nock properly, now they don't so we can return to using the mocks.

@Pchelolo Pchelolo closed this Mar 16, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

2 participants