Steps to replicate the issue (include links if applicable):
Brief summary:
- Clone MediaWiki core and OAuth
- Install MediaWiki with --with-extensions
- Fetch Special:OAuthListConsumers
Script:
cd /tmp git clone --depth=1 https://gerrit.wikimedia.org/r/mediawiki/core.git git -C core/extensions/ clone --depth=1 https://gerrit.wikimedia.org/r/mediawiki/extensions/OAuth.git ln -s composer.local.json-sample core/composer.local.json composer -d core/ install php core/maintenance/run.php install --dbtype=sqlite --with-extensions --with-developmentsettings --pass=testpass0123456789 'Test Wiki' 'Test Wiki Admin' php -S localhost:12345 & sleep 1; curl -v http://localhost:12345/core/index.php/Special:OAuthListConsumers kill %1
What happens?:
Error 1: no such table: oauth_registered_consumer
What should have happened instead?:
The table should exist, there shouldn’t be an error.
Workaround:
Run update.php (or rather php maintenance/run.php update yadda yadda), which will create the tables.
Software version (on Special:Version page; skip for WMF-hosted wikis like Wikipedia):
MediaWiki core 8ce0a47689, OAuth d25e72b64f.
Other information (browser name/version, screenshots, etc.):
I’ve pretty much only tested the exact steps in the script so far (I first noticed it in setup-mediawiki + m3api-oauth2 but that uses basically the same steps). Someone™ should check whether this also affects other extensions, database types, and/or wikis without development settings. (I might do that later but not tonight :P)
- It also happens without --with-developmentsettings (but then you don’t see the exact error message in the web output, of course)
- It also happens for Wikibase (clone with --recursive, curl Special:ListProperties), so it’s probably not specific to any one extension
- …