Page MenuHomePhabricator

Default content model of flow-board is applying to non-Flow pages on officewiki, making them inaccessible
Closed, ResolvedPublic

Description

This page was a wikitext archive page. https://office.wikimedia.org/wiki/User_talk:Whatamidoing_%28WMF%29/Archive_1
The Board history there gives this error: [ed1c2cae] 2015-06-25 02:11:35: Fatal exception of type "Flow\Exception\InvalidDataException"

Event Timeline

Quiddity created this task.Jun 25 2015, 2:13 AM
Quiddity raised the priority of this task from to High.
Quiddity updated the task description. (Show Details)
Restricted Application added a subscriber: Aklapper. · View Herald TranscriptJun 25 2015, 2:13 AM

It seems this was caused by a combination of 4c33ff5b535d27b07ec41be018a54de5cb78689c (the part about sub-pages now being occupied) and not having either page_content_model or rev_content_model populated (T103388: E11. Write maintenance script to populate page.page_content_model, revision.rev_content_*, archive.ar_content_*) because wgContentHandlerUseDB was previously off.

https://office.wikimedia.org/w/api.php?action=query&prop=revisions&titles=User_talk:Whatamidoing%20%28WMF%29/Archive%201&rvprop=ids|user|timestamp|comment|content&rvlimit=500 shows old posts being wrongly interpreted as Flow content:

All of the talk namespaces are occupied on Office wiki (and only there, there are no occupied namespaces on any other production wiki), so this issue does not apply to MediaWiki.org or elsewhere.

mattflaschen@tin:~$ mwscript eval.php --wiki=officewiki        
> 

> var_export( $wgContentHandlerUseDB );
true
> var_export( $wgNamespaceContentModels );
array (
  2600 => 'flow-board',
  470 => 'JsonSchema',
)
> var_export( $wgFlowOccupyNamespaces );
array (
  0 => 1,
  1 => 3,
  2 => 5,
  3 => 7,
  4 => 9,
  5 => 11,
  6 => 13,
  7 => 15,
  8 => 91,
  9 => 93,
  10 => 101,
  11 => 111,
  12 => 113,
  13 => 829,
)
mysql:research@s3-analytics-slave [officewiki]> SELECT page_id, page_namespace, page_title, page_content_model FROM page WHERE page_title = 'Whatamidoing_(WMF)/Archive_1';
+---------+----------------+------------------------------+--------------------+
| page_id | page_namespace | page_title                   | page_content_model |
+---------+----------------+------------------------------+--------------------+
|   11829 |              3 | Whatamidoing_(WMF)/Archive_1 | NULL               |
+---------+----------------+------------------------------+--------------------+
1 row in set (0.01 sec)
mysql:research@s3-analytics-slave [officewiki]> SELECT rev_id, page_title, page_namespace, rev_content_model FROM revision JOIN page ON rev_page = page_id WHERE page_title = 'Whatamidoing_(WMF)/Archive_1';
+--------+------------------------------+----------------+-------------------+
| rev_id | page_title                   | page_namespace | rev_content_model |
+--------+------------------------------+----------------+-------------------+
|  95478 | Whatamidoing_(WMF)/Archive_1 |              3 | NULL              |
| 106259 | Whatamidoing_(WMF)/Archive_1 |              3 | NULL              |
| 106283 | Whatamidoing_(WMF)/Archive_1 |              3 | NULL              |
| 106286 | Whatamidoing_(WMF)/Archive_1 |              3 | NULL              |
| 106287 | Whatamidoing_(WMF)/Archive_1 |              3 | NULL              |
| 106288 | Whatamidoing_(WMF)/Archive_1 |              3 | NULL              |
| 106294 | Whatamidoing_(WMF)/Archive_1 |              3 | NULL              |
| 106896 | Whatamidoing_(WMF)/Archive_1 |              3 | NULL              |
| 106906 | Whatamidoing_(WMF)/Archive_1 |              3 | NULL              |
| 107301 | Whatamidoing_(WMF)/Archive_1 |              3 | NULL              |
| 113495 | Whatamidoing_(WMF)/Archive_1 |              3 | NULL              |
| 113498 | Whatamidoing_(WMF)/Archive_1 |              3 | NULL              |
| 113549 | Whatamidoing_(WMF)/Archive_1 |              3 | NULL              |
| 115331 | Whatamidoing_(WMF)/Archive_1 |              3 | NULL              |
| 115335 | Whatamidoing_(WMF)/Archive_1 |              3 | NULL              |
| 121298 | Whatamidoing_(WMF)/Archive_1 |              3 | NULL              |
| 121370 | Whatamidoing_(WMF)/Archive_1 |              3 | NULL              |
| 121432 | Whatamidoing_(WMF)/Archive_1 |              3 | NULL              |
| 121441 | Whatamidoing_(WMF)/Archive_1 |              3 | NULL              |
| 121543 | Whatamidoing_(WMF)/Archive_1 |              3 | NULL              |
| 121545 | Whatamidoing_(WMF)/Archive_1 |              3 | NULL              |
| 121546 | Whatamidoing_(WMF)/Archive_1 |              3 | NULL              |
| 121549 | Whatamidoing_(WMF)/Archive_1 |              3 | NULL              |
| 123895 | Whatamidoing_(WMF)/Archive_1 |              3 | NULL              |
| 123896 | Whatamidoing_(WMF)/Archive_1 |              3 | NULL              |
+--------+------------------------------+----------------+-------------------+
25 rows in set (0.01 sec)

We may to roll back the subpage change then write and run T103388: E11. Write maintenance script to populate page.page_content_model, revision.rev_content_*, archive.ar_content_*, then redo the subpage one.

Or, we could check that all the Flow pages have a non-NULL content model and have T103388: E11. Write maintenance script to populate page.page_content_model, revision.rev_content_*, archive.ar_content_* take that into account.

Mattflaschen-WMF renamed this task from Flow subpage conversion included archive pages to Default content model is applying to non-Flow pages, making them inaccessible.Jun 25 2015, 5:28 AM
Mattflaschen-WMF renamed this task from Default content model is applying to non-Flow pages, making them inaccessible to Default content model of flow-board is applying to non-Flow pages on officewiki, making them inaccessible.
Mattflaschen-WMF set Security to None.

Change 221011 had a related patch set uploaded (by Mattflaschen):
Temporarily make subpages in occupied namespaces non-Flow again

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

Change 221011 merged by jenkins-bot:
Temporarily make subpages in occupied namespaces non-Flow again

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

Change 221305 had a related patch set uploaded (by Catrope):
Temporarily make subpages in occupied namespaces non-Flow again

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

Change 221305 merged by jenkins-bot:
Temporarily make subpages in occupied namespaces non-Flow again

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

Change 221305 merged by jenkins-bot:
Temporarily make subpages in occupied namespaces non-Flow again
https://gerrit.wikimedia.org/r/221305

This is deployed now, and https://office.wikimedia.org/wiki/User_talk:Whatamidoing_%28WMF%29/Archive_1 works again. We now need to run legoktm's script (once he finishes writing it) and then we can undo this change.

  1. Checked the page in the ticket - https://office.wikimedia.org/wiki/User_talk:Whatamidoing_%28WMF%29/Archive_1 - no issues with displaying it.
  1. Checked on http://ca.wikipedia.beta.wmflabs.org/wiki/Especial:Registre/delete where one old and one new deleted pages were listed: Restoring the old page KartikMistry/Helsinki (non-Flow page).
MariaDB [cawiki]> select ar_title, ar_timestamp, ar_content_model from archive where  ar_title='Flow' or ar_title='KartikMistry/Helsinki';
+-----------------------+----------------+------------------+
| ar_title              | ar_timestamp   | ar_content_model |
+-----------------------+----------------+------------------+
| KartikMistry/Helsinki | 20140718092720 | NULL             |
+-----------------------+----------------+------------------+

After restoring, the page is correctly displayed and page_content_model ='wikitext'

MariaDB [cawiki]> select page_id, page_namespace, page_title, page_content_model  from page where page_title='Flow' or page_title='KartikMistry/Helsinki'\g
+---------+----------------+-----------------------+--------------------+
| page_id | page_namespace | page_title            | page_content_model |
+---------+----------------+-----------------------+--------------------+
|   23622 |              2 | KartikMistry/Helsinki | wikitext           |
+---------+----------------+-----------------------+--------------------+
DannyH closed this task as Resolved.Jul 2 2015, 4:37 PM
DannyH added a subscriber: DannyH.