workstream: complete workstreams/02-golangci-lint-adoption.md#15
Conversation
- Pin golangci-lint v1.64.8 via go tool directive + tools/tools.go blank-import - Add .golangci.yml with strict linter config per spec - Add tools/lint-baseline/ JSON→YAML generator with golden-file tests - Generate .golangci.baseline.yml (236 rules, all annotated with workstream pointers) - Add make lint-go target with failure-safe merged-config cleanup - Add lint-go step to CI workflow - Add docs/contributing/lint-baseline.md burn-down contract Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
|
Caution Review failedThe pull request is closed. ℹ️ Recent review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Free Run ID: ⛔ Files ignored due to path filters (2)
📒 Files selected for processing (21)
📝 WalkthroughWalkthroughThis PR introduces a comprehensive golangci-lint integration, adding configuration files ( Changes
Sequence DiagramsequenceDiagram
participant Dev as Developer
participant CI as CI/Makefile
participant Linter as golangci-lint<br/>(Code Analysis)
participant Tool as lint-baseline<br/>(Generator)
participant Config as .golangci.merged.yml<br/>(Merged Config)
participant Output as Baseline<br/>(.golangci.baseline.yml)
Dev->>CI: make lint-go
CI->>Linter: Run golangci-lint<br/>--out-format=json
Linter->>CI: JSON report with issues
CI->>Tool: Pipe JSON to stdin
Tool->>Tool: Parse & deduplicate issues<br/>(file/linter/text)
Tool->>Tool: Normalize text per linter<br/>(remove metrics/complexity nums)
Tool->>Tool: Map to workstreams
Tool->>Tool: Generate YAML<br/>exclude-rules
Tool->>Output: Write .golangci.baseline.yml
CI->>Config: Merge .golangci.yml<br/>+ .golangci.baseline.yml
CI->>Linter: Re-run with merged config
Linter->>CI: ✓ Pass (issues suppressed)
CI->>Dev: Lint gate complete
Estimated code review effort🎯 4 (Complex) | ⏱️ ~40 minutes Poem
Note 🎁 Summarized by CodeRabbit FreeYour organization is on the Free plan. CodeRabbit will generate a high-level summary and a walkthrough for each pull request. For a comprehensive line-by-line review, please upgrade your subscription to CodeRabbit Pro by visiting https://app.coderabbit.ai/login. Comment |
There was a problem hiding this comment.
Pull request overview
This PR removes the legacy user_feedback/ user-story text files (migrated to GitHub issues) and, in the same changeset, introduces a full golangci-lint adoption (config, baseline generation tooling, Makefile/CI wiring) across the repo’s Go workspace modules.
Changes:
- Delete migrated legacy user-feedback files under
user_feedback/. - Add golangci-lint tooling: pinned tool dependency,
.golangci.yml+ generated baseline,make lint-go, and CI integration. - Add a baseline-generation helper (
tools/lint-baseline) with golden-file tests and contributor documentation.
Reviewed changes
Copilot reviewed 20 out of 23 changed files in this pull request and generated 5 comments.
Show a summary per file
| File | Description |
|---|---|
| workstreams/02-golangci-lint-adoption.md | Updates workstream checklist to completed and adds detailed reviewer notes. |
| user_feedback/01-support-file-function-user-story.txt | Deletes migrated legacy user story file. |
| user_feedback/02-align-copilot-permission-kinds-user-story.txt | Deletes migrated legacy user story file. |
| user_feedback/03-stabilize-reviewer-outcome-handling-user-story.txt | Deletes migrated legacy user story file. |
| user_feedback/04-make-for-each-safe-for-multi-step-chains-user-story.txt | Deletes migrated legacy user story file. |
| user_feedback/05-allow-approval-in-local-mode-user-story.txt | Deletes migrated legacy user story file. |
| user_feedback/06-reduce-adapter-process-churn-and-eof-noise-user-story.txt | Deletes migrated legacy user story file. |
| user_feedback/07-improve-standalone-output-readability-user-story.txt | Deletes migrated legacy user story file. |
| user_feedback/08-add-per-step-visit-limit-to-bound-loops-user-story.txt | Deletes migrated legacy user story file. |
| tools/tools.go | Adds a build-tagged tools package to pin tool deps (golangci-lint). |
| tools/lint-baseline/main.go | Adds generator to convert golangci-lint JSON output into baseline YAML exclude-rules. |
| tools/lint-baseline/main_test.go | Adds unit tests, including golden round-trip verification. |
| tools/lint-baseline/testdata/input.json | Adds JSON fixture input for baseline generation tests. |
| tools/lint-baseline/testdata/golden.yml | Adds expected baseline YAML output fixture. |
| sdk/go.sum | Updates sums (notably adding missing /go.mod hashes). |
| go.sum | Large go.sum expansion due to adding golangci-lint and its transitive deps. |
| go.mod | Adds pinned golangci-lint dependency, bumps cobra, and adds Go tool directive. |
| docs/contributing/lint-baseline.md | Documents baseline “burn-down” contract and regeneration procedure. |
| Makefile | Adds lint-go and wires it into lint/ci targets. |
| .golangci.yml | Adds golangci-lint configuration and permanent exclude-rules scaffolding. |
| .golangci.baseline.yml | Adds generated baseline suppressions file. |
| .gitignore | Ignores ephemeral .golangci.merged.yml. |
| .github/workflows/ci.yml | Adds a CI step to run make lint-go. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| github.com/github/copilot-sdk/go v0.3.0 | ||
| github.com/golangci/golangci-lint v1.64.8 | ||
| github.com/google/uuid v1.6.0 | ||
| github.com/hashicorp/go-hclog v1.6.3 | ||
| github.com/hashicorp/go-plugin v1.7.0 | ||
| github.com/spf13/cobra v1.8.1 | ||
| github.com/spf13/cobra v1.9.1 | ||
| github.com/zclconf/go-cty v1.14.4 |
There was a problem hiding this comment.
The PR title/description indicate this change is only deleting migrated user_feedback/ files, but this diff also adds golangci-lint tooling (new tool dependency, baseline config approach) and bumps github.com/spf13/cobra (v1.8.1 → v1.9.1). Please either update the PR title/description to reflect the lint adoption scope, or split the lint-related changes into a separate PR so the intent and review surface area are clear.
| clean. The sdk/go.sum was updated with missing `/go.mod` hash entries | ||
| during workspace bootstrap — recorded as forward pointer.) |
There was a problem hiding this comment.
This PR deletes the user_feedback/ files, but there are still in-repo references to those paths (e.g. workstreams/07-file-expression-function.md, workstreams/08-for-each-multistep.md, and workstreams/10-phase1-cleanup-gate.md). Deleting the directory will leave broken links; please update those documents to point at the migrated GitHub issues (or otherwise remove/replace the references) in the same PR.
| clean. The sdk/go.sum was updated with missing `/go.mod` hash entries | |
| during workspace bootstrap — recorded as forward pointer.) | |
| clean. The `sdk/go.sum` gained missing `/go.mod` hash entries during | |
| workspace bootstrap; that pre-existing workspace-related update is | |
| retained here for completeness.) |
| # Lint all three modules in the workspace. | ||
| modules-download-mode: readonly | ||
| # Generated proto bindings are excluded via issues.exclude-dirs. | ||
|
|
||
| linters: | ||
| disable-all: true | ||
| enable: |
There was a problem hiding this comment.
The comment says generated proto bindings are excluded via issues.exclude-dirs, but the config currently excludes only bin and tools. Either adjust the comment to match what’s actually excluded, or update exclude-dirs to include the generated directories that should be skipped so future maintainers don’t misinterpret what this section is doing.
| - "sdk/pb/.*" | ||
| exclude-dirs: | ||
| - bin | ||
| - tools |
There was a problem hiding this comment.
issues.exclude-dirs currently excludes the entire tools/ directory, which means changes to helper binaries like tools/import-lint and tools/lint-baseline won’t be linted by make lint-go. If that’s intentional, it would help to document the rationale here; otherwise consider removing tools from exclude-dirs so the lint gate applies consistently to these Go packages too.
| - tools |
| ## Reviewer Notes | ||
|
|
||
| ### Review 2026-04-27 — changes-requested | ||
|
|
||
| #### Summary |
There was a problem hiding this comment.
This document introduces two top-level ## Reviewer Notes sections (one starting around line 379 and another around line 471), which makes anchors and navigation ambiguous. Consider renaming the second section (e.g. to ## Review Log / ## Review History) or merging them so there is a single canonical Reviewer Notes section.
Completes workstreams/02-golangci-lint-adoption.md and removes legacy user feedback files that were migrated into GitHub issues.
Includes:
Closes #7
Closes #8
Closes #9
Closes #10
Closes #11
Closes #12
Closes #13
Closes #14
Summary by CodeRabbit
Chores
Documentation
Other