From ab287bcac21ccf83058a6d8915abee43ed45eca8 Mon Sep 17 00:00:00 2001 From: Michael Lieberman Date: Wed, 26 Aug 2026 10:19:24 -0400 Subject: [PATCH] chore(context): reconcile .project/ reader with CNCF upstream (1.3.0 -> 1.4.0) Upstream added a `Managed *bool` field to the `Team` struct in `utilities/dot-project/types.go` (nil defaults to managed; false excludes the team from CNCF resource automation). Darnit does not consume this attribute today, so the reader picks it up via the existing unknown-field catch-all in `_parse_maintainer_teams` into `MaintainerTeam._extra["managed"]` (NEW-IGNORED classification per feature 030 Q1: parse-only scope). No new dataclass, no new parsing helper, no new attribute on `MaintainerTeam`. Just the version + reconciliation-history bump plus the tracked-hash refresh so `test_upstream_spec_unchanged` stops firing on every open PR. Also updates the pinned version-check test to the new value; the test name previously referenced the specific 1.3.0 milestone. Closes #397. Reconcile SHA: cncf/automation@e9adbac (was cncf/automation@afa3d17 via bd7fec94). --- .github/dot-project-spec-hash.txt | 2 +- .../darnit/src/darnit/context/dot_project.py | 17 ++++++++++++++++- tests/darnit/context/test_dot_project.py | 6 +++--- 3 files changed, 20 insertions(+), 5 deletions(-) diff --git a/.github/dot-project-spec-hash.txt b/.github/dot-project-spec-hash.txt index 03d8f16..3c43ccd 100644 --- a/.github/dot-project-spec-hash.txt +++ b/.github/dot-project-spec-hash.txt @@ -1 +1 @@ -afa3d17914ab7eac38b92d9db64338c3530848411f29c7589a26ba5fb9c625d9 +e9adbac38ab1d4d54fa2cb109a664f412653d112e70c6ec68c5793b75dc6bbd8 diff --git a/packages/darnit/src/darnit/context/dot_project.py b/packages/darnit/src/darnit/context/dot_project.py index f1f0ee6..ccf9ad0 100644 --- a/packages/darnit/src/darnit/context/dot_project.py +++ b/packages/darnit/src/darnit/context/dot_project.py @@ -41,6 +41,13 @@ unknown-field catch-all into `ProjectConfig._extra["slack_channels"]`. Not projected onto any `ProjectConfig` attribute (feature 030 Q1: parse-only scope). +- 1.3.0 -> 1.4.0 (issue #397, 2026-08-26): + * `maintainers.yaml` `teams[*].managed`: new upstream `Team.Managed + *bool` (nil defaults to managed; false excludes from CNCF resource + automation). Darnit does not consume this attribute today; parsed + via the existing unknown-field catch-all in + `_parse_maintainer_teams` into `MaintainerTeam._extra["managed"]` + (NEW-IGNORED). No new attribute on `MaintainerTeam`. """ from __future__ import annotations @@ -55,7 +62,7 @@ # Targeted .project/ spec version. Bumped 1:1 with the tracked-hash file # in `.github/dot-project-spec-hash.txt` per feature 030 Q3. -DOT_PROJECT_SPEC_VERSION = "1.3.0" +DOT_PROJECT_SPEC_VERSION = "1.4.0" DOT_PROJECT_SPEC_URL = "https://github.com/cncf/automation/tree/main/utilities/dot-project" # Reconciliation history @@ -74,6 +81,14 @@ # in a future reconcile once a control needs it. # * `cncf_slack_channel` deprecation alias retained (removal is # tracked for a later reconcile, not yet scheduled). +# - 1.3.0 -> 1.4.0 (issue #397, 2026-08-26): +# * maintainers.yaml `teams[*].managed`: new upstream `Team.Managed +# *bool` field. Nil means managed; false excludes from CNCF +# resource automation. Darnit does not consume this today, so +# it is parsed by `_parse_maintainer_teams`'s existing unknown- +# field catch-all into `MaintainerTeam._extra["managed"]` +# (NEW-IGNORED). Adds no attribute to `MaintainerTeam`. +# * `cncf_slack_channel` deprecation alias retained. @dataclass diff --git a/tests/darnit/context/test_dot_project.py b/tests/darnit/context/test_dot_project.py index 822613a..f4f6399 100644 --- a/tests/darnit/context/test_dot_project.py +++ b/tests/darnit/context/test_dot_project.py @@ -1975,8 +1975,8 @@ def test_empty_repositories_list_stays_empty(self, temp_dir: Path): assert "repositories" in missing @pytest.mark.unit - def test_spec_version_bumped_to_1_3_0(self): - """DOT_PROJECT_SPEC_VERSION MUST be 1.3.0 after the RepositoryEntry reconcile.""" + def test_spec_version_bumped_to_1_4_0(self): + """DOT_PROJECT_SPEC_VERSION MUST be 1.4.0 after the Team.Managed reconcile (issue #397).""" from darnit.context.dot_project import DOT_PROJECT_SPEC_VERSION - assert DOT_PROJECT_SPEC_VERSION == "1.3.0" + assert DOT_PROJECT_SPEC_VERSION == "1.4.0"