Skip to content

Commit deca499

Browse files
authored
Release CLI v0.8.10 (#138)
Keeps the benchmark authority synchronized with the evaluator and fixture sources used at release time, so source drift fails during ordinary CI instead of after a tag is published. The established conservative quality metrics remain unchanged, and the package version advances to `v0.8.10`.
1 parent 0c67648 commit deca499

5 files changed

Lines changed: 24 additions & 4 deletions

File tree

Cargo.lock

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "postil-cli"
3-
version = "0.8.9"
3+
version = "0.8.10"
44
edition = "2024"
55
description = "Postil: a low-noise AI review gate. Silent on clean PRs, hard gate on real risk."
66
license = "Apache-2.0"

bench/baseline.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
"schemaVersion": 1,
33
"corpus": {
44
"fixtureCorpusSha256": "3c4f952f9411bf2c4e5f0a61b5975e47d203f7681a8235d53d717c743ea9cb54",
5-
"evaluatorSha256": "64dd1975bd5743e15b073b8c6dbad91e37cef3388f793073b216d002de80d78a"
5+
"evaluatorSha256": "b0d452b0c2f8d419ef6f4780791cde8cd760d318a82b439aa5746a226305e125"
66
},
77
"profiles": {
88
"z-ai/glm-5.2": {

bench/src/compare-baseline.test.ts

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,8 @@
11
import { describe, expect, test } from "bun:test";
2+
import { createHash } from "node:crypto";
3+
import { readFile } from "node:fs/promises";
4+
import { resolve } from "node:path";
5+
import { cases } from "../fixtures/cases";
26
import {
37
DETECTION_RATE_MAX_DROP_PP,
48
FALSE_FINDINGS_MAX_INCREASE,
@@ -12,6 +16,22 @@ import {
1216
type BaselineProfile,
1317
type LiveReportForComparison,
1418
} from "./compare-baseline";
19+
import { benchmarkCase } from "./harness";
20+
import { evaluatorSourceSha256 } from "./live";
21+
22+
test("committed baseline authority matches the current benchmark sources", async () => {
23+
const baseline = JSON.parse(
24+
await readFile(resolve(import.meta.dir, "..", "baseline.json"), "utf8"),
25+
) as {
26+
corpus: { fixtureCorpusSha256: string; evaluatorSha256: string };
27+
};
28+
const fixtureCorpusSha256 = createHash("sha256")
29+
.update(JSON.stringify(cases.map((input) => benchmarkCase.parse(input))))
30+
.digest("hex");
31+
32+
expect(baseline.corpus.fixtureCorpusSha256).toBe(fixtureCorpusSha256);
33+
expect(baseline.corpus.evaluatorSha256).toBe(await evaluatorSourceSha256());
34+
});
1535

1636
function fakeReport(overrides: {
1737
falsePositives?: number;

bench/src/live.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -380,7 +380,7 @@ async function screeningProfileMetadata(path: string): Promise<{
380380
};
381381
}
382382

383-
async function evaluatorSourceSha256(): Promise<string> {
383+
export async function evaluatorSourceSha256(): Promise<string> {
384384
const benchRoot = resolve(fileURLToPath(import.meta.url), "..", "..");
385385
const sources = [
386386
"fixtures/cases.ts",

0 commit comments

Comments
 (0)