Add the rewrite record to the repository protocols [IFC-3284]

Merged
GM
14d ago
+24-0

What

Regenerated infrahub_sdk/protocols.py so CoreGenericRepository, CoreRepository, CoreReadOnlyRepository and their Sync counterparts declare four new attributes:

  • last_rewrite_previous_commit: StringOptional
  • last_rewrite_commit: StringOptional
  • last_rewrite_at: DateTimeOptional
  • rewrite_count: IntegerOptional

This goes with https://github.com/opsmill/infrahub/pull/10904, and this PR merges first.

Why

The Infrahub core schema now declares these attributes on the CoreGenericRepository generic. They record the last rewrite of the remote history of a branch. protocols.py is generated from those definitions by invoke backend.generate in the Infrahub repository, so this file moves with them. Both concrete kinds inherit the attributes and override none of them.

Notes

  • Generated output only, with no hand-written change. As with #1272, there is no changelog fragment for a protocols regeneration.
  • The Infrahub PR needs this commit: its invoke backend.validate-generated runs git -C python_sdk diff --exit-code infrahub_sdk/protocols.py.

Summary by cubic

Regenerates infrahub_sdk/protocols.py so CoreGenericRepository, CoreRepository, CoreReadOnlyRepository, and their Sync counterparts declare the four optional attributes that record the last rewrite of a branch's remote history (IFC-3284).

Notes

  • Generated output only; merge this before the Infrahub PR that validates infrahub_sdk/protocols.py.