Skip to content

Commit 2282e4c

Browse files
Require explicit self-hosted soak provenance
1 parent 8b76ac5 commit 2282e4c

3 files changed

Lines changed: 6 additions & 3 deletions

File tree

docs/bounded-growth.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -115,8 +115,8 @@ alerting.
115115
`trusted_long_soak_v1` profile. Short CI smokes can still pass, but they are
116116
classified as ineligible for the issue-closing trusted evidence unless they run
117117
for at least one hour, use compose-backed resource sampling, run on a
118-
self-hosted runner when GitHub exposes the runner environment, meet sample
119-
coverage, and have no bounded-growth assertion failures.
118+
self-hosted runner with an explicit `RUNNER_ENVIRONMENT=self-hosted` provenance
119+
value, meet sample coverage, and have no bounded-growth assertion failures.
120120

121121
Per-policy limits can be enforced with JSON maps keyed by policy ID:
122122
`DW_PERF_MAX_SERVER_CACHE_KEYS_BY_POLICY` for maximum observed keys and

scripts/perf/server_soak.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -678,7 +678,9 @@ def evidence_trust_profile(
678678
reasons.append(f"duration below trusted long-soak minimum {minimum_duration_seconds}s")
679679
if not compose_project:
680680
reasons.append("compose-backed resource sampling was not configured")
681-
if runner_environment and runner_environment != "self-hosted":
681+
if not runner_environment:
682+
reasons.append("runner environment is unknown")
683+
elif runner_environment != "self-hosted":
682684
reasons.append(f"runner environment is {runner_environment}, not self-hosted")
683685
if periodic_sample_count < minimum_trusted_samples:
684686
reasons.append("periodic sample coverage below trusted minimum")

tests/Unit/ServerPerfHarnessContractTest.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -50,6 +50,7 @@ public function test_soak_summary_records_trusted_evidence_fields(): void
5050
'minimum_duration_seconds',
5151
'requires_self_hosted_runner',
5252
'requires_compose_resource_sampling',
53+
'runner environment is unknown',
5354
'duration below trusted long-soak minimum',
5455
'bounded-growth assertions failed',
5556
] as $needle) {

0 commit comments

Comments
 (0)