Skip to content

fix(org): declare team maintainers and drop deprecated team_id - #65

Merged
robinbowes merged 1 commit into
mainfrom
fix/team-member-roles
Aug 13, 2026
Merged

fix(org): declare team maintainers and drop deprecated team_id#65
robinbowes merged 1 commit into
mainfrom
fix/team-member-roles

Conversation

@robinbowes

Copy link
Copy Markdown
Contributor

Two problems that PR #64's apply exposed, both in github_team_members. Neither
changes any infrastructure — task plan reports No changes. on this branch,
scoped and unscoped. The config is being corrected to match what already exists.

Team roles. GitHub makes whoever creates a team its maintainer. #64 declared
a flat members list, so the provider default member became a standing
instruction to demote robinbowes from maintainer. _teams.yaml now takes a
maintainers list alongside members, rendered as two dynamic "members"
blocks. A team with no maintainers writes exactly what it wrote before.

This reverses the "flat member list, no roles" decision in the migration design.
That decision's premise — "roles would add configuration surface for no
behaviour" — was falsified by the apply: omitting the role has a behaviour.
Recorded in decisions/2026-08-13-team-member-roles.md.

Deprecated team_id. The provider deprecated it in favour of team_slug
and will make it computed-only in a future release, which version = "~> 6.0"
permits. Switching to team_slug = github_team.this[each.key].slug keeps the
dependency edge that orders team creation before any repo grant — the edge comes
from referencing github_team at all, not from which attribute is read.

Username case. github_team_members lowercases usernames into state and
compares case-sensitively, so PlanetSeth under a team was a third standing
diff. Team usernames are now lowercase. This is specific to team membership;
collaborators.users in a repo file carries GitHub's display case and has never
drifted.

🤖 Generated with Claude Code

https://claude.ai/code/session_01C15usdmazQC71xZC1YFGHg

@yo61-lastlight yo61-lastlight Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Adds a maintainers list alongside members in _teams.yaml (rendered as two dynamic "members" blocks with explicit roles), switches github_team_members from the deprecated team_id to team_slug, and lowercases the one existing team username. Checked the dependency-edge claim (still holds — team_slug still references github_team.this, so team creation still orders before membership), the coalesce(lookup(...), []) null-guard against an explicitly empty YAML key, and the decision doc, which already calls out and accepts the one open edge case (a username listed under both maintainers and members produces two blocks, unvalidated). No infrastructure-shape change, and the PR states task plan is a no-op. Nothing else in the diff raises a Critical or Important concern.

@robinbowes
robinbowes merged commit 8cb5e2b into main Aug 13, 2026
2 checks passed
@robinbowes
robinbowes deleted the fix/team-member-roles branch August 13, 2026 10:57
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