Skip to content

feat(release-trust): package-scoped tags for flow and agent from the OpenAdapt monorepo - #54

Merged
abrichr merged 1 commit into
mainfrom
fix/package-scoped-release-tags
Oct 17, 2026
Merged

abrichr merged 1 commit into
mainfrom
fix/package-scoped-release-tags

Conversation

@abrichr

@abrichr abrichr commented Oct 17, 2026

Copy link
Copy Markdown
Member

Flow 2.2.0 and agent 2.2.1 are the first releases from the OpenAdapt monorepo (packages/flow, packages/agent). Until now the policy bound the flow and agent targets to the standalone repositories, and production_trust.py accepted only refs/tags/v* rulesets, which the launcher already uses in OpenAdapt. So no monorepo release could be admitted.

What changes

  • Package releases from the monorepo are tagged <pypi-project>-v<version>: openadapt-flow-v2.2.0, openadapt-agent-v2.2.1. The launcher keeps v*.
  • In TARGET_CONTRACTS, flow and agent now name OpenAdaptAI/OpenAdapt (627024850), with package_path and an exact tag_prefix.
  • previous_sources keeps every earlier release (flow < 2.2.0, agent < 2.2.1) bound to its standalone repository and plain v<version> tag.
  • The release version alone decides the source (release_source, release_tag, release_source_for_tag). A monorepo release can't claim the old repository or a v* tag, and an earlier release can't claim the monorepo. The retained admissions still validate unchanged.
  • validate_tag_rulesets takes the prefix and requires exactly one include pattern, refs/tags/<prefix>v*, plus that prefix's ruleset names. The prefix is a literal checked against ^(|openadapt-[a-z]+-)$, so the only wildcard is the version part. The bypass actors, rules, enforcement and roles are unchanged.
  • production-lifecycle-policy.json (revision 8) and production-release-authority-policy.json name OpenAdapt for flow and agent. The authority policy entries also carry package_path, tag_pattern and both ruleset names.
  • Schemas accept exactly those patterns and names. The verification receipts pair each source repository with its own tag form (oneOf), so neither pairing can be mixed with the other.
  • check_profile still treats the frozen openadapt-flow and openadapt-agent repositories as product target repositories, because their earlier releases stay bound to them.
  • openadapt-types is not a Production target, so it has no target to rebind.

Rulesets needed on OpenAdapt (created separately; the existing v* rulesets are untouched):

  • OpenAdapt policy: openadapt-flow release tag creation and OpenAdapt policy: immutable openadapt-flow release tags on refs/tags/openadapt-flow-v*
  • OpenAdapt policy: openadapt-agent release tag creation and OpenAdapt policy: immutable openadapt-agent release tags on refs/tags/openadapt-agent-v*

Validation run locally

  • unittest: 428 tests OK; that includes the new tests/test_package_scoped_release_tags.py (boundaries, refusals, and a flow 2.2.0 admission issued end to end and checked against the schema).
  • validate_evidence_registry, validate_production_lifecycle (7 active admissions; history-only against main also passes), check_profile, and check_benchmark_claims all pass.

…OpenAdapt monorepo

Flow from 2.2.0 and agent from 2.2.1 release from OpenAdaptAI/OpenAdapt
(packages/flow, packages/agent) under openadapt-flow-v<version> and
openadapt-agent-v<version> tags; the launcher keeps v*.

production_trust binds each target to a tag prefix and the matching
ruleset names, and checks each tag ruleset against that one exact
include pattern (refs/tags/<prefix>v*). The release version alone picks
the source: every earlier release stays bound to its standalone
repository and v<version> tag (previous_sources), so the retained
admissions still validate and neither side can claim the other's
releases. The lifecycle policy (revision 8) and the release authority
policy name OpenAdapt for both targets; the schemas accept exactly those
patterns and names and pair each source repository with its tag form.
@abrichr
abrichr merged commit 9aaa623 into main Oct 17, 2026
5 checks passed
@abrichr
abrichr deleted the fix/package-scoped-release-tags branch October 17, 2026 23:38
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.

1 participant