Create a protocol backward-compatibility checking tool
Closed, ResolvedPublic

Description

It would be useful to have a tool, that would do all the mechanical checks of protocol backward-compatibility when XML files get updated. One possible way to implement it would be as follows:

Add a new output mode to wayland-scanner, that produces distilled details of protocol ABI on the wire, including things like opcodes for messages, argument signatures, and 'since' versioning. You would generate this output for the XML before and after a change, and then use a new tool to verify all the changes are backward-compatible.

Or, maybe the tool could process XML directly, but that probably duplicates things from wayland-scanner. It is uncertain which approach is better in the end, or should it perhaps be even built into wayland-scanner itself.

Examples of things that break backward-compatibility:

  • changing opcodes (changing the order in which requests and events are listed)
  • changing interface, request and event names
  • adding, removing or changing arguments to existing messages
  • changing enum values
  • removing enum names/values
  • removing interfaces, requests or events
  • ...

This tool could also verify, that interface versions get bumped properly, and that correct 'since' attributes are used.

Obviously this tool cannot check for semantical changes, and we want to allow improving documentation without being flagged as a break, so it would need to completely ignore all documentation elements.

While writing this tooling and making it detect each of the listed error types, also write tests that provoke those particular errors, so we are certain it will keep on working in the future.

pq created this task.Oct 12 2015, 9:52 AM
pq updated the task description. (Show Details)
pq raised the priority of this task from to Enhancement.
pq added a project: Wayland.
pq added subscribers: pq, daniels.
pq updated the task description. (Show Details)Oct 12 2015, 10:06 AM

GitLab Migration Automatic Message

This bug has been migrated to freedesktop.org's GitLab instance and has been closed from further activity.

You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.freedesktop.org/wayland/wayland/issues/5.

daniels closed this task as Closed.Jun 5 2018, 7:15 PM
daniels claimed this task.