Page MenuHomePhabricator

[Spike] How to deal with WB replacing their JS data model?
Closed, DeclinedPublic

Description

Apparently, wikibase are replacing their JS data model, and we're using it in wikibase.mediainfo.statements (introduced in https://gerrit.wikimedia.org/r/c/mediawiki/extensions/WikibaseMediaInfo/+/491288)
Should we localise our own version of the WB datamodel?
Should we try to keep up-to-date with upstream changes?
Just use plain JS literals that represent valid API output?
Something else?

Let's figure out exactly what's changing (@Jdforrester-WMF may know more?) and come up with a plan.

Event Timeline

matthiasmullie created this task.
Addshore added a subscriber: Addshore.

I guess this ticket comes due to the other tickets discussing SSR and VueJS?

Apparently, wikibase are replacing their JS data model, and we're using it in wikibase.mediainfo.statements (introduced in https://gerrit.wikimedia.org/r/c/mediawiki/extensions/WikibaseMediaInfo/+/491288)

Not sure where exactly that was said?

Should we localise our own version of the WB datamodel?

Perhaps, if you end up being the only user / last user, but I doubt it will come to that (at least any time soon)

Should we try to keep up-to-date with upstream changes?

Probably, as we won't be removing this and likely not changing it any time soon.

Right now there is no plan to get rid of any of this any time soon, and if people are actively using it, it will not go anywhere.
One day the whole UI might be written in vue, but right now the termbox is the only thing on the roadmap, there will be plenty of time before anything else changes or anything disappear entirely.
Even if we wanted to make removing all of this code a priority, it would be unlikely that we would get there for quite some time / years.

Yeah, I think we should adopt a proper local data model rather than using Wikidata's, but (a) I don't think there's a rush, per Adam, and (b) definitely this doesn't block T204264 unless I'm missing something big?

Ok. Would it be correct to say that adopting our own local data model is a discrete project, and should be ticketed as such?

Ok. Would it be correct to say that adopting our own local data model is a discrete project, and should be ticketed as such?

Yeah, it's probably something we should formally decide to put on the backlog before creating though. It's quite an epic.

Not worth pursuing ATM. Let’s figure this out and reconsider options if/when this becomes an actual issue in the future.