Drop feature-flag patch; pass --no-default-features at all build sites - #50
Conversation
📝 WalkthroughWalkthroughChangesThe downstream packaging flow removes non-Linux dependencies, uses system libraries, applies explicit build-time feature flags consistently across build, test, and vendor generation, and updates patch-maintenance documentation and compliance checks. Downstream build alignment
Estimated code review effort: 3 (Moderate) | ~20 minutes Possibly related PRs
Suggested reviewers: 🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Comment |
ef66eec to
a7e324d
Compare
0002-Set-downstream-feature-flags.patch had two concerns conflated:
1. Switch sqlx sqlite → sqlite-unbundled (system library linkage)
2. Rewrite Cargo.toml default feature lists to suppress upstream
defaults (rustls-tls, aws-providers, …) that pull in forbidden
content
Split them apart:
• The sqlite-unbundled change moves into Patch 0001, where it belongs
alongside the other system-library linkage decisions.
• Feature selection is now explicit at every call site via
--no-default-features --features %{downstream_features}, defined
once as a %global in the spec and mirrored in the cargo
vendor-filterer call in generate-vendor-tarball.sh.
This removes a Cargo.toml patch that needed rebasing on every upstream
release and replaces it with a single source of truth that is visible
in the build invocations rather than buried in a patch file.
Updated 03-patch-rebase.md, 08-spec-updates.md, and
09-compliance-checklist.md to reflect the new approach and to fix
an existing doc error (0003/0004 are dependency patches, not code
patches).
a7e324d to
be82920
Compare
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In @.claude/commands/goose-update/08-spec-updates.md:
- Around line 130-135: Update section 8.6.4 to require verifying that all five
feature names still exist upstream during every update, including handling
renamed or removed features before reusing them in %cargo_build, %cargo_test,
and generate-vendor-tarball.sh. Require updating all affected call sites
atomically and regenerating the vendor tarball with only valid, permitted
features.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: CHILL
Plan: Enterprise
Run ID: 686f97a3-6943-489b-a549-c1b885c521d3
📒 Files selected for processing (7)
.claude/commands/goose-update/03-patch-rebase.md.claude/commands/goose-update/08-spec-updates.md.claude/commands/goose-update/09-compliance-checklist.md0001-Strip-non-Linux-deps-and-use-system-libraries.patch0002-Set-downstream-feature-flags.patchgenerate-vendor-tarball.shgoose.spec
💤 Files with no reviewable changes (1)
- 0002-Set-downstream-feature-flags.patch
🚧 Files skipped from review as they are similar to previous changes (5)
- goose.spec
- generate-vendor-tarball.sh
- .claude/commands/goose-update/09-compliance-checklist.md
- .claude/commands/goose-update/03-patch-rebase.md
- 0001-Strip-non-Linux-deps-and-use-system-libraries.patch
| ### 8.6.4 When to change the feature set | ||
|
|
||
| Only change these flags when a new upstream feature replaces or augments one of | ||
| the five listed. When that happens, update **all three call sites** atomically | ||
| and re-generate the vendor tarball. Never add features that pull in forbidden | ||
| content (see Phase 5 and the compliance checklist). |
There was a problem hiding this comment.
🎯 Functional Correctness | 🟡 Minor | ⚡ Quick win
🧩 Analysis chain
🏁 Script executed:
#!/bin/bash
set -euo pipefail
# Inspect the target section and nearby references
file=".claude/commands/goose-update/08-spec-updates.md"
wc -l "$file"
sed -n '110,155p' "$file"
printf '\n---\n'
# Find mentions of the five features, Cargo.toml, and call sites in this workflow
rg -n "feature set|Cargo.toml|call sites|forbidden content|five listed|feature" .claude/commands/goose-update -g '*.md'Repository: rhel-lightspeed/goose
Length of output: 12910
🏁 Script executed:
#!/bin/bash
set -euo pipefail
sed -n '84,140p' .claude/commands/goose-update/08-spec-updates.md
printf '\n---\n'
sed -n '33,72p' .claude/commands/goose-update/01-preflight.mdRepository: rhel-lightspeed/goose
Length of output: 3319
Handle removed and renamed features too. On each update, check that all five feature names still exist upstream before reusing them in %cargo_build, %cargo_test, and generate-vendor-tarball.sh; otherwise a renamed or removed feature will leave all three call sites with an invalid --features list.
🤖 Prompt for AI Agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
In @.claude/commands/goose-update/08-spec-updates.md around lines 130 - 135,
Update section 8.6.4 to require verifying that all five feature names still
exist upstream during every update, including handling renamed or removed
features before reusing them in %cargo_build, %cargo_test, and
generate-vendor-tarball.sh. Require updating all affected call sites atomically
and regenerating the vendor tarball with only valid, permitted features.
Source: Path instructions
0002-Set-downstream-feature-flags.patch had two concerns conflated:
Split them apart:
• The sqlite-unbundled change moves into Patch 0001, where it belongs
alongside the other system-library linkage decisions.
• Feature selection is now explicit at every call site via
--no-default-features --features %{downstream_features}, defined
once as a %global in the spec and mirrored in the cargo
vendor-filterer call in generate-vendor-tarball.sh.
This removes a Cargo.toml patch that needed rebasing on every upstream release and replaces it with a single source of truth that is visible in the build invocations rather than buried in a patch file.
Updated 03-patch-rebase.md, 08-spec-updates.md, and 09-compliance-checklist.md to reflect the new approach and to fix an existing doc error (0003/0004 are dependency patches, not code patches).
Summary by CodeRabbit
Build & Packaging
Documentation