Tgr added a comment.

I think there are two separate issues here:

  • Should prepareSave be allowed to check for global consistency? I'd agree that global state requirements do not mix well with the conceptual model of a wiki; implementers should be discouraged from relying on state outside the content object itself. (At a glance, current extensions don't do anything like that, apart from Wikibase.)
  • Should checks happen on import / undelete? I suppose both approaches are justifiable; on one hand, it would be nice to offer a consistency guarantee when content is created (e.g. undeleting something after the code or configuration has been changed in a backwards-incompatble way should trigger an error). On the other hand, when an edit save fails, the problem can be surfaced to the user, who can fix it; but when an undelete or import fails, there usually isn't any feasible way to recover. So it would definitely be good to avoid errors in those cases. (Same goes for a rollback, somewhat, although in that case the user could be asked to do a manual edit instead.) Only checking after edits is maybe the less disruptive option.

(Also prepareSave seems like a misnomer; everything uses it for validation, not preprocessing or such.)


TASK DETAIL
https://phabricator.wikimedia.org/T192777

EMAIL PREFERENCES
https://phabricator.wikimedia.org/settings/panel/emailpreferences/

To: Tgr
Cc: Aklapper, hoo, Anomie, Tgr, Lydia_Pintscher, daniel, Lahi, Gq86, GoranSMilovanovic, QZanden, LawExplorer, Agabi10, Wikidata-bugs, aude, Mbch331
_______________________________________________
Wikidata-bugs mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/wikidata-bugs

Reply via email to