Repository navigation
docs(purchase): defer savings-plans alias drop to 2026-10-30 (closes #95) - #827
Conversation
|
@coderabbitai review |
|
Important Review skippedNo new commits to review since the last review. ⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
📝 WalkthroughWalkthroughThis PR updates comments in two modules to document Savings Plans slug normalization, legacy ChangesSavings Plans Alias Documentation Updates
Estimated code review effort: 1 (Trivial) | ~3 minutes Possibly related PRs
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
✅ Actions performedReview triggered.
|
|
@coderabbitai full review |
✅ Actions performedFull review triggered. |
|
@coderabbitai review |
Rate Limit Exceeded
|
|
@coderabbitai full review Generated by Claude Code |
|
Tip For best results, initiate chat on the files or code changes. 🧩 Analysis chain🏁 Script executed: #!/bin/bash
# Get PR details
gh pr view 827 --repo LeanerCloud/CUDly --json title,body,files,state,baseRefName,headRefName
echo "---FILES CHANGED---"
gh pr diff 827 --repo LeanerCloud/CUDlyLength of output: 5438
Review:
|
|
@coderabbitai full review |
✅ Action performedFull review finished. |
|
@coderabbitai full review |
✅ Action performedFull review finished. |
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 `@internal/purchase/execution.go`:
- Around line 892-905: Pre-commit is failing because the diff in the TODO block
that mentions the "savings-plans" -> "savingsplans" rename was not gofmt'ed; run
gofmt (or go fmt ./...) over the repository (or run the project's pre-commit
hooks) to normalize formatting, stage the resulting changes, and commit them so
the pre-commit gate passes and CI turns green; ensure the TODO comment block
containing "savings-plans" and "savingsplans" remains unchanged semantically.
🪄 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: defaults
Review profile: CHILL
Plan: Pro
Run ID: eb13dbc4-6574-4c07-9fd7-4843ce8604cc
📒 Files selected for processing (2)
internal/purchase/execution.gopkg/common/service_details_codec.go
|
@coderabbitai review |
✅ Action performedReview finished.
|
|
@coderabbitai review |
✅ Action performedReview finished.
|
|
@coderabbitai review |
✅ Action performedReview finished.
|
|
@coderabbitai full review |
✅ Action performedFull review finished. |
|
@coderabbitai full review |
✅ Action performedFull review finished. |
|
@coderabbitai review |
✅ Action performedReview finished.
|
|
@coderabbitai review |
✅ Action performedReview finished.
|
|
@coderabbitai review |
✅ Action performedReview finished.
|
|
@coderabbitai review |
✅ Action performedReview finished.
|
…o 2026-10-30 PR #94 (merged 2026-04-30) renamed the "savings-plans" slug to "savingsplans". The ~6-month purchase_executions retention window means the "savings-plans" alias in mapSavingsPlansSlug and newDetailsForService cannot be dropped until 2026-10-30 at earliest. Update both TODO comments to reference #95, record the PR #94 merge date, state the earliest safe drop date, and include the full removal checklist (DB verification query, exact files/lines, test flip). The alias itself is unchanged. Closes #95
CodeRabbit flagged the failing go-fmt pre-commit gate on this PR: the SQL verification snippet added to the mapSavingsPlansSlug TODO used space-indented comment lines, which gofmt normalizes to a tab-indented code block delimited by blank comment lines. Run gofmt -w on internal/purchase/execution.go; the TODO content (query, dates, removal checklist) is semantically unchanged.
Fix British spellings flagged by golangci-lint misspell in the two files touched by the #95 TODO-update commit: execution.go and service_details_codec.go. Changes are comment-only. behaviour -> behavior, recognise/normalise/honour -> recognize/normalize/honor
Summary
purchase_executionsretention window is ~6 months, so the"savings-plans"legacy alias cannot be safely dropped until 2026-10-30 at earliest.TODO(#85)->TODO(#95)inmapSavingsPlansSlug(execution.go) andnewDetailsForService(service_details_codec.go) with: the PR chore(common): normalize Savings Plans identifier to "savingsplans" (frontend canonical) #94 merge date, the earliest safe drop date, the exact DB verification query, and the full removal checklist (exact lines in both files + the test flip).DB check outcome
Direct psql access was not available in the implementation environment. The date evidence is conclusive: 22 days elapsed vs a 6-month window -- production rows almost certainly still carry
"service":"savings-plans"in JSONB. Alias drop deferred.Verification query for whoever picks up #95 in October:
Zero rows -> safe to drop. Any rows -> defer further.
Test plan
go build ./...passesgo test ./internal/purchase/...-- 189 passedgo test github.com/LeanerCloud/CUDly/pkg/common/...-- 172 passedTestMapServiceType_AllBranchesandTestDecodeServiceDetailsFor_LegacyDashFormSPstill pass (alias unchanged)Summary by CodeRabbit
"savings-plans"as a legacy decoding alias for backward compatibility.