fix: show version tag/name in Plans page breadcrumb instead of UUID#1051
fix: show version tag/name in Plans page breadcrumb instead of UUID#1051adityachoudhari26 merged 2 commits intomainfrom
Conversation
Closes #1037 Co-authored-by: Aditya Choudhari <adityachoudhari26@users.noreply.github.com>
|
Warning Rate limit exceeded
Your organization is not enrolled in usage-based pricing. Contact your admin to enable usage-based pricing to continue reviews beyond the rate limit, or try again in 34 minutes and 21 seconds. ⌛ How to resolve this issue?After the wait time has elapsed, a review can be triggered using the We recommend that you space out your commits to avoid hitting the rate limit. 🚦 How do rate limits work?CodeRabbit enforces hourly rate limits for each developer per organization. Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout. Please see our FAQ for further information. ℹ️ Review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (2)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|
|
There was a problem hiding this comment.
Pull request overview
Updates the Plans detail page breadcrumb to display a human-friendly deployment version identifier (tag/name) instead of the raw plan UUID by including version information in the deployment.plans.results tRPC response.
Changes:
- Extended
deployment.plans.resultsto return{ version, results }rather than only an array of results. - Updated the plan detail route to consume the new response shape and render
versionin the breadcrumb (with fallback toplanId).
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 3 comments.
| File | Description |
|---|---|
| packages/trpc/src/routes/deployment-plans.ts | Adds versionTag/versionName to the plan lookup and returns version info alongside the results list. |
| apps/web/app/routes/ws/deployments/page.$deploymentId.plans.$planId.tsx | Adapts to the new tRPC response shape and renders version label in the breadcrumb. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| <BreadcrumbPage className="font-mono"> | ||
| {version?.tag ?? version?.name ?? planId} | ||
| </BreadcrumbPage> |
There was a problem hiding this comment.
The breadcrumb label currently prefers version.tag over version.name. Issue #1037 (and other UI usages) indicate the opposite preference (show name when present, otherwise tag). Consider switching the order to version?.name ?? version?.tag ?? planId (or equivalent), so a friendly name is shown when available.
| }); | ||
| return { | ||
| version: { tag: plan.versionTag, name: plan.versionName }, | ||
| results: rows.map((r) => { |
There was a problem hiding this comment.
The tRPC procedure is named results and now returns an object with a results property, which forces consumers into ...results.results... and makes the API/type usage harder to read. Consider renaming the response field (e.g., items, rows, targets) or renaming the procedure so the output shape is less confusing.
| results: rows.map((r) => { | |
| items: rows.map((r) => { |
| type Result = | ||
| RouterOutputs["deployment"]["plans"]["results"]["results"][number]; |
There was a problem hiding this comment.
Minor readability/maintainability: RouterOutputs["deployment"]["plans"]["results"]["results"][number] is hard to scan. Consider introducing an intermediate alias for the full response type (e.g., type ResultsResponse = RouterOutputs[...]["results"];) and then deriving Result from ResultsResponse["results"][number].
| type Result = | |
| RouterOutputs["deployment"]["plans"]["results"]["results"][number]; | |
| type ResultsResponse = RouterOutputs["deployment"]["plans"]["results"]; | |
| type Result = ResultsResponse["results"][number]; |
Fixes #1037
The Plans page breadcrumb was showing the raw plan UUID instead of the version tag or name.
Changes:
resultstRPC procedure to include version info in the responseversion.tag ?? version.name ?? planIdGenerated with Claude Code