-
Notifications
You must be signed in to change notification settings - Fork 30
Release v1.7.1 — render benefit % and actionable fix #248
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 all commits
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 |
|---|---|---|
|
|
@@ -187,6 +187,7 @@ .card h3 { | |
| .warn-type { font-size: 0.75rem; font-weight: 600; } | ||
| .warn-benefit { font-size: 0.7rem; font-weight: 600; color: var(--text-muted); padding: 0.05rem 0.3rem; border-radius: 3px; background: rgba(0,0,0,0.04); } | ||
| .warn-msg { font-size: 0.8rem; color: var(--text); flex-basis: 100%; } | ||
| .warn-fix { font-size: 0.75rem; color: var(--text-secondary); font-style: italic; flex-basis: 100%; border-left: 2px solid var(--border); padding-left: 0.5rem; margin-top: 0.15rem; } | ||
|
|
||
| /* Query text */ | ||
| details { margin-bottom: 0.75rem; } | ||
|
|
@@ -459,6 +460,8 @@ private static void WriteWarnings(StringBuilder sb, StatementResult stmt) | |
| if (w.MaxBenefitPercent.HasValue) | ||
| sb.AppendLine($"<span class=\"warn-benefit\">up to {w.MaxBenefitPercent:N0}% benefit</span>"); | ||
| sb.AppendLine($"<span class=\"warn-msg\">{Encode(w.Message)}</span>"); | ||
| if (!string.IsNullOrEmpty(w.ActionableFix)) | ||
| sb.AppendLine($"<span class=\"warn-fix\">{Encode(w.ActionableFix)}</span>"); | ||
|
Owner
Author
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. New Generated by Claude Code |
||
| sb.AppendLine("</div>"); | ||
| } | ||
| sb.AppendLine("</div>"); | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -172,6 +172,8 @@ public static void WriteText(AnalysisResult result, TextWriter writer) | |
| ? $" (up to {w.MaxBenefitPercent:N0}% benefit)" | ||
| : ""; | ||
| writer.WriteLine($" [{w.Severity}] {w.Type}{benefitTag}: {EscapeNewlines(w.Message)}"); | ||
| if (!string.IsNullOrEmpty(w.ActionableFix)) | ||
| writer.WriteLine($" Fix: {EscapeNewlines(w.ActionableFix)}"); | ||
|
Owner
Author
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. Same gap on the text side — no test in Generated by Claude Code |
||
| } | ||
| } | ||
|
|
||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -332,7 +332,10 @@ else | |
| @if (infoCount > 0) { <span class="warn-count-badge info">@infoCount</span> } | ||
| </h4> | ||
| <div class="warnings-list"> | ||
| @foreach (var w in GetAllWarnings(ActiveStmt!)) | ||
| @foreach (var w in GetAllWarnings(ActiveStmt!) | ||
| .OrderByDescending(x => x.MaxBenefitPercent ?? -1) | ||
| .ThenByDescending(x => x.Severity == "Critical" ? 3 : x.Severity == "Warning" ? 2 : 1) | ||
| .ThenBy(x => x.Type)) | ||
|
Comment on lines
+335
to
+338
Owner
Author
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. Ordering here mirrors Generated by Claude Code |
||
| { | ||
| <div class="warning @w.Severity.ToLower()"> | ||
| <span class="severity">@w.Severity</span> | ||
|
|
@@ -341,7 +344,15 @@ else | |
| <span class="warning-op">@w.Operator</span> | ||
| } | ||
| <span class="warning-type">@w.Type</span> | ||
| @if (w.MaxBenefitPercent.HasValue) | ||
| { | ||
| <span class="warn-benefit">up to @w.MaxBenefitPercent.Value.ToString("N0")% benefit</span> | ||
| } | ||
| <span class="warning-msg">@w.Message</span> | ||
| @if (!string.IsNullOrEmpty(w.ActionableFix)) | ||
| { | ||
| <span class="warning-fix">@w.ActionableFix</span> | ||
| } | ||
| </div> | ||
| } | ||
| </div> | ||
|
|
||
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.
Idempotency check:
gh release upload ... --clobber(line 184) andvpk upload ... --merge(line 187) handle re-runs against an existing release, so dropping theEXISTS == 'false'guards on the build/sign/package steps is safe from a failure-mode standpoint. The trade-off is that every re-run now submits a fresh SignPath signing request and a full Velopack pack — intentional for the "partial failure on the first run" recovery case, just flagging the cost side for awareness.Generated by Claude Code