guardian / media-atom-maker

A tool for creating media atoms, including a UI specifically for managing video
https://video.gutools.co.uk/videos
4 stars 3 forks source link

Use revision numbers, not content comparisons, for change detection #1131

Closed jonathonherbert closed 1 year ago

jonathonherbert commented 1 year ago

NB: depends on #1130.

What does this change?

Uses revision numbers, not a deep compare of content, to detect whether it's possible to save and launch a piece.

The current behaviour is arguably better for users when it works, because 'save and launch' is not available when there's nothing new to publish.

However, it has some disadvantages:

It's worth noting that other tools, like Composer, use a revision number, not a deep compare, to determine whether a piece can be republished.

Rather than re-implement deep compare in Composer, it's arguably better to go for a less potentially buggy and more consistent approach for now. This doesn't rule out reimplementing deep compare in future across both tools in some more robust way.

How to test

Has unpublished changes ('save and launch' available in MAM) No changes ('published' in MAM)
Screenshot 2023-08-18 at 12 45 11 Screenshot 2023-08-18 at 12 44 52
prout-bot commented 1 year ago

Seen on PROD (created by @jonathonherbert and merged by @Georges-GNM 7 minutes and 40 seconds ago) Please check your changes!