-
Notifications
You must be signed in to change notification settings - Fork 10
fix: enforce mypy on changed files, and make the PR review bot always submit a verdict #614
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from 5 commits
50aeb30
aa8ce43
ca69a8c
e684a0a
eb4d00e
311cc48
8acced2
e8cc0c7
fd2d5c7
ebd9349
63931b3
61856c4
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,2 @@ | ||
| - [Board field IDs](project_board_field_ids.md) — GraphQL node/field/option IDs for Status/Priority/Awaiting; Priority has NO P0 option, only P1-P4 | ||
| - [Board state 2026-08-16](project_backlog_board_state_2026_08_16.md) — board had only 1 of 36 open issues before this pass; digest column ≠ board presence |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,32 @@ | ||
| --- | ||
| name: project_backlog_board_state_2026_08_16 | ||
| description: State of the backlog board before/after the first board-writes-only PO pass on 2026-08-16 — only #611 was on the board, 35 issues missing entirely | ||
| metadata: | ||
| type: project | ||
| --- | ||
|
|
||
| Before this pass, the board (project 1) had exactly **one** card (#611, | ||
| P1/Backlog) despite 36 open issues existing. `backlog-digest.sh` derives a | ||
| `column` for every open issue regardless of whether it's on the board, which | ||
| made this easy to miss without diffing against `gh project item-list` | ||
| directly — the digest's presence doesn't imply board presence. | ||
|
|
||
| **Why:** board-init/bootstrap work (PRs around #609-611 per recent commits) | ||
| created the project and field schema but never did a bulk backlog import — | ||
| only the issue that happened to be filed around that time landed on it. | ||
|
|
||
| **How to apply:** before trusting "the board is roughly in sync," diff | ||
| `gh project item-list` counts against `gh issue list --state open` counts. | ||
| Don't assume prior passes kept the board populated. | ||
|
|
||
| Several issues surfaced during this pass that are candidates for maintainer | ||
| attention but were out of scope (board-writes-only run): | ||
| - #520/#393/#571 form a cluster (LOAD_SUPPORT / discharge-gate shadow-price | ||
| correctness) — likely worth a combined roadmap push rather than fixing | ||
| piecewise. | ||
| - #118 (Solax-Growatt MIN-inverter correction) has 29 comments — the busiest | ||
| thread in the backlog — and is still unlabeled and un-triaged. | ||
| - #96 is the only `analyzed`/Ready for Dev item; everything else needing | ||
| Stage 2 analysis is still sitting in Analysis. | ||
|
|
||
| See [[project_board_field_ids]] for the GraphQL mechanics used. |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,32 @@ | ||
| --- | ||
| name: project_board_field_ids | ||
| description: GraphQL node/field/option IDs for the backlog board (project 1) — Status, Priority, Awaiting — and the Priority field's real options | ||
| metadata: | ||
| type: project | ||
| --- | ||
|
|
||
| Board GraphQL IDs, confirmed working 2026-08-16 via a full-board write pass | ||
| (all 36 open issues added, Status/Priority/Awaiting set on every card): | ||
|
|
||
| - Project id: `PVT_kwHOACEigM4Bgiwa` | ||
| - Status field: `PVTSSF_lAHOACEigM4Bgiwazhfh7Mg` — options: Backlog `f75ad846`, | ||
| Analysis `012dae50`, Ready for Dev `456880aa`, In Progress `47fc9ee4`, | ||
| In Review `58ad8ead`, Done `98236657` | ||
| - Priority field: `PVTSSF_lAHOACEigM4Bgiwazhfh7NQ` — options are **P1 `131c5c2f`, | ||
| P2 `107b9947`, P3 `6d4b1494`, P4 `4d153125`. There is no P0 option** — | ||
| the backlog skill/task text that references "P0 da61340b" is stale; that | ||
| option id does not exist on the live field. Treat P1 as the top tier. | ||
| - Awaiting field: `PVTSSF_lAHOACEigM4Bgiwazhfh7Nw` — options: reporter | ||
| `71ef723a`, discussion `82098dd9`, upstream `16ca2f41`, analysis `c7538747` | ||
|
|
||
| Mutation shape that works: `addProjectV2ItemById(input: {projectId, contentId})` | ||
| to add a card (contentId = issue node id from `gh issue list --json id`), then | ||
| `updateProjectV2ItemFieldValue(input: {projectId, itemId, fieldId, value: | ||
| {singleSelectOptionId}})` per field. Run via | ||
| `scripts/gh-agent.sh --as po api graphql -f query='...' -f name=value ...` | ||
| from inside the repo checkout (it resolves `.env` via `git rev-parse | ||
| --git-common-dir`, so it fails silently with "BESS_PO_TOKEN not set" if run | ||
| from a non-repo cwd like a scratch tmpdir). | ||
|
|
||
| See [[project_backlog_board_state_2026_08_16]] for what was actually on the | ||
| board before/after this pass. |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -3,6 +3,7 @@ pytest-cov | |
| httpx | ||
| black | ||
| ruff | ||
| mypy | ||
| pyyaml | ||
| podman-compose | ||
| websockets | ||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,86 @@ | ||
| #!/usr/bin/env bash | ||
| # | ||
| # Create the Product Owner's kanban board, once. Idempotent: if a project with | ||
| # this title already exists, print its number and change nothing. | ||
| # | ||
| # Run this as the MAINTAINER, not as the PO identity. A GitHub user cannot | ||
| # create a Project inside another user's account, and the board deliberately | ||
| # lives under the maintainer's account — it is their backlog and where they | ||
| # will look for it. `scripts/gh-agent.sh --as po project list --owner | ||
| # johanzander` returns "unknown owner type" for exactly this reason. | ||
| # | ||
| # The PO then gets write access to the board as a project collaborator, which | ||
| # is a separate grant from repo collaboration — repo write does NOT imply | ||
| # project write. That step is manual (see the end of this script's output): | ||
| # the Projects v2 API exposes no collaborator-invite mutation. | ||
| # | ||
| # Usage: | ||
| # scripts/backlog-board-init.sh # create or report the board | ||
| # | ||
| # Output (stdout, last line): | ||
| # PROJECT_NUMBER <n> | ||
| set -euo pipefail | ||
|
|
||
| owner="${PROJECT_OWNER:-johanzander}" | ||
| title="BESS Manager Backlog" | ||
|
|
||
| # `gh project` needs the `project` scope. Fail with the fix rather than a raw | ||
| # GraphQL error — this is the single most common setup failure here. | ||
| if ! gh auth status 2>&1 | grep -q "project"; then | ||
| echo "backlog-board-init.sh: your gh token lacks the 'project' scope." >&2 | ||
| echo " Fix: gh auth refresh -s project" >&2 | ||
| exit 1 | ||
| fi | ||
|
|
||
| existing=$(gh project list --owner "$owner" --format json \ | ||
| --jq ".projects[] | select(.title == \"$title\") | .number" || true) | ||
|
|
||
| if [ -n "$existing" ]; then | ||
| echo "Board already exists — nothing changed." >&2 | ||
| echo "PROJECT_NUMBER $existing" | ||
| exit 0 | ||
| fi | ||
|
|
||
| number=$(gh project create --owner "$owner" --title "$title" \ | ||
| --format json --jq '.number') | ||
|
|
||
| echo "Created project #$number." >&2 | ||
|
|
||
| # Custom fields. The built-in Status field carries the columns and is edited | ||
| # separately (see the closing instructions) — `gh` cannot rewrite the options | ||
| # of a built-in single-select field. | ||
| gh project field-create "$number" --owner "$owner" \ | ||
| --name "Priority" --data-type SINGLE_SELECT \ | ||
| --single-select-options "P0,P1,P2" >/dev/null | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more.
|
||
| echo " + Priority field (P0,P1,P2)" >&2 | ||
|
|
||
| gh project field-create "$number" --owner "$owner" \ | ||
| --name "Source" --data-type SINGLE_SELECT \ | ||
| --single-select-options "issue,TODO" >/dev/null | ||
| echo " + Source field (issue,TODO)" >&2 | ||
|
|
||
| gh project field-create "$number" --owner "$owner" \ | ||
| --name "Awaiting" --data-type SINGLE_SELECT \ | ||
| --single-select-options "reporter,discussion,upstream,analysis" >/dev/null | ||
| echo " + Awaiting field (reporter,discussion,upstream,analysis)" >&2 | ||
|
|
||
| cat >&2 <<REMAINING | ||
|
|
||
| Two steps remain and neither can be scripted — the Projects v2 API exposes no | ||
| mutation for either: | ||
|
|
||
| 1. Columns. Open the board, edit the built-in Status field, and set its | ||
| options to exactly: | ||
| Backlog, Analysis, Ready for Dev, In Progress, In Review, Done | ||
| The digest derives these names; a mismatch silently strands cards. | ||
|
|
||
| 2. PO access. Project -> ... -> Settings -> Manage access -> invite | ||
| bess-product-owner with write. Repo collaboration does NOT grant project | ||
| access, so without this every board write fails as the PO. | ||
|
|
||
| Then export PROJECT_NUMBER=$number (or add it to your shell profile) and run | ||
| scripts/backlog-digest.sh to confirm the board is readable. | ||
|
|
||
| REMAINING | ||
|
|
||
| echo "PROJECT_NUMBER $number" | ||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This line (new in this PR) still lists
P0 da61340bas a live Priority option:But
project_board_field_ids.md, added by this same PR, says the opposite:This PR is introducing the stale claim into
SKILL.mdin the same diff that documents it as stale elsewhere. Should be fixed to match the confirmed P1–P4 values before merge.