Page MenuHomePhabricator

Migrate graphs from Vega 1 to Vega 2 syntax on edit with VE
Open, LowestPublic8 Story Points

Description

Since ext.graph now supports Vega 2, the VisualEditor module should exclusively produce Vega 2 graphs ASAP. Existing Vega 1 graphs should be able to be converted to Vega 2 syntax seamlessly upon an edit.

Event Timeline

ferdbold raised the priority of this task from to Needs Triage.
ferdbold updated the task description. (Show Details)
ferdbold added projects: Graphs, VisualEditor.
ferdbold moved this task to VisualEditor on the Graphs board.
ferdbold added a subscriber: ferdbold.
Restricted Application added subscribers: StudiesWorld, Aklapper. · View Herald TranscriptDec 3 2015, 11:28 PM

Existing Vega 1 graphs should be able to be converted to Vega 2 syntax seamlessly upon an edit.

So anyone editing a page will cause unrelated syntax to be updated? We specifically *don't* want VE doing that.

@Krenair I was talking about a graph edit specifically. If the user opens the graph dialog of a graph made with Vega 1, the tool should automagically convert it to Vega 2.

Of course that's an ideal scenario, and I'll have to investigate on whether this is possible without too much pain

@Krenair I was talking about a graph edit specifically. If the user opens the graph dialog of a graph made with Vega 1, the tool should automagically convert it to Vega 2.
Of course that's an ideal scenario, and I'll have to investigate on whether this is possible without too much pain

It's pretty much a drop-dead requirement.

Jdforrester-WMF renamed this task from Migrate ext.graph.VisualEditor to Vega 2 to Migrate graphs from Vega 1 to Vega 2 syntax on edit with VE.Dec 4 2015, 9:36 PM
Jdforrester-WMF set Security to None.
Jdforrester-WMF triaged this task as Low priority.Dec 8 2015, 7:42 PM
Jdforrester-WMF edited a custom field.
Jdforrester-WMF moved this task from To Triage to Blocked on the VisualEditor board.
Yurik added a subscriber: Yurik.EditedDec 18 2015, 10:03 PM

For the current, non-aggregated graphs, the migration is very simple -- place "version":2 at the top, and remove all data. from the fields.

For the future capabilities, if you use facets and other fun features, you will need to use the Vega2 ones, as described in https://github.com/vega/vega/wiki/Upgrading-to-2.0 , or better yet, just read the new transformation docs.

AlexMonk-WMF edited subscribers, added: AlexMonk-WMF; removed: Krenair.Feb 23 2016, 3:35 AM
Deskana lowered the priority of this task from Low to Lowest.Aug 16 2018, 3:07 PM
Deskana moved this task from Blocked to Freezer on the VisualEditor board.