Skip to content

Document the contract versioning rule (increase on any change of result) - #97

Merged
PierreRaybaut merged 1 commit into
developfrom
docs/contract-versioning-rule
Oct 25, 2026
Merged

PierreRaybaut merged 1 commit into
developfrom
docs/contract-versioning-rule

Conversation

@PierreRaybaut

Copy link
Copy Markdown
Contributor

Closes #96 (corrects the principle written by #95).

  • Guidelines (Operation contracts): version increased whenever a change of a computation function changes its result, whatever the releases of applications; exceptions: previously refused inputs now accepted, no effect on the result, change covered by a versioned rule of the execution context (inputs previously accepted and now refused do require an increase); checklist for changing a computation function; historical one-off exception of 1.4.
  • User guide: new page Operation contracts and versions (what a version guarantees, when it is increased, rules of the execution context, consequences for replay, 1.4 note).
  • Release notes 1.4: contracts keep version 1 in this release only.
  • Agent instructions (.github/copilot-instructions.md): new Operation Contracts section, example with \operation_id/\contract_version/\qualification, qualification report step, Modifying an Existing Computation Function checklist, key files, release classification note.
  • Docstrings: \sigima.proc.contracts, \computation_function(contract_version=...).
  • French translations (all new entries translated). HTML builds (en, fr): no new warning.

…ntly of applications

The guidelines stated that contract versions are not increased until a
stable application records contracts (DataLab 1.4). This tied the
versioning of Sigima to the releases of an application, while Sigima is a
reference of its own.

The rule is now: the version of a contract is increased whenever a change
of a computation function changes the result it returns, in the change
itself, whatever the releases of the applications using Sigima. It is not
increased when previously refused inputs are now accepted, when the change
has no effect on the result, or when the change is entirely covered by a
versioned rule of the execution context (whose version is increased
instead); inputs previously accepted and now refused require an increase.
Keeping version 1 from 1.3.0 to 1.4.0 is recorded as a one-off exception
(contracts just published, not used yet) that does not apply to later
changes.

The rule, with a checklist, is documented in the contributing guidelines, in
a new user guide page "Operation contracts and versions", in a 1.4 release
note, in the instructions for AI agents (contracts section, corrected
example, checklist for modifying a computation function) and in the
docstrings of sigima.proc.contracts and computation_function, with French
translations.

Closes #96

Assisted-by: Claude Opus 5.5
@PierreRaybaut
PierreRaybaut merged commit d6e60b9 into develop Oct 25, 2026
6 checks passed
@PierreRaybaut
PierreRaybaut deleted the docs/contract-versioning-rule branch October 25, 2026 09:37
@ThomasMalletCodra ThomasMalletCodra added this to the v1.4.0 milestone Oct 27, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants