Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 7 additions & 11 deletions .trinity/seals/pr_TriPrPreflight.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"built_by": "t27c-bootstrap@0.5.2+92178c87d",
"built_by": "t27c-bootstrap@0.5.2+fdb6b28dd",
"closure": [
{
"spec": "specs/tri/lab/receipt.t27",
Expand All @@ -8,23 +8,19 @@
{
"spec": "specs/tri/lanes/lanes.t27",
"spec_hash": "sha256:aac192b3e3250196262a9b8467d4a9cef8147438c11c0744c66c3f6b175c9342"
},
{
"spec": "specs/tri/test/report.t27",
"spec_hash": "sha256:2e781b2dc9d841f0c6482e06a328ac2c27a1c74bad71d847c283cf9111c62bd0"
}
],
"config": "gen=c,rust,verilog,zig;tests=zig",
"gen_hash_c": "sha256:7b7bf4ca8d5e47943caa50b0805120c3494f07c2def750b9ced0d32597f1f00e",
"gen_hash_rust": "sha256:cc34d39493212eb6a1870556548d441da543a39a41ad46bd671aa648bbe59315",
"gen_hash_verilog": "sha256:b9d4a072e31fe481d785ae6e3bf20314f53142d608a3be8ffbc2e359fd636d4a",
"gen_hash_zig": "sha256:734d6444989a3578d5da324f134d377be1940fa14f2e93147a89f76a911681e2",
"gen_hash_c": "sha256:d85f440682c707fd126ed726dc9a8c3713f33fa67528953a532a9eb40da55b81",
"gen_hash_rust": "sha256:d945336cc8dded5d2368a118984c549c629b7428fcd054089b7db46cfaa4ced2",
"gen_hash_verilog": "sha256:68f5baedb845f39d78c0aed0c6100be3574cd1d7a3bccd09b9e1d9042e589850",
"gen_hash_zig": "sha256:bf8cabe6e83216400e8702e979de7cd26cb4bfd5919a7f6fc557ca621092709a",
"module": "TriPrPreflight",
"ring": 12,
"seal_schema": 2,
"sealed_at": "2026-10-18T04:31:44Z",
"sealed_at": "2026-10-18T05:09:07Z",
"sealed_by": "t27c-bootstrap@0.5.2",
"spec_hash": "sha256:0a1effb20e59df9703bbf36290078e60108b44506f32725176f61613e7975b95",
"spec_hash": "sha256:24634647a1245ac9d776735bd4323f524d71f7c52f0928ce31066a114b68f409",
"spec_path": "specs/tri/pr/preflight.t27",
"tests": {
"failed": 0,
Expand Down
5 changes: 5 additions & 0 deletions docs/reports/t27b_expectations.json
Original file line number Diff line number Diff line change
Expand Up @@ -171,6 +171,7 @@
{"path": "specs/ci/gates/documented_commands.t27", "t27b": "pass"},
{"path": "specs/ci/gates/verilog_widths.t27", "t27b": "pass"},
{"path": "specs/ci/schema.t27", "t27b": "pass"},
{"path": "specs/ci/suite_ledger_steward.t27", "t27b": "pass"},
{"path": "specs/claw/engine.t27", "t27b": "pass"},
{"path": "specs/claw/gates.t27", "t27b": "pass"},
{"path": "specs/claw/gates_pins.t27", "t27b": "pass"},
Expand Down Expand Up @@ -423,6 +424,7 @@
{"path": "specs/isa/tri27_machine.t27", "t27b": "pass"},
{"path": "specs/jobs/network_job.t27", "t27b": "pass"},
{"path": "specs/jobs/release_t27c.t27", "t27b": "pass"},
{"path": "specs/jobs/suite_ledger_steward.t27", "t27b": "pass"},
{"path": "specs/jobs/t27b_ledger_steward.t27", "t27b": "pass"},
{"path": "specs/math/constants.t27", "t27b": "pass"},
{"path": "specs/math/gf_competitive.t27", "t27b": "pass"},
Expand Down Expand Up @@ -1327,13 +1329,15 @@
{"path": "specs/skills/trinity-wave.t27", "t27b": "pass"},
{"path": "specs/system/unified-agent-operations.t27", "t27b": "pass"},
{"path": "specs/t27f/deck.t27", "t27b": "pass"},
{"path": "specs/t27f/hot.t27", "t27b": "pass"},
{"path": "specs/t27f/quest.t27", "t27b": "pass"},
{"path": "specs/t27f/reel.t27", "t27b": "pass"},
{"path": "specs/t27f/reel_gf16_nmse.t27", "t27b": "pass"},
{"path": "specs/t27f/reel_t27_basics.t27", "t27b": "pass"},
{"path": "specs/t27f/spec_graph.t27", "t27b": "pass"},
{"path": "specs/t27f/spec_graph_derive.t27", "t27b": "pass"},
{"path": "specs/t27f/spec_graph_export.t27", "t27b": "pass"},
{"path": "specs/t27f/spec_graph_fold.t27", "t27b": "pass"},
{"path": "specs/t27f/spec_graph_outline.t27", "t27b": "pass"},
{"path": "specs/t27f/spec_graph_view.t27", "t27b": "pass"},
{"path": "specs/t27f/topic_engine.t27", "t27b": "pass"},
Expand Down Expand Up @@ -1532,6 +1536,7 @@
{"path": "specs/tri/pipeline/codegen.t27", "t27b": "pass"},
{"path": "specs/tri/pipeline/spec_writer.t27", "t27b": "pass"},
{"path": "specs/tri/pipeline/workflow.t27", "t27b": "pass"},
{"path": "specs/tri/pr/preflight.t27", "t27b": "pass"},
{"path": "specs/tri/reseal/seal.t27", "t27b": "pass"},
{"path": "specs/tri/search/pattern.t27", "t27b": "pass"},
{"path": "specs/tri/sort/insertion_sort.t27", "t27b": "pass"},
Expand Down
30 changes: 10 additions & 20 deletions gen/rust/tri/pr/preflight.rs
Original file line number Diff line number Diff line change
Expand Up @@ -146,6 +146,16 @@ pub fn step_runs(k: u8, quick: bool) -> bool {
return ((k < STEPS) && ((k != STEP_SUITE) || (quick == false)));
}

pub fn opens_with(text: &'static str, at: usize, end: usize, lit: &'static str) -> bool {
if (at > end) {
return false;
}
if (lit.len() > (end - at)) {
return false;
}
return span_is(text, at, (at + lit.len()), lit);
}

pub fn entry_at(c: &'static str, n: u64) -> usize {
let mut at: usize = 0;
let mut seen: u64 = 0;
Expand Down Expand Up @@ -998,26 +1008,6 @@ pub fn digits(text: &'static str, from: usize, to: usize) -> u64 {
return n;
}

pub const V_GREEN: u8 = 0;

pub fn opens_with(text: &'static str, at: usize, end: usize, lit: &'static str) -> bool {
if ((at > end) || (lit.len() > (end - at))) {
return false;
}
let mut k: usize = 0;
while (k < lit.len()) {
if (text.as_bytes()[((at + k)) as usize] != lit.as_bytes()[(k) as usize]) {
return false;
}
k = (k + 1);
}
return true;
}

pub fn passes(v: u8) -> bool {
return (v == V_GREEN);
}

pub const FAIL: u8 = 1;

pub const PASS: u8 = 0;
Expand Down
9 changes: 8 additions & 1 deletion specs/tri/pr/preflight.t27
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@ module TriPrPreflight;

use tri::lab::receipt::line_end;
use tri::lab::receipt::span_is;
use tri::test::report::opens_with;
use tri::lanes::lanes::digits;

// The steps, in the order they run. Every per-target step runs after CHANGES, which names the targets.
Expand Down Expand Up @@ -122,6 +121,14 @@ pub fn step_runs(k: u8, quick: bool) -> bool {
return k < STEPS and (k != STEP_SUITE or quick == false);
}

/// Does the line text[at..end] start with lit? Built on receipt's span_is: a `use` path through
/// tri::test stops at the keyword `test`, and the parser drops the rest of the line (parse-no-discard).
fn opens_with(text: string, at: usize, end: usize, lit: string) -> bool {
if (at > end) { return false; }
if (lit.len > end - at) { return false; }
return span_is(text, at, at + lit.len, lit);
}

// ---- the CHANGES output: one `<status>\t<path>` line per changed file -------------------------

/// The offset of the n-th non-empty line (from 0), or c.len when there are fewer.
Expand Down
Loading