Page MenuHomePhabricator

Fix parser tests runner to use wfGetDB correctly
Closed, ResolvedPublic


Parsoid's PHP parser tests jenkins job started failing after got merged. See stack trace below.
For now, @Krinkle reverted that patch but we need to figure out the problem in the test runner and fix it.

Wikimedia\Rdbms\DBUnexpectedError from line 113 of /workspace/src/includes/libs/rdbms/database/DBConnRef.php: Database selection is disallowed to enable reuse.
#0 /workspace/src/includes/db/CloneDatabase.php(88): Wikimedia\Rdbms\DBConnRef->tablePrefix()
#1 /workspace/src/tests/parser/ParserTestRunner.php(1331): CloneDatabase->cloneTableStructure()
#2 /workspace/src/tests/parser/ParserTestRunner.php(692): ParserTestRunner->setupDatabase()
#3 /workspace/src/tests/parser/parserTests.php(189): ParserTestRunner->runTestsFromFiles()
#4 /workspace/src/maintenance/doMaintenance.php(99): ParserTestsMaintenance->execute()
#5 /workspace/src/tests/parser/parserTests.php(200): include()
#6 {main}
INFO:backend.DevWebServer:Terminating DevWebServer
Traceback (most recent call last):
  File "/usr/local/bin/quibble", line 11, in <module> 
    load_entry_point('quibble==0.0.0', 'console_scripts', 'quibble')()
  File "/usr/local/lib/python3.5/dist-packages/quibble/", line 435, in main
  File "/usr/local/lib/python3.5/dist-packages/quibble/", line 410, in execute
  File "/usr/local/lib/python3.5/dist-packages/quibble/", line 551, in execute
    cmd, shell=True, cwd=self.mw_install_path)
  File "/usr/lib/python3.5/", line 271, in check_call
    raise CalledProcessError(retcode, cmd)
subprocess.CalledProcessError: Command 'mediawiki/services/parsoid/tools/' returned non-zero exit status 1

Event Timeline

ssastry triaged this task as High priority.Jul 24 2019, 7:20 PM
ssastry edited projects, added Parsoid-Tests; removed MediaWiki-Parser.

Change 525433 had a related patch set uploaded (by Gergő Tisza; owner: Gergő Tisza):
[mediawiki/core@master] Replace wfGetDB in ParserTestRunner

Codesearch suggests SMW is the only other thing affected, made #4166.

Change 525433 merged by jenkins-bot:
[mediawiki/core@master] Replace wfGetDB in ParserTestRunner

ssastry lowered the priority of this task from High to Medium.Mar 8 2020, 10:08 PM
cscott assigned this task to Tgr.
cscott added a subscriber: cscott.

I believe this was fixed by @Tgr in the patch above.