Compare commits

..
Author SHA1 Message Date
skylartaylor 1872d0e52f nightly-tests: read quoted flow keys, and state the signer-environment prerequisite
The trust-closure flow-mapping reader split its masked copy, so a quoted key (`{"environment":
release}`, `{'uses': ...}`) became `''` and the scan accepted a route it must refuse. It now splits
the original bracket-free mapping and keeps the mask only for the shape check. New cases cover a
double- and single-quoted `environment` key, a quoted `uses` key, and a harmless quoted key that
must still be read rather than masked.

The activation notes and the signer caller said the `release` environment already trusts
`nightly-signer`. It admits only `release` today, so both now state that the environment must
admit `nightly-signer` before the first dispatch.
2026-11-26 03:02:44 +01:00
skylartaylor a44003437e nightly: re-pin the shared workflow to the exact-analysis admission
craft-common-actions main is now `be00e5ccd18b68e950c8a08532f2230e7c3d0cba`: #371 admits a
candidate on the built commit's own Sonar analysis instead of main's latest, after #370 (the
Windows and macOS registry rows) and #369 (helper checkouts kept out of the clean-source check,
macOS on `macos-15`), which follow #364 and #363.

Both callers name it in `uses` and `tooling-revision`, the policy names it as
`producer_tooling_revision`, `signer_tooling_revision` and `producer_workflow_ref`, and the
activation notes record what the pin is.

Checked at that commit: the candidate `contract()` for this policy (its rules are unchanged by
#371), `nightly_app.admit` on `main` and on `nightly-signer`, all three platform targets with their
release-ref plug-ins and entrypoints, and this app's packaging suites.
2026-11-26 02:14:35 +01:00
skylartaylor f2e86e6c1d nightly: re-pin the shared workflow to the Windows and macOS registry rows
craft-common-actions main is now `fc7124a1defa96813aee060031dc8b4d2afa3652`: #370 admits this
app's Windows and macOS nightly registry rows, on top of #369 (shared helper checkouts kept out of
the app's clean-source check, and macOS on `macos-15`), which follows #364 and #363.

Both callers name it in `uses` and `tooling-revision`, the policy names it as
`producer_tooling_revision`, `signer_tooling_revision` and `producer_workflow_ref`, and the
activation notes record what the pin is.

Checked at that commit: the candidate `contract()` for this policy, `nightly_app.admit` on `main`
and on `nightly-signer`, all three platform targets with their release-ref plug-ins and
entrypoints, and this app's packaging suites.
2026-11-26 00:58:01 +01:00
skylartaylor 41fd0047a2 nightly-tests: check the Sonar gate shape the candidate contract admits
`packaging/nightly-release-tests.py` gains test_sonar_policy_keeps_the_shared_candidate_contract,
which mirrors the Sonar rules the pinned candidate contract() applies - non-empty issue scope,
accepted failures one-to-one with the issue types, one condition per gate metric, all six live gate
conditions, the reviewed A threshold and the A..E bound - so this tree refuses the shape before a
nightly run reaches admission.
2026-11-26 00:20:10 +01:00
skylartaylor a6d24037ad Switch on supervised nightlies on the nightly-signer branch 2026-11-25 23:48:39 +01:00
+1 -23
View File
@@ -253,20 +253,12 @@ fn initialize_nightly_process_identity() -> Result<(), process_identity::Identit
)
}
/// Whether a refusal may also open a native message box. Standard error always carries the reason;
/// this only adds a box where one renders without the app's event loop. Never on macOS: rfd's alert
/// there needs the AppKit run loop this start has not reached, so a refused nightly launch hung in
/// an invisible modal instead of exiting (GridCraft Mac smoke, 2026-11-26).
fn refusal_dialog(flavor: build_flavor::BuildFlavor, desktop_session: bool, macos: bool) -> bool {
build_flavor::needs_native_error(flavor, desktop_session) && !macos
}
fn report_launch_profile_error(error: &str) {
eprintln!("DeckCraft launch profile: {error}");
let desktop_session = cfg!(windows)
|| cfg!(target_os = "macos")
|| (cfg!(target_os = "linux") && ["DISPLAY", "WAYLAND_DISPLAY"].into_iter().any(|key| std::env::var_os(key).is_some_and(|v| !v.is_empty())));
if refusal_dialog(build_flavor::COMPILED, desktop_session, cfg!(target_os = "macos")) {
if build_flavor::needs_native_error(build_flavor::COMPILED, desktop_session) {
if let Err(error) = initialize_nightly_process_identity() {
eprintln!("DeckCraft launch profile: {error}");
return;
@@ -680,17 +672,3 @@ mod tests {
assert!(script.contains("has no embedded icon"), "package.ps1 does not reject an iconless exe");
}
}
#[cfg(test)]
mod refusal_dialog_tests {
use super::refusal_dialog;
use crate::build_flavor::BuildFlavor;
#[test]
fn a_refusal_never_blocks_on_a_modal_before_the_event_loop_on_macos() {
assert!(refusal_dialog(BuildFlavor::NightlyV1, true, false), "a desktop refusal still shows the box where one renders");
assert!(!refusal_dialog(BuildFlavor::NightlyV1, true, true), "macOS has no run loop yet: the modal would hang");
assert!(!refusal_dialog(BuildFlavor::NightlyV1, false, false), "a headless session has no box");
assert!(!refusal_dialog(BuildFlavor::Stable, true, false), "only a nightly refusal explains itself in a box");
}
}