diff --git a/.github/DISCUSSION_TEMPLATE/vouch-request.yml b/.github/DISCUSSION_TEMPLATE/vouch-request.yml index 4f2b0f0a01..13d841d109 100644 --- a/.github/DISCUSSION_TEMPLATE/vouch-request.yml +++ b/.github/DISCUSSION_TEMPLATE/vouch-request.yml @@ -7,8 +7,8 @@ body: ## Vouch Request Fullsend uses a vouch system for first-time contributors. Fill out this - form to request approval. A maintainer will review and comment `/vouch` - if approved. + form to request approval. A writer or a maintainer will review and + comment `/vouch` if approved. **Write in your own words.** Do not have an AI generate this request. Requests that read like LLM output will be denied. diff --git a/.github/ISSUE_TEMPLATE/config.yml b/.github/ISSUE_TEMPLATE/config.yml index 78c6a3bddd..3ac24d9000 100644 --- a/.github/ISSUE_TEMPLATE/config.yml +++ b/.github/ISSUE_TEMPLATE/config.yml @@ -5,4 +5,4 @@ contact_links: about: > First-time contributors must be vouched before submitting PRs. Open a Vouch Request discussion describing what you want to work on. A - maintainer will approve you with /vouch. + writer or a maintainer will approve you with /vouch. diff --git a/CODEOWNERS b/CODEOWNERS index b1c9faea7e..6f9a8e26af 100644 --- a/CODEOWNERS +++ b/CODEOWNERS @@ -1,12 +1,32 @@ -# These users have approval access to all resources (wildcard) -* @fullsend-ai/maintainers +# Maintainers and writers have approval access to all resources +# (wildcard). See LADDER.md for the roles. +* @fullsend-ai/maintainers @fullsend-ai/fullsend-writers # Submodule paths — no code-owner review required so Renovate # digest bumps can auto-merge after CI passes. # GitHub CODEOWNERS uses last-match-wins, so these blank-owner -# entries after the wildcard override @fullsend-ai/maintainers for +# entries after the wildcard override the wildcard owners for # these paths only. Entries are root-anchored so the exemption # cannot leak to same-named paths at other depths. -# .gitmodules is deliberately excluded: it maps submodule fetch -# URLs, so URL swaps must keep @fullsend-ai/maintainers review (#6082). /experiments + +# Files reserved for maintainers. These set out the roles, the code +# owners and the architecture decisions, so a writer's approval does not +# count on them (LADDER.md, "Files reserved for maintainers"). They come +# after the wildcard because the last matching entry wins. +# .gitmodules maps submodule fetch URLs, so URL swaps must keep +# @fullsend-ai/maintainers review (#6082). +# +# GitHub reads CODEOWNERS from .github/, the root, then docs/, and uses +# only the first file it finds. All three locations are reserved, so a +# new file in a location that is read first needs a maintainer's +# approval too. The test that guards these entries is reserved for the +# same reason. +/CODEOWNERS @fullsend-ai/maintainers +/.github/CODEOWNERS @fullsend-ai/maintainers +/docs/CODEOWNERS @fullsend-ai/maintainers +/internal/owners/codeowners_repo_test.go @fullsend-ai/maintainers +/LADDER.md @fullsend-ai/maintainers +/MAINTAINERS.md @fullsend-ai/maintainers +/.gitmodules @fullsend-ai/maintainers +/docs/ADRs/ @fullsend-ai/maintainers diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 8a94191135..6a909f1056 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -4,12 +4,12 @@ Thank you for your interest in contributing! This document covers the social nor ## First-Time Contributors -This project uses a **vouch system**. AI tools make it trivial to generate plausible-looking but low-quality contributions, so we require first-time contributors to be vouched by a maintainer before submitting pull requests. +This project uses a **vouch system**. AI tools make it trivial to generate plausible-looking but low-quality contributions, so we require first-time contributors to be vouched by a writer or a maintainer before submitting pull requests. 1. Open a [Vouch Request](https://github.com/fullsend-ai/fullsend/discussions/new?category=vouch-request) discussion. 2. Describe what you want to change and why. 3. Write in your own words — do not have an AI generate the request. Requests that read like LLM output will be denied. -4. A maintainer will comment `/vouch` if approved. +4. A writer or a maintainer will comment `/vouch` if approved. 5. Once vouched, you can submit pull requests. **If you are not vouched, any pull request you open will be automatically closed.** Org members and collaborators with write access bypass this check. @@ -61,14 +61,19 @@ contribution. ### Review etiquette -- **The approving maintainer merges the pull request** after requested reviewers - have responded and the PR has all required approvals. ADRs require two - maintainer approvals; see [Working with ADRs](#working-with-adrs). - - If another maintainer authored or drove the change, that maintainer merges - it after a different maintainer approves. For an agent-authored PR, treat - the maintainer who triggered or drove the work as its originator. - - The approving maintainer merges code-agent-authored PRs and PRs from - contributors with Write access, unless another maintainer drove the change. +- **The person driving a pull request gets it merged**, once requested + reviewers have responded, review threads are resolved and the PR has all + required approvals. ADRs require two maintainer approvals; see + [Working with ADRs](#working-with-adrs). + - If you can merge (you hold the Write or Maintainer role), add the PR to + the merge queue yourself. It still needs an approval from someone else + first. + - If you cannot merge, ask the person who approved it to merge it. If you do + not know who to ask, mention `@fullsend-ai/maintainers` on the pull + request. + - For an agent-authored PR, the person who triggered or steered the agent is + driving it. An agent-authored PR that nobody is driving is merged by its + approver. - **The PR author resolves review comments.** The author can address feedback and resolve the conversation themselves. - **If you need to block a PR on your feedback, use "Request changes."** A @@ -217,12 +222,14 @@ The [`filing-issues`](skills/filing-issues/SKILL.md) skill encodes this split fo ## Contributor ladder -This project defines five contributor roles — Vouched, Triage, Write, -Maintainer, and Admin — each granting additional capabilities. See -[LADDER.md](LADDER.md) for the full ladder and how to request each role. +This project defines five contributor roles. Vouched, Triage, Write, +and Maintainer form a ladder, and each one grants additional +capabilities. Admin is a separate role for administrative work. See +[LADDER.md](LADDER.md) for the criteria for every role and how to +request each one. -For the Maintainer role specifically, see -[MAINTAINERS.md](MAINTAINERS.md). +[MAINTAINERS.md](MAINTAINERS.md) describes what maintainers do and the +time commitment. ## License diff --git a/LADDER.md b/LADDER.md index e50231dfb0..b7eb34c180 100644 --- a/LADDER.md +++ b/LADDER.md @@ -1,9 +1,12 @@ # Contributor Ladder -This document defines the path from first-time contributor to admin. -Each role grants additional capabilities and carries additional -expectations. Advancement is not automatic — it requires a request, a -track record, and maintainer approval. +This document defines the contributor roles in the fullsend-ai +organization and how to request each one. Vouched, Triage, Write, and +Maintainer form a ladder. Each role grants additional capabilities and +carries additional expectations. Admin is a separate role that sits +beside the ladder (see [Admin](#admin)). No role is granted +automatically. Each one requires a request, a track record, and +approval. The ladder is organization-wide. Merged PRs and substantive reviews in any public repository under the @@ -16,9 +19,9 @@ discussion, admits you to every fullsend-ai repository that runs the vouch gate. See [CONTRIBUTING.md](CONTRIBUTING.md) for the request process. -For the Maintainer role specifically — including eligibility, the -nomination process, and what maintainers do — see -[MAINTAINERS.md](MAINTAINERS.md). +This document holds the criteria and the request process for every +role. [MAINTAINERS.md](MAINTAINERS.md) describes what maintainers do, +the time commitment, and how inactive maintainers are removed. **A good place to start is reviewing existing pull requests.** Reviewing teaches you the codebase, the project's direction, and its conventions, @@ -52,12 +55,12 @@ on the `vouched` branch. **How to request:** Open a [Vouch Request](https://github.com/fullsend-ai/fullsend/discussions/new?category=vouch-request) -discussion. A maintainer will review and comment `/vouch` if approved. -The `vouch-command` workflow then adds you to +discussion. A writer or a maintainer will review and comment `/vouch` +if approved. The `vouch-command` workflow then adds you to [`VOUCHED.td`](https://github.com/fullsend-ai/fullsend/blob/vouched/.github/VOUCHED.td) and closes the request discussion automatically. -**Who approves:** Any single maintainer. +**Who approves:** Any single writer or maintainer. ### Triage @@ -91,15 +94,16 @@ repository. - Responsive to feedback on your contributions — on changes you drove and in review discussions you took part in -**How to check:** Your GitHub username is listed under `triagers` -in the `teams:` section of +**How to check:** Your GitHub username is listed under `triagers` or +`fullsend-triagers` (a new grant adds you to both) in the `teams:` +section of [peribolos.yaml](https://github.com/fullsend-ai/org/blob/main/peribolos.yaml) in the [fullsend-ai/org](https://github.com/fullsend-ai/org) repository. **How to request:** Open a [Triage Request](https://github.com/fullsend-ai/org/issues/new?template=triage-request.yml) -issue in [fullsend-ai/org](https://github.com/fullsend-ai/org). A maintainer -approves by adding your username to the `triagers` team in `peribolos.yaml`. +issue in [fullsend-ai/org](https://github.com/fullsend-ai/org). See +[Requesting a role](#requesting-a-role) for what happens next. You do not need to be an expert in the codebase or community conventions to request Triage. If you think your contributions demonstrate @@ -111,10 +115,18 @@ assess the evidence and explain any additional experience needed. ### Write **What it means:** You have GitHub `write` collaborator access on the -repository. +repository. You can do everything needed to land a change, including +approving and merging other people's pull requests. This document calls +people with the Write role writers. **What it unlocks:** +- Approving pull requests. Your approval counts as the code owner + approval that a merge requires, except on the + [files reserved for maintainers](#files-reserved-for-maintainers). + You do not approve [changes you drove](#changes-you-drove). +- Merging approved pull requests +- Vouching for new contributors by commenting `/vouch` - `/fs-code` and `/fs-fix` slash commands (mutation agents) - `/fs-retro` and `/fs-prioritize` slash commands (analysis agents that require write-level trust) @@ -134,45 +146,78 @@ repository. **Criteria:** - Already at the Triage role -- Sustained contribution history: multiple merged PRs across different - areas of the codebase, or - [deep expertise in a specific subsystem](#subsystem-expertise) +- A contribution history that meets one of the two paths below. A + contribution is a merged change you authored or + [drove](#agent-authored-prs-and-assignment), or a + [substantive review](#substantive-reviews). + - **Breadth:** at least 12 contributions across at least 3 + [subsystems](#subsystems), with at least 2 in each of those three. + - **Depth:** [deep expertise in one subsystem](#subsystem-expertise), + plus at least 4 contributions outside it. Those contributions cover + at least 2 other subsystems, with at least 2 in each. +- On either path, at least 4 of your contributions are substantive + reviews of changes you did not drive. Writers approve other people's + work, so your request must show how you review. - Demonstrated understanding of project conventions (commit messages, PR workflow, review etiquette) - Trusted not to push directly to protected branches or bypass review -**How to check:** Your GitHub username is listed under `writers` -in the `teams:` section of +**How to check:** Your GitHub username is listed under both `writers` +and `fullsend-writers` in the `teams:` section of [peribolos.yaml](https://github.com/fullsend-ai/org/blob/main/peribolos.yaml) in the [fullsend-ai/org](https://github.com/fullsend-ai/org) repository. **How to request:** Open a [Write Request](https://github.com/fullsend-ai/org/issues/new?template=write-request.yml) -issue in [fullsend-ai/org](https://github.com/fullsend-ai/org). Two maintainers -must approve by commenting on that issue; only after both approvals should -a `peribolos.yaml` PR be opened. The maintainer opening the PR links the -approved issue in the PR description, and adds your username to the `writers` -team in `peribolos.yaml`. +issue in [fullsend-ai/org](https://github.com/fullsend-ai/org). See +[Requesting a role](#requesting-a-role) for what happens next. -**Who approves:** Two maintainers must approve on the request issue before -the `peribolos.yaml` PR is opened. A single maintainer -can request more discussion but cannot unilaterally grant write access. +**Who approves:** Two maintainers, after the request has been open for +at least 48 hours. A maintainer's objection blocks the request unless a +majority of the maintainers approve it. See +[Objections](#objections). ### Maintainer -**What it means:** You have merge and approval rights and are a member -of the [@fullsend-ai/maintainers](https://github.com/orgs/fullsend-ai/teams/maintainers) -team. You are expected to be an active regular participant in the -project and to help review contributions you are not driving. +**What it means:** You are a member of the +[@fullsend-ai/maintainers](https://github.com/orgs/fullsend-ai/teams/maintainers) +team. Maintainers are the stewards of the project as a whole. Together +they decide who holds each role, including who the admins are, and they +approve changes to how the project is governed. See +[MAINTAINERS.md](MAINTAINERS.md) for the full list of responsibilities +and the time commitment. **What it unlocks:** -- CODEOWNERS approval required to merge PRs -- Issue triage and backlog management -- All capabilities from previous roles +- Approving and objecting to role requests for every role above + Vouched +- Approving changes to the + [files reserved for maintainers](#files-reserved-for-maintainers) +- Approving and merging pull requests in + [fullsend-ai/org](https://github.com/fullsend-ai/org), including the + `peribolos.yaml` pull requests that grant or remove roles +- All capabilities of the Write role + +**Criteria:** -**Criteria and process:** See [MAINTAINERS.md](MAINTAINERS.md) for the -full eligibility criteria, nomination process, and time commitment. +- You have held the Write role for at least 2 months +- **Review across the project.** You have given at least 12 + [substantive reviews](#substantive-reviews) since you became a + writer, across at least 3 [subsystems](#subsystems), with at least 2 + in each of those three. They include changes outside the area you + know best. +- **Sound approvals.** Your approvals show that you check whether a + change fits the project's direction and conventions, and not only + whether it works. You have requested changes when a change needed it. +- **Part in the project's direction.** You have taken a substantive + part in at least 1 architecture decision or design discussion: as an + [ADR](docs/ADRs/) author, as an ADR reviewer, or in a problem + document or design thread. +- **Helping others contribute.** You have helped other contributors + land their work. Examples: reviewing newcomers' pull requests, + answering questions, and unblocking stuck reviews. +- **Reliability.** You respond to review requests and mentions in + reasonable time, and you follow things through. **How to check:** Your GitHub username is listed in the `maintainers` team in @@ -180,10 +225,13 @@ team in in the [fullsend-ai/org](https://github.com/fullsend-ai/org) repository. **How to request:** Open a -[Maintainer Nomination](https://github.com/fullsend-ai/org/issues/new?template=maintainer-request.yml) -issue in [fullsend-ai/org](https://github.com/fullsend-ai/org). Existing -maintainers discuss and reach consensus; if approved, your username is -added to the `maintainers` team in `peribolos.yaml`. +[Maintainer Request](https://github.com/fullsend-ai/org/issues/new?template=maintainer-request.yml) +issue in [fullsend-ai/org](https://github.com/fullsend-ai/org). See +[Requesting a role](#requesting-a-role) for what happens next. + +**Who approves:** Three maintainers, after the request has been open +for at least 48 hours. A maintainer's objection blocks the request +until that maintainer withdraws it. See [Objections](#objections). ### Admin @@ -191,31 +239,99 @@ added to the `maintainers` team in `peribolos.yaml`. member of the [@fullsend-ai/admins](https://github.com/orgs/fullsend-ai/teams/admins) team. Admins are typically also owners of the fullsend-ai GitHub -organization. You are expected to perform all of the activities of the -Maintainer role and also to perform repository-level administrative -tasks as needed. +organization. You perform administrative tasks for the project, such as +changing repository and organization settings. + +Admin is a separate role, not a step above Maintainer. Some people hold +both roles and some hold only one. An admin who is not a maintainer +does not approve or object to role requests. **What it unlocks:** - GitHub `admin` access on the fullsend-ai repositories -- Approving and merging the `peribolos.yaml` pull requests in - [fullsend-ai/org](https://github.com/fullsend-ai/org) that grant or - revoke roles (see [Requesting a role](#requesting-a-role) and - [Revoking access](#revoking-access)) -- All capabilities from previous roles - -**Criteria and process:** This role has no formal request process -yet. The project does not anticipate needing to add admins anytime -soon. If and when someone needs this role, the admins will define the -request process, the track record expected, and the approval -threshold, and document them here. Until then, if you believe you need -administrator access, reach out to one or more admins and explain why. +- Approving and merging pull requests in + [fullsend-ai/org](https://github.com/fullsend-ai/org) + +**Criteria:** + +- You hold the Write role or the Maintainer role +- **A stated purpose.** Your request says which administrative tasks + you intend to take on. Admin rights are broad. The project grants + them for a reason, not as recognition. +- **Demonstrated capability.** You have done administrative work that + did not need admin rights, with at least 3 merged changes of this + kind. Examples: changes to the configuration in + [fullsend-ai/org](https://github.com/fullsend-ai/org), CI and + workflow changes, onboarding a repository, and writing or following + operational runbooks. +- **Reliability.** You have followed operational tasks through + promptly, including routine ones. +- **Care with access.** Your work shows sound handling of secrets, + tokens, and permissions. **How to check:** Your GitHub username is listed in the `admins` team in [peribolos.yaml](https://github.com/fullsend-ai/org/blob/main/peribolos.yaml) in the [fullsend-ai/org](https://github.com/fullsend-ai/org) repository. +**How to request:** Open an +[Admin Request](https://github.com/fullsend-ai/org/issues/new?template=admin-request.yml) +issue in [fullsend-ai/org](https://github.com/fullsend-ai/org). See +[Requesting a role](#requesting-a-role) for what happens next. + +**Who approves:** Three maintainers, after the request has been open +for at least 48 hours. A maintainer's objection blocks the request +until that maintainer withdraws it. See [Objections](#objections). +Maintainers decide admin requests, and admins do not, because +maintainers are the stewards of the project as a whole. + +## Approving pull requests + +The Write and Maintainer roles both carry approval rights. Two rules +apply to them. + +### Changes you drove + +The approval that allows a merge comes from someone who did not author +or drive the change. For an agent-authored pull request, the person who +triggered or steered the agent counts as its author. See +[Agent-authored PRs and assignment](#agent-authored-prs-and-assignment) +for what driving a change means. + +GitHub blocks you from approving a pull request that you opened. It +cannot tell who drove a pull request that an agent opened, so this rule +is a project norm that writers and maintainers follow. + +One exception: the `peribolos.yaml` pull requests in +[fullsend-ai/org](https://github.com/fullsend-ai/org) that grant or +remove a role. The independent approvals for those happen on the +request issue or the removal issue, so the maintainer who commented +`/fs-code` may also approve the pull request. + +### Files reserved for maintainers + +A writer's approval allows a merge on every file except a short list: +the files that set out the roles and the code owners, and the +architecture decision records. These need a maintainer's approval: + +- In this repository: `CODEOWNERS` (in each location GitHub reads it + from), the test that guards these entries + (`internal/owners/codeowners_repo_test.go`), `LADDER.md`, + `MAINTAINERS.md`, `.gitmodules` (which sets where submodules are + fetched from), and every file under `docs/ADRs/` +- In [fullsend-ai/org](https://github.com/fullsend-ai/org): every file. + There, an admin's approval also allows a merge. + +An ADR needs approval from two maintainers, as +[Working with ADRs](CONTRIBUTING.md#working-with-adrs) says. GitHub +requires one of them. The second is a project norm, and a writer's +approval does not count toward the two. + +Workflow files under `.github/` and the agent configuration under +`.fullsend/` are not on the list, so a writer's approval allows a merge +on them. They change often, and reserving them would make routine work +wait for a maintainer. + ## Demonstrating readiness Advancement is a human assessment of demonstrated trust and readiness. @@ -269,12 +385,36 @@ Distinguish between driving a change and independently reviewing it: not drive. Your review of a change you drove is not an independent review. +### Subsystems + +The Write and Maintainer criteria count contributions by subsystem. A +subsystem is a part of the system with its own responsibilities and +design, large enough that one person could be its usual reviewer. +Examples: + +- The token mint +- Jira polling +- The sandbox and the runtimes +- The forge integrations (GitHub, GitLab, Forgejo) +- Installation and scaffolding +- Telemetry +- The agent definitions in + [fullsend-ai/agents](https://github.com/fullsend-ai/agents) +- The eval harness in + [fullsend-ai/agent-eval-harness](https://github.com/fullsend-ai/agent-eval-harness) + +This list is not complete, and the project keeps no fixed list. A +separate repository usually counts as its own subsystem. In your +request, name the subsystems your contributions belong to. Maintainers +judge whether the subsystems you name are distinct. + ### Subsystem expertise -Deep expertise in a specific subsystem means understanding its +Deep expertise in a specific subsystem means that you understand its responsibilities, design, interactions with other parts of the system, -tradeoffs, and security boundaries — well enough to evaluate changes to -it and explain why it works the way it does. Evidence can include: +tradeoffs, and security boundaries. You understand them well enough to +evaluate changes to the subsystem and to explain why it works the way +it does. Evidence can include: - Substantive reviews of changes to that subsystem - Design discussions in issues, PRs, or problem documents @@ -308,36 +448,146 @@ code and documentation, and follow feedback through to resolution. ## Requesting a role -Role changes use the following request mechanisms: - -| Role | Request mechanism | Approval | -|------|-------------------|----------| -| Vouched | [Vouch Request](https://github.com/fullsend-ai/fullsend/discussions/new?category=vouch-request) | 1 Maintainer | -| Triage | [Triage Request](https://github.com/fullsend-ai/org/issues/new?template=triage-request.yml) issue in [fullsend-ai/org](https://github.com/fullsend-ai/org) | 1 Maintainer | -| Write | [Write Request](https://github.com/fullsend-ai/org/issues/new?template=write-request.yml) issue in [fullsend-ai/org](https://github.com/fullsend-ai/org) | 2 Maintainers | -| Maintainer | [Maintainer Nomination](https://github.com/fullsend-ai/org/issues/new?template=maintainer-request.yml) issue in [fullsend-ai/org](https://github.com/fullsend-ai/org) (see [MAINTAINERS.md](MAINTAINERS.md)) | Maintainer consensus | -| Admin | None yet; ask a member of the [@fullsend-ai/admins](https://github.com/orgs/fullsend-ai/teams/admins) team (see [Admin](#admin)) | Admins; formal process to be defined when needed | - -Approving a request and merging it are separate steps. Maintainers -approve Triage, Write, and Maintainer requests as the table shows, but -each of those roles is granted by a pull request against -[peribolos.yaml](https://github.com/fullsend-ai/org/blob/main/peribolos.yaml) -in [fullsend-ai/org](https://github.com/fullsend-ai/org), and merging -there needs an admin's review. A maintainer can open that pull request -once the request is approved; an admin then approves and merges it. +Maintainers decide every role request above Vouched. A writer or a +maintainer can vouch. The table shows how you request +each role and what an approval needs. + +| Role | Request | Maintainer approvals | A maintainer's objection | Minimum time open | +|------|---------|----------------------|--------------------------|-------------------| +| Vouched | [Vouch Request](https://github.com/fullsend-ai/fullsend/discussions/new?category=vouch-request) discussion | 1, from a writer or a maintainer | No formal objection step | None | +| Triage | [Triage Request](https://github.com/fullsend-ai/org/issues/new?template=triage-request.yml) issue in [fullsend-ai/org](https://github.com/fullsend-ai/org) | 1 | No formal objection step | None | +| Write | [Write Request](https://github.com/fullsend-ai/org/issues/new?template=write-request.yml) issue in [fullsend-ai/org](https://github.com/fullsend-ai/org) | 2 | Blocks the request unless a majority of the maintainers approve | 48 hours | +| Maintainer | [Maintainer Request](https://github.com/fullsend-ai/org/issues/new?template=maintainer-request.yml) issue in [fullsend-ai/org](https://github.com/fullsend-ai/org) | 3 | Blocks the request until withdrawn | 48 hours | +| Admin | [Admin Request](https://github.com/fullsend-ai/org/issues/new?template=admin-request.yml) issue in [fullsend-ai/org](https://github.com/fullsend-ai/org) | 3 | Blocks the request until withdrawn | 48 hours | + +You request a role for yourself. Anyone is welcome to encourage someone +else to apply. + +### The request process + +Write, Maintainer, and Admin requests follow the same steps: + +1. You open the request issue from its template. The 48 hours start + when you open the issue. +2. Maintainers approve or object by commenting on the issue. An + approval posted during the 48 hours counts. The wait gives every + maintainer time to object. +3. The request is ready when three things are true: it has the number + of approvals in the table, no objection blocks it (a Write request + can pass over one, as [Objections](#objections) describes), and it + has been open for 48 hours. +4. A maintainer comments `/fs-code` on the issue. The request is + approved at that moment, if the three conditions hold then. The code + agent checks them and opens a pull request against + [peribolos.yaml](https://github.com/fullsend-ai/org/blob/main/peribolos.yaml) + in [fullsend-ai/org](https://github.com/fullsend-ai/org) that adds + you to the role's teams. +5. A maintainer or an admin confirms the three conditions on the issue, + then approves and merges the pull request. + +An objection counts when a maintainer posts it before the `/fs-code` +comment. Once a request is approved, it is finished. A concern raised +after that goes through [Revoking access](#revoking-access). + +Your own approval does not count toward your request. You do not +comment `/fs-code` on your own request, and you do not approve its pull +request. + +A Triage request has no 48-hour wait and no objection step. Once one +maintainer has approved it on the issue, a maintainer comments +`/fs-code`, and steps 4 and 5 apply with that one approval as the only +condition. + +Maintainers aim to respond to a request within one week. The `/fs-code` +comment must come within 30 days of the day you opened the request. A +request that has not been approved by then is closed as not approved. +You may apply again when you can show what has changed. + +### Objections + +- A maintainer objects by commenting on the request issue. +- An objection stands until the same maintainer withdraws it in a later + comment, for example after you answer the concern. +- A Maintainer or Admin request cannot be approved while an objection + stands, however many approvals it has. +- A Write request with a standing objection needs approval from a + majority of the current maintainers, in place of the usual two. +- A request that is still blocked by an objection 30 days after you + opened it is closed as not approved, like any other request that has + not been approved by then. + +### Reasons for approvals and objections + +A maintainer who approves or objects to a request, for any role, posts +the reasons with the approval or objection. A maintainer may choose not +to post reasons that are sensitive or private. + +Anyone may contact a maintainer privately to ask for the reasons behind +an approval or objection that was posted without them. That maintainer +decides whether to share the reasons, based on who is asking and how +sensitive the reasons are. ## Revoking access -Any admin may revoke a collaborator's access at any role level. Common -reasons include: - -- Extended inactivity (no contributions or reviews for 6+ months) -- Misuse of granted permissions -- Violation of project norms or [contributing guidelines](CONTRIBUTING.md) - -Revocation is not punitive — it reflects current activity level. A -contributor whose access is revoked for inactivity can re-request it -through the normal process. +Maintainers decide when a role is removed, as they decide when it is +granted. A removal follows the same steps as a grant: + +1. Someone opens an issue in + [fullsend-ai/org](https://github.com/fullsend-ai/org) that names the + person and the roles to remove. +2. Maintainers approve by commenting on the issue. +3. A maintainer comments `/fs-code`. The code agent checks the + approvals and opens a pull request against + [peribolos.yaml](https://github.com/fullsend-ai/org/blob/main/peribolos.yaml). +4. A maintainer or an admin confirms the approvals on the issue, then + approves and merges the pull request. + +| Case | Who opens the issue | Maintainer approvals | +|------|---------------------|----------------------| +| Stepping down | You, or a maintainer you asked | None | +| Inactivity | Any maintainer | 2 | +| Removal for cause | Any maintainer | 3 | + +The maintainer who opened the issue may be one of the approvals. A +maintainer whose own role is in question does not count. + +- **Stepping down.** You can give up a role at any time. Open the issue + yourself, or ask a maintainer to open it and confirm in a comment. + Stepping down removes only the roles you name. You keep any other + role you are listed under in + [peribolos.yaml](https://github.com/fullsend-ai/org/blob/main/peribolos.yaml). + If you want a lower role that you are not listed under, request it as + [Requesting a role](#requesting-a-role) describes. +- **Inactivity.** Any maintainer may open the issue for someone with no + contributions or reviews for 6 months or more. The issue mentions the + person by GitHub username, so that they are notified and can respond. + Removal for inactivity covers every role the person holds above + Vouched, and the Admin role if they hold it. An inactive maintainer + gets notice and a grace period first, as described below. +- **Removal for cause.** Causes include misuse of granted permissions + and violation of project norms or the + [contributing guidelines](CONTRIBUTING.md). The three maintainers who + approve also decide which of the person's roles are removed. As with + any approval, they may choose not to post reasons that are sensitive + or private (see + [Reasons for approvals and objections](#reasons-for-approvals-and-objections)). +- **Emergency.** Access can be removed at once for a security reason, + such as a compromised account. It takes two steps: + 1. An admin removes the access directly in GitHub. A maintainer who + is not an admin asks an admin to do it, and tells the other + maintainers straight away. + 2. A maintainer or an admin opens a pull request by hand that removes + the person from `peribolos.yaml`. The file is applied again every + day, so without this step the access comes back. This pull request + does not wait for a removal issue. Another maintainer or admin + approves and merges it. + + The maintainers then confirm or reverse the removal under the rule + for removal for cause. + +Removal for inactivity is not punitive. It reflects your current +activity level. If your role is removed for inactivity, you can request +it again through the normal process. For maintainers, removal for inactivity follows the notification and grace-period process in diff --git a/MAINTAINERS.md b/MAINTAINERS.md index 9297800581..fecc729352 100644 --- a/MAINTAINERS.md +++ b/MAINTAINERS.md @@ -1,56 +1,44 @@ -# Becoming a Maintainer +# Maintainers -Maintainers have merge and approval rights on this repository. They are +Maintainers are the stewards of the project as a whole. They are members of the [@fullsend-ai/maintainers](https://github.com/orgs/fullsend-ai/teams/maintainers) team referenced in [CODEOWNERS](CODEOWNERS). Maintainer is a role on the [contributor ladder](LADDER.md), above -Write and below Admin. See that document for the full path from -first-time contributor to admin, including the other roles (Vouched, -Triage, Write, and Admin). - -## What maintainers do that contributors do not - -Contributors submit pull requests and participate in discussions. -Maintainers carry additional responsibilities: - -- **Review and approve PRs.** Maintainers provide the CODEOWNERS approval - required to merge. This means understanding not just whether code works, - but whether it fits the project's direction and conventions. -- **Triage issues.** Help prioritize incoming issues, label them, and - identify duplicates. -- **Maintain project health.** Keep the backlog healthy, close stale - issues, and ensure CI stays green. -- **Uphold standards.** Enforce the project's +Write. That document holds the criteria and the request process for +every role, including this one. + +## What maintainers do + +People with the Write role can approve and merge pull requests, so +day-to-day review does not depend on maintainers. Maintainers carry +these additional responsibilities: + +- **Decide who holds each role.** Approve or object to role requests at + every level above Vouched, with reasons. See + [Requesting a role](LADDER.md#requesting-a-role). +- **Approve changes to how the project is governed.** That means the + [files reserved for maintainers](LADDER.md#files-reserved-for-maintainers) + in this repository, and every file in + [fullsend-ai/org](https://github.com/fullsend-ai/org). +- **Steward the project's direction.** Take part in architecture + decisions and roadmap discussions. Approve architecture decision + records: each one needs two maintainers, as + [Working with ADRs](CONTRIBUTING.md#working-with-adrs) describes. +- **Review work outside your own area.** Pick up cross-cutting changes + and changes that no one else is placed to judge. +- **Uphold standards and handle disputes.** Enforce the project's [contributing guidelines](CONTRIBUTING.md), - [commit conventions](COMMITS.md), and review etiquette. - -## Eligibility - -You should have a demonstrated track record of contributions — merged -PRs, substantive PR reviews, or both — in -[this repository](https://github.com/fullsend-ai/fullsend) or other -public repositories of the -[fullsend-ai](https://github.com/fullsend-ai) organization. At least -one merged change or substantive review must be in this repository. -Drive-by fixes are appreciated but do not on their own establish the -familiarity needed for a maintainer role. - -## Process - -1. **File a nomination issue** using the - [Maintainer Nomination](https://github.com/fullsend-ai/org/issues/new?template=maintainer-request.yml) - template in [fullsend-ai/org](https://github.com/fullsend-ai/org). - In the issue, link to merged PRs you have authored or - substantive reviews you have provided that demonstrate your - familiarity with the project. -2. **Current maintainers discuss.** The maintainers will review your - contributions and reach a group consensus. Approval is not a single - maintainer's decision — it requires agreement among the existing - maintainer team. -3. **Decision within one week.** A maintainer will follow up on the - issue with the outcome. If approved, you will be added to the - `@fullsend-ai/maintainers` team and gain merge permissions. + [commit conventions](COMMITS.md), and review etiquette. Contributors + turn to maintainers when a review is stuck or a norm is in question. +- **Stay active.** See [Time commitment](#time-commitment) and + [Inactivity and removal](#inactivity-and-removal). + +## Becoming a maintainer + +The criteria are in [LADDER.md § Maintainer](LADDER.md#maintainer). +The request process, including who approves and how objections work, +is in [LADDER.md § Requesting a role](LADDER.md#requesting-a-role). ## Time commitment @@ -116,27 +104,37 @@ removal goes ahead. ### Removal -Removal uses the same GitHub team structure as onboarding: +Removal follows the steps in +[LADDER.md § Revoking access](LADDER.md#revoking-access), with the +notification issue as the removal issue: -1. A maintainer opens a pull request against +1. Two maintainers approve the removal by commenting on the + notification issue. The maintainer who opened the issue may be one + of them. +2. Once the grace period has passed with no response, a maintainer + comments `/fs-code` on the issue. The code agent checks the + approvals and the grace period, and opens a pull request against [peribolos.yaml](https://github.com/fullsend-ai/org/blob/main/peribolos.yaml) - in [fullsend-ai/org](https://github.com/fullsend-ai/org) that removes - the username from the maintainer team. The pull request links the - notification issue. -2. An admin approves and merges it. Team membership changes in - fullsend-ai/org need an admin's approval, so a maintainer cannot - complete a removal alone. The notification issue is then closed. + in [fullsend-ai/org](https://github.com/fullsend-ai/org). It removes + the username from the maintainers team, from the Write and Triage + teams, and from the admins team if they are on it. Inactivity + removes every role above Vouched and the Admin role, because the + 6-month threshold applies to each of them. +3. A maintainer or an admin approves and merges the pull request. The + notification issue is then closed. Code ownership follows team membership. [CODEOWNERS](CODEOWNERS) names -the maintainer team, not individual users, so removing someone from the -team also removes their code owner approval. No per-user CODEOWNERS -edit is needed. If CODEOWNERS ever lists individual maintainers, the -removal pull request must also remove the username there. +the maintainers team and the Write team, not individual users, so +removing someone from those teams also removes their code owner +approval. No per-user CODEOWNERS edit is needed. If CODEOWNERS ever +lists individual users, the removal pull request must also remove the +username there. ### Returning -A former maintainer removed for inactivity is welcome to return. File a -new nomination through the normal [Process](#process). +A former maintainer removed for inactivity is welcome to return. Open a +new request through the normal +[request process](LADDER.md#requesting-a-role). ## Team meetings and communication @@ -148,7 +146,13 @@ maintainer coordination — but that infrastructure is not yet in place. ## Stepping down -If you no longer wish to serve as a maintainer, open an issue or let an -existing maintainer know. You will be removed from the `@fullsend-ai/maintainers` -team. Stepping down is normal and carries no stigma — contributions are -always welcome regardless of maintainer status. +If you no longer wish to serve as a maintainer, open an issue in +[fullsend-ai/org](https://github.com/fullsend-ai/org) that says so, as +[Revoking access](LADDER.md#revoking-access) describes. A maintainer +can open it for you if you confirm in a comment on it. You will be +removed from the `@fullsend-ai/maintainers` team. Any other role you +are listed under stays as it is. If you are not on the Write teams and +want to keep approving pull requests, request the Write role as +[Requesting a role](LADDER.md#requesting-a-role) describes. Stepping +down is normal and carries no stigma. Contributions are always welcome +regardless of maintainer status. diff --git a/docs/contributing/vouch-system.md b/docs/contributing/vouch-system.md index 03d64b8b3f..916999e8dd 100644 --- a/docs/contributing/vouch-system.md +++ b/docs/contributing/vouch-system.md @@ -4,7 +4,7 @@ - `vouch-check` runs on a schedule (every 10 minutes) and on `workflow_dispatch`, not on `pull_request_target` ([#9245](https://github.com/fullsend-ai/fullsend/issues/9245)). It runs [`scripts/vouch-sweep.sh`](../../scripts/vouch-sweep.sh), which reads PR metadata through the API and never checks out PR code. Only PRs opened or reopened in the last 60 minutes are checked, so overlapping runs cover a missed or late cron run and older open PRs are left alone. An unvouched PR can therefore stay open for up to about 10 minutes before it is closed. - To preview a sweep without closing or commenting, run `scripts/vouch-sweep.sh --dry-run fullsend-ai/fullsend` with a `GH_TOKEN` that can read the repository. - Org members and collaborators with write access bypass the vouch gate automatically. -- Maintainers vouch users by commenting `/vouch` on a Vouch Request discussion. The `vouch-command` workflow appends the username to `.github/VOUCHED.td` on the `vouched` branch. +- Writers and maintainers vouch users by commenting `/vouch` on a Vouch Request discussion. The `vouch-command` workflow appends the username to `.github/VOUCHED.td` on the `vouched` branch. - After a successful `/vouch`, the `vouch-command` workflow closes the Vouch Request discussion automatically with the `RESOLVED` reason. This includes the already-vouched case (the request is complete either way); maintainers do not need to close the discussion by hand. - Agent bot identities (`fullsend-ai-*[bot]`, `renovate-fullsend[bot]`, `github-actions[bot]`) are skipped automatically because they have `user.type: 'Bot'`. - The `vouched` branch is protected — only the `vouch-command` workflow (via `GITHUB_TOKEN`) can push to it. Do not push to, rebase, or target PRs at the `vouched` branch. diff --git a/docs/guides/dev/behaviour-testing.md b/docs/guides/dev/behaviour-testing.md index 35c0cdf289..f5799c9302 100644 --- a/docs/guides/dev/behaviour-testing.md +++ b/docs/guides/dev/behaviour-testing.md @@ -778,8 +778,9 @@ breaks the agents suite before it merges. time with **Re-run all jobs** on the pull request's `behaviour-github-emulator` run. Every shard, the playback job and the `behaviour-github-emulator (agents)` job must pass both times. -3. A maintainer opens or takes over the pull request that moves the pin, since - it edits a workflow file, and links the two validation runs in it. +3. A writer or a maintainer opens or takes over the pull request that moves + the pin, since it edits a workflow file, and links the two validation runs + in it. The agents repository's emulator job reads the pin from the fullsend checkout it builds, so it follows this pin with no change in that repository. diff --git a/docs/guides/user/escalation-ladder.md b/docs/guides/user/escalation-ladder.md index 0245420315..1d68b93cc7 100644 --- a/docs/guides/user/escalation-ladder.md +++ b/docs/guides/user/escalation-ladder.md @@ -83,8 +83,8 @@ repo (harness, scripts, skills, agent definitions), contribute there. If the agent definition or harness lives in [fullsend-ai/agents](https://github.com/fullsend-ai/agents), contribute to that repo instead. First-time contributors must be -[vouched](../../../CONTRIBUTING.md) by a maintainer before opening a PR — -unvouched PRs are auto-closed. +[vouched](../../../CONTRIBUTING.md) by a writer or a maintainer before +opening a PR — unvouched PRs are auto-closed. **Evidence to escalate:** show that the improvement you need is specific to your team's workflow and would not benefit other users. Concrete evidence diff --git a/docs/roadmap.md b/docs/roadmap.md index cd766e806d..0a76c5449d 100644 --- a/docs/roadmap.md +++ b/docs/roadmap.md @@ -107,10 +107,10 @@ The work below is what this edition focuses on. ### Community -Gain additional contributors through the [maintainer process](https://github.com/fullsend-ai/fullsend/blob/main/MAINTAINERS.md). +Gain additional contributors through the [contributor ladder](https://github.com/fullsend-ai/fullsend/blob/main/LADDER.md). Do not promise specific number of new maintainers. Keep contributor pull requests moving. Progress is tracked through PR review velocity and the -maintainer process rather than dedicated issues. +contributor ladder rather than dedicated issues. ### Platform diff --git a/internal/owners/codeowners_repo_test.go b/internal/owners/codeowners_repo_test.go index 398009203b..0c8a05c751 100644 --- a/internal/owners/codeowners_repo_test.go +++ b/internal/owners/codeowners_repo_test.go @@ -72,13 +72,47 @@ func codeownerTokenValid(token string) bool { // surfaced via the repos code-owners-errors API, so a bracketed // rule can neither revoke nor grant review. // -// Whole-path matching only: directory-containment rules ("docs/") over -// their contents are not modeled, which is sound because the guarded -// target is a root-level file with no ancestor directories. +// Directory containment is modeled too, because some guarded files sit +// below the root (".github/CODEOWNERS", this test file): a rule that +// matches a directory owns everything beneath it. That covers +// directory-only rules ("docs/", "/internal/") and rules without a +// trailing slash that name an ancestor directory ("/internal", "docs"). +// A directory-only rule may end in a wildcard segment ("/internal/*/", +// "*/"): the trailing slash makes that segment match directories, so +// the rule owns what is beneath each one. func codeownersPatternMatches(pattern, relPath string) bool { + if pattern == "" { + return false + } + dirOnly := strings.HasSuffix(pattern, "/") + if !dirOnly && codeownersPatternMatchesPath(pattern, relPath) { + return true + } + // Try the rule against each ancestor directory of relPath. + dirPattern := strings.TrimSuffix(pattern, "/") + if dirPattern == "" { + return false + } + if !dirOnly && (dirPattern == "*" || strings.HasSuffix(dirPattern, "/*")) { + // Without a trailing slash, a final "*" segment matches files + // only: GitHub documents that "docs/*" does not own files + // nested deeper. + return false + } + for i, r := range relPath { + if r == '/' && codeownersPatternMatchesPath(dirPattern, relPath[:i]) { + return true + } + } + return false +} + +// codeownersPatternMatchesPath reports whether pattern, which carries no +// trailing slash, matches relPath as a whole path (a file, or a +// directory when the caller passes an ancestor). +func codeownersPatternMatchesPath(pattern, relPath string) bool { p := pattern - if p == "" || strings.HasSuffix(p, "/") { - // Empty or directory-only rule: cannot match a file. + if p == "" { return false } if strings.Contains(p, "[") { @@ -189,7 +223,7 @@ func codeownersOwners(content, relPath string) []string { // merely move commit pointers inside trusted repos — it maps submodule // names to fetch URLs. GitHub CODEOWNERS is last-match-wins, so a // blank-owner rule matching ".gitmodules" after the -// "* @fullsend-ai/maintainers" wildcard removes the human-review gate for +// wildcard rule removes the human-review gate for // submodule URL swaps. // // The effective owner list must equal exactly @fullsend-ai/maintainers, @@ -213,6 +247,42 @@ func TestRepoCodeownersRetainsOwnerForGitmodules(t *testing.T) { "removes the review gate entirely (issue #6082)", loc, owners) } +// TestRepoCodeownersReservesGovernanceFiles guards the files that +// LADDER.md reserves for maintainers ("Files reserved for maintainers"). +// The CODEOWNERS wildcard also names @fullsend-ai/fullsend-writers, so +// each reserved path needs its own later rule that resolves to exactly +// @fullsend-ai/maintainers. Without that rule a writer's approval would +// allow a change to the file. +// +// All three locations GitHub reads CODEOWNERS from are covered. GitHub +// uses only the first file it finds (.github/, the root, then docs/), +// so an unreserved location that is read before the current file would +// let a writer-approved pull request replace every rule here. This +// test file is on the list for the same reason: it is the guard. +// +// One ADR stands in for the "/docs/ADRs/" directory rule. +func TestRepoCodeownersReservesGovernanceFiles(t *testing.T) { + content, loc := repoCodeowners(t) + + for _, relPath := range []string{ + "CODEOWNERS", + ".github/CODEOWNERS", + "docs/CODEOWNERS", + "internal/owners/codeowners_repo_test.go", + "LADDER.md", + "MAINTAINERS.md", + "docs/ADRs/0001-use-adrs-for-decision-making.md", + } { + t.Run(relPath, func(t *testing.T) { + owners := codeownersOwners(content, relPath) + require.Equal(t, []string{"@fullsend-ai/maintainers"}, owners, + "effective CODEOWNERS (%s) must resolve %s to exactly "+ + "[@fullsend-ai/maintainers] (got %v): LADDER.md "+ + "reserves this file for maintainers", loc, relPath, owners) + }) + } +} + // TestCodeownersOwnersMatchesGitignoreVariants proves the guard resolves // patterns the way GitHub matches them, not just literal strings: any // blank-owner rule after the catch-all that the CODEOWNERS dialect lets @@ -254,6 +324,17 @@ func TestCodeownersOwnersMatchesGitignoreVariants(t *testing.T) { {"interior globstar needs the named dir", "a/**/b", "a", core}, {"trailing globstar matches inside", "a/**", "a/b/c/x", revoked}, {"trailing globstar misses the dir itself", "a/**", "a", core}, + {"dir-only docs/ owns files beneath it", "docs/", "docs/CODEOWNERS", revoked}, + {"anchored dir /internal/ owns nested files", "/internal/", "internal/owners/x_test.go", revoked}, + {"anchored /internal without slash owns nested files", "/internal", "internal/owners/x_test.go", revoked}, + {"bare dir name owns files beneath it at depth", "owners", "internal/owners/x_test.go", revoked}, + {"anchored dir /owners/ misses a nested dir", "/owners/", "internal/owners/x_test.go", core}, + {"single star dir/* misses deeper files", "internal/*", "internal/owners/x_test.go", core}, + {"dir-only wildcard /internal/*/ owns nested files", "/internal/*/", "internal/owners/x_test.go", revoked}, + {"dir-only wildcard */ owns files in any directory", "*/", "internal/owners/x_test.go", revoked}, + {"dir-only wildcard */ misses a root file", "*/", ".gitmodules", core}, + {"dir-only wildcard /docs/*/ misses a file directly in docs", "/docs/*/", "docs/CODEOWNERS", core}, + {"dir rule for another dir keeps owner", ".github/", "docs/CODEOWNERS", core}, {"invalid owner token line is skipped like GitHub", ".gitmodules core-team", ".gitmodules", core}, {"blank revokes when later invalid co-owner line is skipped", ".gitmodules\n.gitmodules @fullsend-ai/core core-team", ".gitmodules", revoked}, {"invalid co-owner falls back to wildcard without false red", ".gitmodules @fullsend-ai/core core-team", ".gitmodules", core},