Page MenuHomePhabricator

Beta cluster: The content model 'JadeJudgment' is not registered
Closed, ResolvedPublicBUG REPORT

Description

Steps to reproduce:
Visit https://en.wikipedia.beta.wmflabs.org/wiki/Jade:Diff/376902
Expected result: Works, like JadeEntity does at https://en.wikipedia.beta.wmflabs.org/wiki/Jade:Diff/1234556

Actual result
[XmlviawQBHcAACAyn7IAAACR] /wiki/Jade:Diff/376902 MWUnknownContentModelException from line 186 of /srv/mediawiki/php-master/includes/content/ContentHandlerFactory.php: The content model 'JadeJudgment' is not registered on this wiki.
See https://www.mediawiki.org/wiki/Content_handlers to find out which extensions handle this content model.

Backtrace:

#0 /srv/mediawiki/php-master/includes/content/ContentHandlerFactory.php(251): MediaWiki\Content\ContentHandlerFactory->validateContentHandler(string, NULL)
#1 /srv/mediawiki/php-master/includes/content/ContentHandlerFactory.php(174): MediaWiki\Content\ContentHandlerFactory->createContentHandlerFromHook(string)
#2 /srv/mediawiki/php-master/includes/content/ContentHandlerFactory.php(83): MediaWiki\Content\ContentHandlerFactory->createForModelID(string)
#3 /srv/mediawiki/php-master/includes/page/WikiPage.php(300): MediaWiki\Content\ContentHandlerFactory->getContentHandler(string)
#4 /srv/mediawiki/php-master/includes/page/WikiPage.php(286): WikiPage->getContentHandler()
#5 /srv/mediawiki/php-master/includes/actions/Action.php(98): WikiPage->getActionOverrides()
#6 /srv/mediawiki/php-master/includes/actions/Action.php(155): Action::factory(string, WikiPage, RequestContext)
#7 /srv/mediawiki/php-master/includes/MediaWiki.php(157): Action::getActionName(RequestContext)
#8 /srv/mediawiki/php-master/includes/MediaWiki.php(889): MediaWiki->getAction()
#9 /srv/mediawiki/php-master/includes/MediaWiki.php(535): MediaWiki->main()
#10 /srv/mediawiki/php-master/index.php(47): MediaWiki->run()
#11 /srv/mediawiki/w/index.php(3): require(string)
#12 {main}

Also reproducible at https://en.wikipedia.beta.wmflabs.org/wiki/Jade:Revision/380836 and https://en.wikipedia.beta.wmflabs.org/wiki/Jade:Page/188553

This formatted as plain HTML output (body tag which include the text in paragraphs) - should it be shown differently (separate from the underlying issue)

Event Timeline

Restricted Application added a subscriber: Aklapper. · View Herald Transcript
DannyS712 changed the subtype of this task from "Task" to "Bug Report".Mar 11 2020, 11:12 PM
DannyS712 moved this task from Unsorted to Reports on the User-DannyS712 board.
DannyS712 updated the task description. (Show Details)

Version info:
Core at: 1.35.0-alpha (e569e34)
Jade at: 0.0.1 (9c7183d)

Change 579086 had a related patch set uploaded (by DannyS712; owner: DannyS712):
[mediawiki/extensions/Jade@master] Restore support for JadeJudgment content handler

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

Was something done to clean up prod enwiki? Or is your example just new enough it works?

Should we be looking to clean up/update the old ones?

Was something done to clean up prod enwiki? Or is your example just new enough it works?

Should we be looking to clean up/update the old ones?

Jade has (as far as I can tell) never been deployed on production

Hi @DannyS712, thanks for the bug report. It looks like these pages that fail under the Jade namespace are due to a much older prototype that used a different content model (JadeJudgment), and also uses a different entity schema.
The pages on beta that you listed do not have much in common with the current state of the extension and can most likely just be removed.

Hi @DannyS712, thanks for the bug report. It looks like these pages that fail under the Jade namespace are due to a much older prototype that used a different content model (JadeJudgment), and also uses a different entity schema.
The pages on beta that you listed do not have much in common with the current state of the extension and can most likely just be removed.

So all existing pages should just be deleted if they use the old content model?
Is it possible to delete pages that don't have a content handler?

So all existing pages should just be deleted if they use the old content model?
Is it possible to delete pages that don't have a content handler?

Yes, we do not need to keep any Jade pages which use the older JadeJudgment content model.
Right now, you won't be able to delete a page that does not have a content handler from the UI.
Jade is still a work-in-progress and we are doing a lot of testing on Beta right now as we finish our MVP.
We do have a some cleanup tasks planned once we finish and will be able to clean these older pages up at that time.

@DannyS712 are you seeing more than those three pages failing?

Looks to be, at least on beta enwiki

MariaDB [enwiki]> select * from page where page_content_model like '%Jade%';
+---------+----------------+-----------------+-------------------+------------------+-------------+----------------+----------------+-------------+----------+--------------------+--------------------+-----------+
| page_id | page_namespace | page_title      | page_restrictions | page_is_redirect | page_is_new | page_random    | page_touched   | page_latest | page_len | page_content_model | page_links_updated | page_lang |
+---------+----------------+-----------------+-------------------+------------------+-------------+----------------+----------------+-------------+----------+--------------------+--------------------+-----------+
|  191117 |            810 | Page/188553     |                   |                0 |           0 | 0.940975688061 | 20180606150931 |      380840 |      269 | JadeJudgment       | 20180606150931     | NULL      |
|  192131 |            810 | Revision/380836 |                   |                0 |           1 | 0.554114349175 | 20180709213329 |      381955 |       97 | JadeJudgment       | 20180709213228     | NULL      |
|  193466 |            810 | Diff/376902     |                   |                0 |           0 | 0.111266912686 | 20190706205918 |      387144 |      782 | JadeJudgment       | 20181119202117     | NULL      |
|  204651 |            810 | Diff/1234556    |                   |                0 |           0 | 0.945361016367 | 20200311231325 |      415995 |     2338 | JadeEntity         | 20200311231325     | NULL      |
|  204875 |            810 | Diff/1234557    |                   |                0 |           1 | 0.263973874421 | 20200228200711 |      414994 |        2 | JadeEntity         | 20200228200711     | NULL      |
+---------+----------------+-----------------+-------------------+------------------+-------------+----------------+----------------+-------------+----------+--------------------+--------------------+-----------+
5 rows in set (0.11 sec)

For future reference, when an extension that provides a content model is removed, the content model should be mapped to UnsupportedContentHandler in $wgContentHandlers. That's probably not needed/wanted here, but I thought I'd spread the word :)

Just ran into this again - I suggest simply deleting all pages with the JadeJudgement content model

Jade is undeployed from beta: T281418: Undeploy JADE extension from beta cluster Fixing this should be easier now. Maybe what Daniel has suggested?

Ladsgroup claimed this task.

I can't reproduce the error anymore given that jade is gone. Let's just call it done?

I can't reproduce the error anymore given that jade is gone. Let's just call it done?

Still reproducible at the second url:

Is that error related to jade and its content model? It doesn't look like it TBH

Is that error related to jade and its content model? It doesn't look like it TBH

Hmm, that error used to be about Jade content model not being registered - I would guess its due to the Jade namespace no longer being registered though. But its the beta cluster, so it doesn't really matter.

Change 579086 abandoned by Ladsgroup:

[mediawiki/extensions/Jade@master] Restore support for JadeJudgment content handler

Reason:

This repo is archived: T281430

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