Page MenuHomePhabricator

Internal nodes should eventually be in a separate document ("sub-documents")
Open, HighPublic160 Estimated Story Points

Details

Reference
bz47344

Related Objects

StatusSubtypeAssignedTask
OpenNone
OpenNone
OpenNone
OpenNone
OpenNone
OpenNone
Resolvedssastry
OpenFeatureNone
OpenFeatureNone
ResolvedNone
ResolvedFeature ppelberg
OpenFeatureNone
OpenNone
OpenNone
OpenReleaseNone
DuplicateNone
OpenNone
OpenNone
OpenNone
OpenFeatureNone
DeclinedNone
OpenNone
ResolvedEsanders
OpenFeatureNone
ResolvedNone
OpenNone
OpenNone
OpenNone
OpenNone
OpenBUG REPORTNone
OpenNone

Event Timeline

bzimport raised the priority of this task from to High.Nov 22 2014, 1:15 AM
bzimport added a project: Technical-Debt.
bzimport set Reference to bz47344.

This is the notorious "sub-documents" concept.

Jdforrester-WMF renamed this task from VisualEditor: Internal nodes should eventually be in a separate document ("sub-documents") to Internal nodes should eventually be in a separate document ("sub-documents").Dec 3 2014, 12:32 AM
Jdforrester-WMF set Security to None.
Jdforrester-WMF lowered the priority of this task from High to Medium.Jan 15 2015, 12:19 AM

Change 179940 had a related patch set uploaded (by Jforrester):
[VERY VERY WIP] DocumentSet and subdocuments

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

Jdforrester-WMF raised the priority of this task from Medium to High.Nov 19 2015, 7:36 PM
Jdforrester-WMF changed the task status from Open to Stalled.Jun 29 2016, 4:40 PM

Here is a proposal for refinement:

  • Conceptually, an article is a set of documents, of which one is the "main document" and the others are "sub-documents". In code terms there is barely any difference between the main document and sub-documents. Documents do not contain other documents, but can reference them, and the references can form cycles. (Essentially the approach from https://gerrit.wikimedia.org/r/269449/ )
  • Each document has a unique immutable ID (probably a random string) that never gets re-used for another document.
  • In the linear model, documents are appear in creation order (so the main document first), wrapped in an outer 'document' tag:
{ type: 'document', attributes: { id: 'main' } },
...,
{ type: '/document' },
{ type: 'document', attributes: { id: 'xXvWksy' } },
...,
{ type: '/document' },
...
  • In the linear model, references into another document contain that document's ID:
{ type: 'mwReference', attributes: { ..., docId: 'xXvWksy', ... } },
{ type: '/mwReference' }
  • In memory, each document can be represented as a separate ve.dm.Document and node tree.
  • The ve.ce.Document tree for the main document is rendered into a DOM tree using information from the other documents as necessary. The same goes for rendering any sub document as required (e.g. when editing a reference).
  • There is *no* special infrastructure in ve.dm.Transaction to handle these extensions, and the document history remains a single transaction list. Rebasing valid transactions over valid transactions will preserve validity (which is what the unique immutable ID was for).
Aklapper changed the task status from Stalled to Open.Nov 3 2020, 11:25 AM

The previous comments don't explain who or what (task?) exactly this task is stalled on ("If a report is waiting for further input (e.g. from its reporter or a third party) and can currently not be acted on"). Hence resetting task status, as tasks should not be stalled (and then potentially forgotten) for years for unclear reasons.

(Smallprint, as general orientation for task management:
If you wanted to express that nobody is currently working on this task, then the assignee should be removed and/or priority could be lowered instead.
If work on this task is blocked by another task, then that other task should be added via Edit Related Tasks...Edit Subtasks.
If this task is stalled on an upstream project, then the Upstream tag should be added.
If this task requires info from the task reporter, then there should be instructions which info is needed.
If this task needs retesting, then the TestMe tag should be added.
If this task is out of scope and nobody should ever work on this, or nobody else managed to reproduce the situation described here, then it should have the "Declined" status.
If the task is valid but should not appear on some team's workboard, then the team project tag should be removed while the task has another active project tag.)