Skip to content

ci: give each quibble job the dependencies and database it needs - #475

Merged
lens0021 merged 3 commits into
mainfrom
claude/pr-468-review-fixes-43uhne
Aug 18, 2026
Merged

ci: give each quibble job the dependencies and database it needs#475
lens0021 merged 3 commits into
mainfrom
claude/pr-468-review-fixes-43uhne

Conversation

@lens0021

@lens0021 lens0021 commented Aug 18, 2026

Copy link
Copy Markdown
Collaborator

Not stacked on #468 — this stands on main on its own, and #468 wants it underneath rather than on top. See "Order" below.

What was wrong

femiwiki/quibble-action resolves what to clone from the first source that answers: the dependencies input, then extension.json's requires, then .phan/config.php's directory list. wikven names no extensions in requires, so the phan config was the source in use — which made one file answer two questions that have different answers:

  • phan wants the directories whose symbols this code reaches for.
  • the wiki wants whatever will not load without it.

Translate is both. UniversalLanguageSelector is only the second, and it was missing. So naming Translate for phan's benefit handed it to the installer too, and the installer refused it:

Error: A dependency error was encountered while installing the extension "Translate":
Could not find the registration file for the extension "UniversalLanguageSelector"

Translate itself confirms these are different lists: its .phan/config.php names AbuseFilter, AdminLinks, cldr, Echo, Elastica, Scribunto and TranslationNotifications — the optional integrations it reaches for — and does not name ULS, its one hard requires.extensions dependency.

Two lists, one per job

The install list moves to quibble.yml, where someone looking for "what does CI install" would look, and .phan/config.php is left alone to be about phan. Each job then gets the list it actually needs:

PHAN_DEPENDENCIES: Gadgets Translate
WIKI_DEPENDENCIES: Gadgets Translate UniversalLanguageSelector

Wikimedia splits this the same way and for the same reason — zuul/dependencies.yaml against zuul/phan_dependencies.yaml, chosen by whether the job name carries -phan, with parameter_functions.py recursing over the first and never the second ("since for Phan we never processed them recursively"). Their two entries for Translate share two of the ten names between them.

What is not copied is the mechanism. Wikimedia needs two maps because its dependency data lives away from the job definition and a job cannot pass its own list; a workflow job is written where its list is written, so a value per job is enough and the action needs no second input.

Naming the input also settles the resolution order: an extensions entry appearing in extension.json would otherwise take the phan config's place silently, and Gadgets/Translate would stop being cloned with nothing said.

The database

Quibble installs on MySQL unless told otherwise, and wikven never runs there — bin/build.php installs with --dbtype sqlite, and maintenance/build.php carries paths that exist only under it (one writer at a time, a database file per pass, SQLITE_BUSY). So the job with the extensions installed was standing on a backend the product does not use, while the phpunit jobs stood on the right backend without the extensions. Neither was where wikven runs. db: sqlite makes coverage the one that is.

The pin moves to an unreleased main commit because no release carries the db input yet. A composite action answers an undeclared input with a warning rather than an error, so a move back to v2.0.2 would leave the line reading as though it does something while the wiki quietly returned to MySQL — noted in the workflow for whoever reviews the dependabot pull request that offers exactly that.

The test

Installing Translate makes the handler in IndexerTest reach the real lookup, which asks the database whether the page above the one under test is marked for translation — and the test had not asked for a database, so it errored with RuntimeException: Database backend disabled.

The contract holds either way: absent, Translate cannot report a translation page; installed, a page nobody marked is not one. So the test asks for a database, and is named after the contract instead of after one of the two environments. MediaWikiGroupValidator::isTestInDatabaseGroup() matches @group Database against the class doc comment and nothing else, so it is declared there.

Both sides stay exercised, because the jobs differ in what they install: the quibble jobs bring Translate along, the phpunit jobs install MediaWiki alone.

Where CI stands now

job database extensions MediaWiki
phpunit SQLite none REL1_46 + master
coverage SQLite Gadgets, Translate, ULS master
phan Gadgets, Translate REL1_46 + master

Order

This wants to land before #468, not after:

Merging this first turns #468 green without #468 having to change.

quibble-action resolves what to clone from the first source that answers:
the dependencies input, extension.json's requires, then the phan config's
directory list. wikven names no extensions in requires, so the phan config
was in use -- which made one file answer two questions that have different
answers. phan wants the directories whose symbols this code reaches for;
the wiki wants whatever will not load without it. Translate is both, but
UniversalLanguageSelector is only the second, and it is missing: naming
Translate for phan hands it to the installer too, and the installer
refuses it with "Could not find the registration file for the extension
UniversalLanguageSelector". Translate's own phan config does not name ULS
either, for the same reason.

So the install list moves to the workflow, where a reader looking for it
would look, and the phan config goes back to being about phan. Naming the
input also settles the resolution order, which an extensions entry in
extension.json would otherwise take over without a word.

Installing Translate makes the handler in IndexerTest reach the real
lookup, which asks the database whether the page above this one is marked
for translation. The contract holds either way -- absent, Translate cannot
report a translation page; installed, an unmarked page is not one -- so the
test asks for a database and is named after the contract rather than after
one of the two environments. MediaWikiGroupValidator matches @group
Database against the class doc comment and nothing else, so it goes there.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Uv1RzRurUH6wrgV5E9PESQ
@lens0021
lens0021 force-pushed the claude/pr-468-review-fixes-43uhne branch from f1e1f6d to 10b0fbe Compare August 18, 2026 13:13
@lens0021 lens0021 changed the title fix: let Translate bring the extension it cannot load without ci: name what the wiki installs, apart from what phan reads Aug 18, 2026
@lens0021
lens0021 changed the base branch from claude/phan-sees-translate to main August 18, 2026 13:13
claude added 2 commits August 18, 2026 13:33
Quibble installs on MySQL unless told otherwise, and wikven never runs
there: bin/build.php installs with --dbtype sqlite, and maintenance/build.php
carries paths that exist only under it -- one writer at a time, a database
file per pass, SQLITE_BUSY. So the job that has the extensions installed was
standing on a backend the product does not use, while the phpunit jobs stood
on the right backend without the extensions. Neither was where wikven runs.
Point coverage at sqlite and one of them is.

quibble-action grew a db input for this. It is pinned to main rather than a
tag because no release carries the input yet, and a composite action answers
an undeclared input with a warning rather than an error -- so a move back to
v2.0.2 would leave the line reading as though it does something while the
wiki quietly returns to MySQL. Noted in the workflow for whoever reviews the
dependabot pull request that offers exactly that.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Uv1RzRurUH6wrgV5E9PESQ
One list was serving both jobs, so the phan jobs cloned
UniversalLanguageSelector -- a checkout phan then never reads, since it
parses what .phan/config.php names and nothing else.

Wikimedia splits this for the same reason, into zuul/dependencies.yaml and
zuul/phan_dependencies.yaml, chosen by whether the job name carries -phan;
parameter_functions.py recurses over the first and never the second, "since
for Phan we never processed them recursively". Their two entries for
Translate share two of the ten names between them.

What stays here is the choosing, not the mechanism: Wikimedia needs two maps
because its dependency data lives away from the job definition and a job
cannot pass its own list. A workflow job is written where its list is
written, so a value per job is enough and the action needs no second input.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Uv1RzRurUH6wrgV5E9PESQ
@lens0021 lens0021 changed the title ci: name what the wiki installs, apart from what phan reads ci: give each quibble job the dependencies and database it needs Aug 18, 2026
@lens0021
lens0021 marked this pull request as ready for review August 18, 2026 14:17
@lens0021
lens0021 merged commit a911947 into main Aug 18, 2026
22 checks passed
@lens0021
lens0021 deleted the claude/pr-468-review-fixes-43uhne branch August 18, 2026 14:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants