fix: accept latest sentinel report option (#930)

Co-authored-by: Codex <codex@noreply.local>
This commit is contained in:
Lyon
2026-06-26 08:28:26 +08:00
committed by GitHub
parent b54a95285b
commit 078bc61b0a
3 changed files with 11 additions and 6 deletions
+2 -1
View File
@@ -75,6 +75,7 @@ export type WebProbeSentinelOptions =
readonly lane: string;
readonly view: WebProbeSentinelReportView;
readonly runId: string | null;
readonly latest: boolean;
readonly traceId: string | null;
readonly sampleSeq: number | null;
readonly raw: boolean;
@@ -1270,7 +1271,7 @@ function runSentinelValidate(state: SentinelCicdState, options: Extract<WebProbe
}
function runSentinelReport(state: SentinelCicdState, options: Extract<WebProbeSentinelOptions, { kind: "report" }>): RenderedCliResult {
const command = `hwlab nodes web-probe sentinel report --view ${options.view}`;
const command = `hwlab nodes web-probe sentinel report ${options.latest ? "--latest " : ""}--view ${options.view}`;
const query = new URLSearchParams({ view: options.view });
if (options.runId !== null) query.set("run", options.runId);
if (options.traceId !== null) query.set("traceId", options.traceId);