From ee7d5f4821c912dca2da727ac813ac01e20fb655 Mon Sep 17 00:00:00 2001 From: IchenDEV Date: Fri, 16 Oct 2026 15:23:10 +0800 Subject: [PATCH] test: synchronize model preparation responsiveness probe --- Sources/UtterModels/ModelGenerations.swift | 8 +- Sources/UtterModels/Native/ModelStorage.swift | 11 +- .../ModelPreparationResponsivenessTests.swift | 50 ++ Tests/OpenTypeTests/UtilityTests.swift | 55 +- .../evidence/release-v0054-first-failure.json | 22 + .../evidence/release-v0054-preflight.json | 14 + .../release.md | 72 ++ .../evidence/cache-preservation.json | 12 + .../first-failures-and-resolution.json | 18 + .../evidence/frozen-products.json | 17 + .../evidence/independent-local-review.json | 124 +++ .../evidence/local-commands.json | 150 ++++ .../evidence/local-packaging.json | 13 + .../evidence/mutation.json | 70 ++ .../evidence/native-suite.json | 749 ++++++++++++++++++ .../evidence/privacy-canaries.json | 14 + .../protected-swift-test-complete-audit.json | 15 + .../evidence/public-disclosure-audit.json | 7 + .../intent.md | 69 ++ .../plan.md | 29 + .../spec.md | 31 + .../verification.md | 64 ++ 22 files changed, 1557 insertions(+), 57 deletions(-) create mode 100644 Tests/OpenTypeTests/ModelPreparationResponsivenessTests.swift create mode 100644 docs/sdlc/changes/2026-10-16-dmg-developer-id-signing/evidence/release-v0054-first-failure.json create mode 100644 docs/sdlc/changes/2026-10-16-dmg-developer-id-signing/evidence/release-v0054-preflight.json create mode 100644 docs/sdlc/changes/2026-10-16-dmg-developer-id-signing/release.md create mode 100644 docs/sdlc/changes/2026-10-16-preparation-responsiveness-test/evidence/cache-preservation.json create mode 100644 docs/sdlc/changes/2026-10-16-preparation-responsiveness-test/evidence/first-failures-and-resolution.json create mode 100644 docs/sdlc/changes/2026-10-16-preparation-responsiveness-test/evidence/frozen-products.json create mode 100644 docs/sdlc/changes/2026-10-16-preparation-responsiveness-test/evidence/independent-local-review.json create mode 100644 docs/sdlc/changes/2026-10-16-preparation-responsiveness-test/evidence/local-commands.json create mode 100644 docs/sdlc/changes/2026-10-16-preparation-responsiveness-test/evidence/local-packaging.json create mode 100644 docs/sdlc/changes/2026-10-16-preparation-responsiveness-test/evidence/mutation.json create mode 100644 docs/sdlc/changes/2026-10-16-preparation-responsiveness-test/evidence/native-suite.json create mode 100644 docs/sdlc/changes/2026-10-16-preparation-responsiveness-test/evidence/privacy-canaries.json create mode 100644 docs/sdlc/changes/2026-10-16-preparation-responsiveness-test/evidence/protected-swift-test-complete-audit.json create mode 100644 docs/sdlc/changes/2026-10-16-preparation-responsiveness-test/evidence/public-disclosure-audit.json create mode 100644 docs/sdlc/changes/2026-10-16-preparation-responsiveness-test/intent.md create mode 100644 docs/sdlc/changes/2026-10-16-preparation-responsiveness-test/plan.md create mode 100644 docs/sdlc/changes/2026-10-16-preparation-responsiveness-test/spec.md create mode 100644 docs/sdlc/changes/2026-10-16-preparation-responsiveness-test/verification.md diff --git a/Sources/UtterModels/ModelGenerations.swift b/Sources/UtterModels/ModelGenerations.swift index e301bd17..469b6aaa 100644 --- a/Sources/UtterModels/ModelGenerations.swift +++ b/Sources/UtterModels/ModelGenerations.swift @@ -58,10 +58,14 @@ package enum ModelGenerations { } package static func prepareOffMainActor( - source: URL, destination: URL, storageRoot: URL + source: URL, destination: URL, storageRoot: URL, + onEnter: (@Sendable () -> Void)? = nil, + onExit: (@Sendable () -> Void)? = nil ) async throws -> PreparedModelGeneration { try await Task.detached { - try prepare( + onEnter?() + defer { onExit?() } + return try prepare( source: source, destination: destination, storageRoot: storageRoot ) }.value diff --git a/Sources/UtterModels/Native/ModelStorage.swift b/Sources/UtterModels/Native/ModelStorage.swift index f03f2e6d..de169bed 100644 --- a/Sources/UtterModels/Native/ModelStorage.swift +++ b/Sources/UtterModels/Native/ModelStorage.swift @@ -149,14 +149,21 @@ package enum ModelStorage { /// Performs preparation on a detached task so the MainActor remains /// responsive while large model trees are copied and symlinks resolved. - package static func prepareGenerationCommitOffMainActor(kind: ModelDownloadKind, modelID: String, staging: ModelDownloadStaging) async throws -> PreparedModelGeneration { + package static func prepareGenerationCommitOffMainActor( + kind: ModelDownloadKind, modelID: String, staging: ModelDownloadStaging, + onEnter: (@Sendable () -> Void)? = nil, + onExit: (@Sendable () -> Void)? = nil + ) async throws -> PreparedModelGeneration { let source = kind == .whisper ? whisperVariantDir(modelID, downloadBase: staging.downloadBase) : hubModelRepoDir(modelID, downloadBase: staging.downloadBase) let destination = kind == .whisper ? whisperVariantDir(modelID, downloadBase: staging.storageRoot) : hubModelRepoDir(modelID, downloadBase: staging.storageRoot) - return try await ModelGenerations.prepareOffMainActor(source: source, destination: destination, storageRoot: staging.storageRoot) + return try await ModelGenerations.prepareOffMainActor( + source: source, destination: destination, storageRoot: staging.storageRoot, + onEnter: onEnter, onExit: onExit + ) } /// Retires an unpublished candidate and any rollback backup. The source diff --git a/Tests/OpenTypeTests/ModelPreparationResponsivenessTests.swift b/Tests/OpenTypeTests/ModelPreparationResponsivenessTests.swift new file mode 100644 index 00000000..f036211d --- /dev/null +++ b/Tests/OpenTypeTests/ModelPreparationResponsivenessTests.swift @@ -0,0 +1,50 @@ +import Foundation +import XCTest +@testable import UtterModels + +final class ModelPreparationResponsivenessTests: XCTestCase { + @MainActor + func testGenerationPreparationKeepsMainActorResponsive() async throws { + let root = FileManager.default.temporaryDirectory + .appendingPathComponent("OpenTypePreparationResponsiveness-\(UUID().uuidString)") + defer { try? FileManager.default.removeItem(at: root) } + let staging = ModelStorage.generationStaging(for: UUID(), storageRoot: root) + try ModelStorage.prepareGeneration(staging) + let source = ModelStorage.hubModelRepoDir("org/model", downloadBase: staging.downloadBase) + try FileManager.default.createDirectory(at: source, withIntermediateDirectories: true) + try Data("{}".utf8).write(to: source.appendingPathComponent("config.json")) + let weights = Data("preparation fixture".utf8) + try weights.write(to: source.appendingPathComponent("weights.safetensors")) + + let gate = BackgroundWorkGate() + let watchdog = Task.detached { + try? await Task.sleep(nanoseconds: 5_000_000_000) + gate.release() + } + defer { + gate.release() + watchdog.cancel() + } + let preparation = Task { @MainActor in + try await ModelStorage.prepareGenerationCommitOffMainActor( + kind: .llm, modelID: "org/model", staging: staging, + onEnter: { gate.enterAndWait() }, onExit: { gate.exit() } + ) + } + let deadline = Date().addingTimeInterval(3) + while !gate.snapshot().entered && Date() < deadline { + try? await Task.sleep(nanoseconds: 1_000_000) + } + let observed = gate.snapshot() + gate.release() + let prepared = try await preparation.value + let copiedWeights = try Data(contentsOf: prepared.candidate.appendingPathComponent("weights.safetensors")) + await ModelStorage.discardPreparedGenerationOffMainActor(prepared) + + XCTAssertTrue(observed.entered, "Preparation must enter its worker barrier") + XCTAssertFalse(observed.exited, "MainActor must respond between worker entry and exit") + XCTAssertTrue(gate.snapshot().exited) + XCTAssertEqual(copiedWeights, weights) + XCTAssertFalse(FileManager.default.fileExists(atPath: prepared.candidate.path)) + } +} diff --git a/Tests/OpenTypeTests/UtilityTests.swift b/Tests/OpenTypeTests/UtilityTests.swift index 1e727ad4..9c875aa8 100644 --- a/Tests/OpenTypeTests/UtilityTests.swift +++ b/Tests/OpenTypeTests/UtilityTests.swift @@ -18,7 +18,7 @@ import Foundation import XCTest @testable import UtterPresentation -private final class StartupCleanupGate: @unchecked Sendable { +final class BackgroundWorkGate: @unchecked Sendable { private let lock = NSLock() private let releaseSignal = DispatchSemaphore(value: 0) private var entered = false @@ -161,7 +161,7 @@ final class UtilityTests: XCTestCase { ) } - let gate = StartupCleanupGate() + let gate = BackgroundWorkGate() var factoryCalls = 0 let catalog = ModelCatalog( startupStorageRoot: root, @@ -220,57 +220,6 @@ final class UtilityTests: XCTestCase { XCTAssertFalse(FileManager.default.fileExists(atPath: staging.root.path)) } - @MainActor - func testGenerationPreparationKeepsMainActorResponsive() async throws { - let root = FileManager.default.temporaryDirectory - .appendingPathComponent("OpenTypePreparationResponsiveness-\(UUID().uuidString)", isDirectory: true) - defer { try? FileManager.default.removeItem(at: root) } - - let staging = ModelStorage.generationStaging(for: UUID(), storageRoot: root) - try ModelStorage.prepareGeneration(staging) - let stagedRepo = ModelStorage.hubModelRepoDir( - "org/model", - downloadBase: staging.downloadBase - ) - try FileManager.default.createDirectory(at: stagedRepo, withIntermediateDirectories: true) - try Data("{}".utf8).write(to: stagedRepo.appendingPathComponent("config.json")) - try Data(repeating: 7, count: 16_000_000).write( - to: stagedRepo.appendingPathComponent("weights.safetensors") - ) - - var heartbeats = 0 - var preparationFinished = false - let preparation = Task { @MainActor in - do { - let prepared = try await ModelStorage.prepareGenerationCommitOffMainActor( - kind: .llm, - modelID: "org/model", - staging: staging - ) - preparationFinished = true - return prepared - } catch { - preparationFinished = true - throw error - } - } - // Let the preparation task reach its detached await before starting - // the probe. A synchronous MainActor copy would keep this probe from - // running until preparationFinished became true. - await Task.yield() - let heartbeat = Task { @MainActor in - while !preparationFinished { - heartbeats += 1 - await Task.yield() - } - } - let prepared = try await preparation.value - await heartbeat.value - ModelStorage.discardPreparedGeneration(prepared) - - XCTAssertGreaterThan(heartbeats, 0, "MainActor should service work while preparation copies files") - } - @MainActor func testGenerationCleanupKeepsMainActorResponsive() async throws { let root = FileManager.default.temporaryDirectory diff --git a/docs/sdlc/changes/2026-10-16-dmg-developer-id-signing/evidence/release-v0054-first-failure.json b/docs/sdlc/changes/2026-10-16-dmg-developer-id-signing/evidence/release-v0054-first-failure.json new file mode 100644 index 00000000..be063e76 --- /dev/null +++ b/docs/sdlc/changes/2026-10-16-dmg-developer-id-signing/evidence/release-v0054-first-failure.json @@ -0,0 +1,22 @@ +{ + "run_id": 38861433092, + "run_attempt": 1, + "candidate_job": 116844377402, + "head_sha": "8d1134ce664fa4dd878389529cf1bf41721af53a", + "tag": "v0.0.54", + "conclusion": "failure", + "xctest_executed": 1143, + "skipped": 18, + "failures": 1, + "swift_testing_passed": 1, + "failed_test": "UtilityTests.testGenerationPreparationKeepsMainActorResponsive", + "path": "Tests/OpenTypeTests/UtilityTests.swift", + "line": 271, + "diagnostic": "XCTAssertGreaterThan: heartbeats=0; expected MainActor work while preparation copies files", + "raw_log_sha256": "367489cfd80d7881c9b5abb652dc0e65b674437c4178e65dff5ecfa1aa79535c", + "raw_log_kept_privately": true, + "production_job": "skipped", + "production_approvals": [], + "notarization_or_publication_executed": false, + "retry_performed": false +} diff --git a/docs/sdlc/changes/2026-10-16-dmg-developer-id-signing/evidence/release-v0054-preflight.json b/docs/sdlc/changes/2026-10-16-dmg-developer-id-signing/evidence/release-v0054-preflight.json new file mode 100644 index 00000000..480bb8cc --- /dev/null +++ b/docs/sdlc/changes/2026-10-16-dmg-developer-id-signing/evidence/release-v0054-preflight.json @@ -0,0 +1,14 @@ +{ + "recorded_at_utc": "2026-10-16T06:28:43.772229+00:00", + "version": "0.0.54", + "commit": "8d1134ce664fa4dd878389529cf1bf41721af53a", + "main_protected": true, + "main_run": 38860187195, + "main_ci_conclusion": "success", + "tag_and_release_unused": true, + "failed_v0053_tag_unchanged": true, + "production_human_review_required": true, + "production_admin_bypass": false, + "local_main_clean": true, + "new_production_approved": false +} diff --git a/docs/sdlc/changes/2026-10-16-dmg-developer-id-signing/release.md b/docs/sdlc/changes/2026-10-16-dmg-developer-id-signing/release.md new file mode 100644 index 00000000..8c57dfda --- /dev/null +++ b/docs/sdlc/changes/2026-10-16-dmg-developer-id-signing/release.md @@ -0,0 +1,72 @@ +# Release: Utter v0.0.54 + +**Status:** blocked +**Approved-by:** — +**Approved-date:** — +**Upstream:** [Verification](verification.md) + +## Candidate + +- Version: `v0.0.54`. +- Protected main commit: `8d1134ce664fa4dd878389529cf1bf41721af53a`. +- Annotated tag object: `3ad41f65abb1958f937c7b406bb0aedfdee3dd36`. +- [Merged corrective PR #125](https://github.com/IchenDEV/utter/pull/125). +- [Exact-main CI](https://github.com/IchenDEV/utter/actions/runs/38860187195) + passed repository checks, full tests, release-style packaging, and SDLC Gate. +- [Release run 38861433092](https://github.com/IchenDEV/utter/actions/runs/38861433092) + failed its complete candidate tests. Production was skipped, with no approval. + +The candidate completed 1,143 XCTest cases with 18 skipped and one failure in +`UtilityTests.testGenerationPreparationKeepsMainActorResponsive`, line 271. +Its MainActor heartbeat counter was zero. One Swift Testing case passed. +The current off-main preparation implementation uses `Task.detached`; the +timing-based test does not synchronize worker entry with its probe. This is +a scheduling-race hypothesis requiring deterministic validation, not evidence +that the application performed file copies on MainActor. + +The main tree matches the verified PR tree. The owner authorized the merge and +single-maintainer review settings. Mandatory PRs, strict CI, resolved review +conversations, blocked force pushes/deletions, and no bypass actors remain. +Production's human approval configuration is unchanged. + +## Human decision + +After complete candidate tests and independent readiness verification pass, +request production authorization for this exact run. The v0.0.53 production +approval does not authorize this run. Record the user's decision and GitHub's +approval readback before claiming deployment is authorized. + +## Required distribution evidence + +- Developer ID app and DMG signatures use certificate SHA-256 + `1B499618154DEB0204896CDB199AA65D25EDA2188FEDBB0E29A73063728E4112`, + team `G9L7H3T3D5`; the DMG has a secure timestamp. +- Apple accepts this run's notarization submission and the ticket is stapled. +- Both DMG and app Gatekeeper checks pass, with matching mounted contents. +- Published DMG and SHA-256 sidecar pass download and byte-equality checks. +- Independent download/signature/ticket verification passes on the published + asset. No app launch or clean-machine interaction is implied by these checks. + +All distribution outcomes remain unexecuted. The earlier local signed fixture and +v0.0.53 Apple acceptance do not establish them for this version. + +## Public disclosure scope + +The source and added public evidence passed credential and independent audits. +Public evidence uses redacted machine paths and redundant commit emails; raw +records remain private. Earlier GitHub snapshots are not claimed to be purged. +Only public certificate/team/fingerprint metadata is needed for verification. + +## Rollback and immutable history + +Preserve failed `v0.0.53` at tag object +`b8e869cddca904cd525ece4fcb36d55fd4a14a33` and public `v0.0.52`. +Never move a release tag or replace same-version published assets. Stop on a +signing, notarization, Gatekeeper, mounted-content, or checksum failure and +preserve its first failure. Revert source through a reviewed PR if needed. +If a published release needs withdrawal, restore the prior latest recommendation +without replacing assets and disclose the older artifact's signing status. + +The bounded corrective work and its continuous owner authorization are recorded +in [preparation responsiveness intent](../2026-10-16-preparation-responsiveness-test/intent.md). +The failed v0.0.54 tag remains unchanged; a future release uses a new version. diff --git a/docs/sdlc/changes/2026-10-16-preparation-responsiveness-test/evidence/cache-preservation.json b/docs/sdlc/changes/2026-10-16-preparation-responsiveness-test/evidence/cache-preservation.json new file mode 100644 index 00000000..93e7de43 --- /dev/null +++ b/docs/sdlc/changes/2026-10-16-preparation-responsiveness-test/evidence/cache-preservation.json @@ -0,0 +1,12 @@ +{ + "started_at_utc": "2026-10-16T06:56:50.010484+00:00", + "internal_free_before": 6510440448, + "active_builds": [], + "completed_at_utc": "2026-10-16T06:58:27.639511+00:00", + "entries": 64254, + "copy_verified": true, + "original_logical_path_preserved": true, + "source_and_dependencies_preserved": true, + "internal_free_after": 11214721024, + "external_free_after": 459316482048 +} diff --git a/docs/sdlc/changes/2026-10-16-preparation-responsiveness-test/evidence/first-failures-and-resolution.json b/docs/sdlc/changes/2026-10-16-preparation-responsiveness-test/evidence/first-failures-and-resolution.json new file mode 100644 index 00000000..ecc07e54 --- /dev/null +++ b/docs/sdlc/changes/2026-10-16-preparation-responsiveness-test/evidence/first-failures-and-resolution.json @@ -0,0 +1,18 @@ +{ + "release_v0054": "Complete CI failed the old timing-based preparation test; signing and production were skipped. Original failure retained in the upstream signing bundle.", + "disk_floor": "Local release build guard refused to start while system free disk was below 10 GiB. After active test processes ended, space recovered above the floor; no user apps/data/history were removed.", + "first_protected_wrapper": { + "exit": 1, + "xctest_assertions_failed": 4, + "affected_test": "ModelDownloadTasksTests.testApplicationCatalogResumeEntryStartsBeforeOldDependencyReturns", + "diagnosis": "Driver omitted CFFIXED_USER_HOME. ModelStorage.defaultRoot resolved into the real Utter Application Support path denied by the privacy policy. Preparation precedes the injected dependency. This diagnosis follows environment, policy and source; the log did not print the underlying mkdir errno.", + "runtime_log_sha256": "636880f2c605a624f2ca9d387c0b1d7b022d94e71e5c6186383a3439de21673b" + }, + "second_protected_wrapper": { + "exit": 1, + "tests_started": 0, + "diagnosis": "Correct isolated user directory required an uncached SwiftPM manifest. Native nested sandbox_apply was refused before tests.", + "runtime_log_sha256": "8b07fd611c833dfa4a3b026868e42951611c4d218d8a83698d555d6ca52d4037" + }, + "resolution": "Compile the same isolated-home manifest and tests outside the private runtime policy with native SwiftPM sandboxing preserved. Run protected swift test --skip-build using that same CFFIXED_USER_HOME. Full execution then passed without product code changes or a weakened policy." +} diff --git a/docs/sdlc/changes/2026-10-16-preparation-responsiveness-test/evidence/frozen-products.json b/docs/sdlc/changes/2026-10-16-preparation-responsiveness-test/evidence/frozen-products.json new file mode 100644 index 00000000..dcdc6df0 --- /dev/null +++ b/docs/sdlc/changes/2026-10-16-preparation-responsiveness-test/evidence/frozen-products.json @@ -0,0 +1,17 @@ +{ + "product_files": 702, + "test_bundle_files": 300, + "bundle_count": 14, + "product_manifest_sha256": "9340bac14b9b2329a31103896738978df6cda0240a9ca35d8f99474ae451e9e2", + "bundle_manifest_sha256": "1c72801ee85740db6e07ddb4abdf134e765f648d07ac6ae576a2510c117f700e", + "runtime_policy_sha256": "1c3ccabadb90565b1ddf23d4de039713845ba7d0f32970fa043456b8acdbcf67", + "source_sha256": { + "Sources/UtterModels/ModelGenerations.swift": "9b6f2235d32495e4ec0ae4621cf984f71a388286f27d022283b8a887bf166f19", + "Sources/UtterModels/Native/ModelStorage.swift": "31bc929a9ca496349504260b980766ef6c11db8085541f8bca81839dd714a04b", + "Tests/OpenTypeTests/UtilityTests.swift": "de82594de0a80ac8510a84bf1b31b636265bec04ddc367f67cd2cb9707c10da0", + "Tests/OpenTypeTests/ModelPreparationResponsivenessTests.swift": "968d10c120a11e3fd8472ab325ca33f9bb9c3351454b2d3d4fffe83990613707", + "Package.resolved": "3a007c520b8b69aa9a675a42675662d7d272e4808dd3e71e4f12e074150219ad" + }, + "fixed_dependency_pins": 19, + "all_resources_and_metadata_preserved": true +} diff --git a/docs/sdlc/changes/2026-10-16-preparation-responsiveness-test/evidence/independent-local-review.json b/docs/sdlc/changes/2026-10-16-preparation-responsiveness-test/evidence/independent-local-review.json new file mode 100644 index 00000000..221a8e5c --- /dev/null +++ b/docs/sdlc/changes/2026-10-16-preparation-responsiveness-test/evidence/independent-local-review.json @@ -0,0 +1,124 @@ +{ + "schema_version": 1, + "verified_at_utc": "2026-10-16T07:21:55.651587+00:00", + "result": "pass_local", + "blockers": [], + "scope": "Independent read-only source and actual local validation evidence review; only this report was written. No tests, builds, credential access, app launch, remote mutation or production approval by verifier.", + "source_review": { + "result": "pass", + "files_sha256": { + "Sources/UtterModels/ModelGenerations.swift": "9b6f2235d32495e4ec0ae4621cf984f71a388286f27d022283b8a887bf166f19", + "Sources/UtterModels/Native/ModelStorage.swift": "31bc929a9ca496349504260b980766ef6c11db8085541f8bca81839dd714a04b", + "Tests/OpenTypeTests/UtilityTests.swift": "de82594de0a80ac8510a84bf1b31b636265bec04ddc367f67cd2cb9707c10da0", + "Tests/OpenTypeTests/ModelPreparationResponsivenessTests.swift": "968d10c120a11e3fd8472ab325ca33f9bb9c3351454b2d3d4fffe83990613707" + }, + "callbacks_bracket_real_detached_work": true, + "production_callers_retain_nil_defaults": true, + "mainactor_observes_entry_before_exit_before_release": true, + "copied_bytes_and_background_cleanup_asserted": true, + "watchdog_started_before_first_suspension": true, + "exact_source_restored_after_mutation": true + }, + "focused_regression": { + "positive_exit": 0, + "whole_worker_explicit_mainactor_mutation_test_exit": 1, + "mutation_harness_exit": 0, + "distinction": "The harness exits zero because the actual XCTest process failed its intended responsiveness assertion. This is not a passing mutant test.", + "failure_assertion": "MainActor must respond between worker entry and exit", + "mutation_test_completed_seconds": 8.535, + "restored_positive_exit": 0, + "evidence": [ + "/focused-positive.json", + "/focused-mainactor-mutation.json", + "/mutation.json", + "/focused-restored-positive.json" + ] + }, + "native_complete_suite": { + "bundle_count": 14, + "xctest_unique": 1143, + "xctest_skipped": 17, + "xctest_failures": 0, + "swift_testing_unique": 1, + "expected_empty_swift_testing_invocations": 13, + "empty_engine_exit": 69, + "discovery_started_finished_exact_unique_identity_sets_match": true, + "frozen_product_files": 702, + "bundle_files": 300, + "frozen_and_live_debug_hashes_match_after_wrapper": true, + "evidence": "/native-run-cea7d6ab/" + }, + "swift_test_wrapper_attempts": [ + { + "attempt": 1, + "exit": 1, + "classification": "Real assertion failure in an incorrectly configured isolated runtime", + "failed_test": "ModelDownloadTasksTests.testApplicationCatalogResumeEntryStartsBeforeOldDependencyReturns", + "assertion_failures": 4, + "diagnosis": "CFFIXED_USER_HOME was omitted. The existing facade uses default Application Support storage, which the runtime policy denies before the injected dependency. Source, environment and zero dependency-call assertions support this diagnosis; the log does not directly print a staging mkdir errno.", + "raw_evidence_preserved": "/protected-swift-test.log" + }, + { + "attempt": 2, + "exit": 1, + "classification": "Setup failure before test execution", + "diagnosis": "Correct isolated CFFIXED_USER_HOME selected an uncached manifest. Compiling it under the outer runtime policy failed with nested sandbox_apply Operation not permitted.", + "raw_evidence_preserved": "/protected-swift-test-isolated.log" + }, + { + "attempt": 3, + "exit": 0, + "classification": "Complete guarded swift test success", + "resolution": "Precompiled the isolated-home manifest with native SwiftPM build sandboxing outside the test runtime policy, then ran swift test --skip-build --skip-update --disable-automatic-resolution under the unchanged runtime policy and isolated home. No product repair or sandbox disabling.", + "xctest_unique": 1143, + "xctest_skipped": 17, + "xctest_failures": 0, + "swift_testing_unique": 1, + "bundle_final_pass_summaries": 14, + "discovery_started_finished_exact_unique_identity_sets_match": true, + "log_sha256": "b3e564c39430161757ad829724998094d73e9fd01443bb754ce585daeb7e8ad1", + "evidence": [ + "/isolated-manifest-build.json", + "/protected-swift-test-prewarmed.json", + "/protected-swift-test-complete-audit.json" + ] + } + ], + "environment_protection": { + "minimal_runner_environments": true, + "runtime_policy_sha256": "1c3ccabadb90565b1ddf23d4de039713845ba7d0f32970fa043456b8acdbcf67", + "real_private_paths_and_preferences_daemons_denied": true, + "fresh_preference_canary_failed_to_sync_and_real_probe_absent": true, + "keychain_path_open_canary_errno": 1, + "native_swiftpm_build_sandbox_preserved": true, + "automatic_dependency_resolution_disabled": true, + "package_resolved_sha256": "3a007c520b8b69aa9a675a42675662d7d272e4808dd3e71e4f12e074150219ad", + "all_recorded_build_check_endpoints_above_10_gib": true + }, + "checks": { + "sdlc_exit": 0, + "basic_checks_exit": 0, + "release_style_build_exit": 0, + "release_style_version": "0.0.55", + "release_style_build_number": "0.0.55", + "local_app_strict_deep_codesign_verified_by_independent_verifier": true, + "app_identity": "Developer ID Application: Chen Li (G9L7H3T3D5)", + "app_team": "G9L7H3T3D5", + "app_hardened_runtime": true, + "app_secure_timestamp_present": true, + "assembled_dmg_sha256": "e1fd29277cc9f7fd4183c81f08f6b249386ddabafa47245c436a4d3bc8a83b73", + "build_log_contains_hdiutil_checksum_and_mounted_app_signature_verification": true, + "release_build_log_sha256": "8c89f6da558fbb0cd5f9e25a8a82740b5d44e6b31542aa7d367ebb86215b3351" + }, + "remaining_delivery_gates": [ + "Publish sanitized evidence and pass exact PR-head CI before owner-authorized merge.", + "Verify exact merged-main CI before a new immutable release tag.", + "A future concrete release run requires separate human production approval." + ], + "limits": [ + "This local packaging result is not Apple notarization, Gatekeeper acceptance or a published release.", + "Failed v0.0.53 and v0.0.54 release histories remain preserved.", + "Original local logs and paths remain outside this report; public evidence must be sanitized before publication." + ], + "rollback": "Revert only the scoped preparation test and callback plumbing through a PR; retain responsiveness assertions and existing signing, CI and production controls." +} diff --git a/docs/sdlc/changes/2026-10-16-preparation-responsiveness-test/evidence/local-commands.json b/docs/sdlc/changes/2026-10-16-preparation-responsiveness-test/evidence/local-commands.json new file mode 100644 index 00000000..b3bbcfb4 --- /dev/null +++ b/docs/sdlc/changes/2026-10-16-preparation-responsiveness-test/evidence/local-commands.json @@ -0,0 +1,150 @@ +{ + "build-tests": { + "command": [ + "swift", + "build", + "--build-tests", + "--skip-update", + "--disable-automatic-resolution" + ], + "started_at_utc": "2026-10-16T07:00:51.571350+00:00", + "exit": 0, + "finished_at_utc": "2026-10-16T07:02:02.427197+00:00", + "lockfile_unchanged": true, + "internal_free_bytes": 11175763968 + }, + "mutation-build": { + "command": [ + "swift", + "build", + "--build-tests", + "--skip-update", + "--disable-automatic-resolution" + ], + "started_at_utc": "2026-10-16T07:03:07.385661+00:00", + "exit": 0, + "finished_at_utc": "2026-10-16T07:03:13.430965+00:00", + "lockfile_unchanged": true, + "internal_free_bytes": 11152990208 + }, + "restored-build": { + "command": [ + "swift", + "build", + "--build-tests", + "--skip-update", + "--disable-automatic-resolution" + ], + "started_at_utc": "2026-10-16T07:03:22.823825+00:00", + "exit": 0, + "finished_at_utc": "2026-10-16T07:03:28.454002+00:00", + "lockfile_unchanged": true, + "internal_free_bytes": 11052101632 + }, + "sdlc-checks": { + "command": [ + "bash", + "scripts/sdlc-checks.sh" + ], + "started_at_utc": "2026-10-16T07:12:23.490319+00:00", + "exit": 0, + "finished_at_utc": "2026-10-16T07:12:24.474944+00:00", + "lockfile_unchanged": true, + "internal_free_bytes": 11045519360 + }, + "basic-checks": { + "command": [ + "bash", + "scripts/ci-basic-checks.sh" + ], + "started_at_utc": "2026-10-16T07:12:23.490319+00:00", + "exit": 0, + "finished_at_utc": "2026-10-16T07:13:56.321438+00:00", + "lockfile_unchanged": true, + "internal_free_bytes": 11303817216 + }, + "release-build": { + "command": [ + "bash", + "scripts/build-app.sh", + "--version=0.0.55", + "--sign=0A1A804E9C5D7BE644E4A6B884487BB5191F691D" + ], + "started_at_utc": "2026-10-16T07:15:26.293086+00:00", + "exit": 0, + "finished_at_utc": "2026-10-16T07:18:10.882528+00:00", + "lockfile_unchanged": true, + "internal_free_bytes": 11045183488 + }, + "isolated-manifest-build": { + "command": [ + "/usr/bin/env", + "CFFIXED_USER_HOME=TASK_WORK/test-home", + "swift", + "build", + "--build-tests", + "--skip-update", + "--disable-automatic-resolution" + ], + "started_at_utc": "2026-10-16T07:18:31.954336+00:00", + "exit": 0, + "finished_at_utc": "2026-10-16T07:18:39.844291+00:00", + "lockfile_unchanged": true, + "internal_free_bytes": 11027816448 + }, + "protected-swift-test": { + "command": [ + "sandbox-exec", + "-f", + "TASK_WORK/test-runtime-narrow.sb", + "swift", + "test", + "--skip-build", + "--skip-update", + "--disable-automatic-resolution" + ], + "started_at_utc": "2026-10-16T07:12:40.010641+00:00", + "exit": 1, + "finished_at_utc": "2026-10-16T07:13:49.499816+00:00", + "lockfile_unchanged": true, + "internal_free_bytes": 11304456192 + }, + "protected-swift-test-isolated": { + "command": [ + "sandbox-exec", + "-f", + "TASK_WORK/test-runtime-narrow.sb", + "/usr/bin/env", + "CFFIXED_USER_HOME=TASK_WORK/test-home", + "swift", + "test", + "--skip-build", + "--skip-update", + "--disable-automatic-resolution" + ], + "started_at_utc": "2026-10-16T07:15:14.100491+00:00", + "exit": 1, + "finished_at_utc": "2026-10-16T07:15:14.783088+00:00", + "lockfile_unchanged": true, + "internal_free_bytes": 11296579584 + }, + "protected-swift-test-prewarmed": { + "command": [ + "sandbox-exec", + "-f", + "TASK_WORK/test-runtime-narrow.sb", + "/usr/bin/env", + "CFFIXED_USER_HOME=TASK_WORK/test-home", + "swift", + "test", + "--skip-build", + "--skip-update", + "--disable-automatic-resolution" + ], + "started_at_utc": "2026-10-16T07:19:04.664473+00:00", + "exit": 0, + "finished_at_utc": "2026-10-16T07:20:04.030300+00:00", + "lockfile_unchanged": true, + "internal_free_bytes": 11338203136 + } +} diff --git a/docs/sdlc/changes/2026-10-16-preparation-responsiveness-test/evidence/local-packaging.json b/docs/sdlc/changes/2026-10-16-preparation-responsiveness-test/evidence/local-packaging.json new file mode 100644 index 00000000..43e9d904 --- /dev/null +++ b/docs/sdlc/changes/2026-10-16-preparation-responsiveness-test/evidence/local-packaging.json @@ -0,0 +1,13 @@ +{ + "exit": 0, + "app_version": "0.0.55", + "app_identifier": "com.opentype.voiceinput", + "signing_identity_sha1": "0A1A804E9C5D7BE644E4A6B884487BB5191F691D", + "app_codesign_and_designated_requirement_verified": true, + "dmg_checksum_owned_resources_and_mounted_app_verified": true, + "dmg_sha256": "e1fd29277cc9f7fd4183c81f08f6b249386ddabafa47245c436a4d3bc8a83b73", + "notarized": false, + "published": false, + "app_launched": false, + "local_fixture_only": true +} diff --git a/docs/sdlc/changes/2026-10-16-preparation-responsiveness-test/evidence/mutation.json b/docs/sdlc/changes/2026-10-16-preparation-responsiveness-test/evidence/mutation.json new file mode 100644 index 00000000..928bf8a7 --- /dev/null +++ b/docs/sdlc/changes/2026-10-16-preparation-responsiveness-test/evidence/mutation.json @@ -0,0 +1,70 @@ +{ + "controlled_mutation": { + "mutation": "Force the entire preparation worker closure onto MainActor", + "source_sha256_before": "9b6f2235d32495e4ec0ae4621cf984f71a388286f27d022283b8a887bf166f19", + "build_exit": 0, + "focused_exit": 0, + "source_sha256_restored": "9b6f2235d32495e4ec0ae4621cf984f71a388286f27d022283b8a887bf166f19", + "exact_source_restored": true + }, + "mutant_xctest": { + "command": [ + "sandbox-exec", + "-f", + "TASK_WORK/test-runtime-narrow.sb", + "/usr/bin/env", + "DYLD_FRAMEWORK_PATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/Library/Frameworks", + "DYLD_LIBRARY_PATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/usr/lib:/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx", + "/Applications/Xcode.app/Contents/Developer/usr/bin/xctest", + "-XCTest", + "OpenTypeTests.ModelPreparationResponsivenessTests/testGenerationPreparationKeepsMainActorResponsive", + "WORKSPACE/.build/out/Products/Debug/OpenTypeTests.xctest" + ], + "started_at_utc": "2026-10-16T07:03:13.458437+00:00", + "finished_at_utc": "2026-10-16T07:03:22.794731+00:00", + "exit": 1, + "expected_failure": true, + "intended_result": true + }, + "positive": { + "command": [ + "sandbox-exec", + "-f", + "TASK_WORK/test-runtime-narrow.sb", + "/usr/bin/env", + "DYLD_FRAMEWORK_PATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/Library/Frameworks", + "DYLD_LIBRARY_PATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/usr/lib:/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx", + "/Applications/Xcode.app/Contents/Developer/usr/bin/xctest", + "-XCTest", + "OpenTypeTests.ModelPreparationResponsivenessTests/testGenerationPreparationKeepsMainActorResponsive", + "WORKSPACE/.build/out/Products/Debug/OpenTypeTests.xctest" + ], + "started_at_utc": "2026-10-16T07:02:45.927690+00:00", + "finished_at_utc": "2026-10-16T07:02:47.513602+00:00", + "exit": 0, + "expected_failure": false, + "intended_result": true + }, + "restored_positive": { + "command": [ + "sandbox-exec", + "-f", + "TASK_WORK/test-runtime-narrow.sb", + "/usr/bin/env", + "DYLD_FRAMEWORK_PATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/Library/Frameworks", + "DYLD_LIBRARY_PATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/usr/lib:/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx", + "/Applications/Xcode.app/Contents/Developer/usr/bin/xctest", + "-XCTest", + "OpenTypeTests.ModelPreparationResponsivenessTests/testGenerationPreparationKeepsMainActorResponsive", + "WORKSPACE/.build/out/Products/Debug/OpenTypeTests.xctest" + ], + "started_at_utc": "2026-10-16T07:12:13.432608+00:00", + "finished_at_utc": "2026-10-16T07:12:14.251705+00:00", + "exit": 0, + "expected_failure": false, + "intended_result": true + }, + "mutant_assertion": "XCTAssertFalse: MainActor must respond between worker entry and exit", + "mutant_duration_seconds": 8.535, + "harness_exit_zero_means_expected_xctest_failure_confirmed": true +} diff --git a/docs/sdlc/changes/2026-10-16-preparation-responsiveness-test/evidence/native-suite.json b/docs/sdlc/changes/2026-10-16-preparation-responsiveness-test/evidence/native-suite.json new file mode 100644 index 00000000..32b32977 --- /dev/null +++ b/docs/sdlc/changes/2026-10-16-preparation-responsiveness-test/evidence/native-suite.json @@ -0,0 +1,749 @@ +{ + "summary": { + "bundle_count": 14, + "invocations": 28, + "nonzero_exits": 13, + "incomplete_invocations": 0, + "total_xctest": 1143, + "total_swift_testing": 1, + "bundle_hashes_unchanged": true, + "all_frozen_products_unchanged": true, + "unique_identity_sets_equal": true, + "total_xctest_skipped": 17, + "xctest_all_pass": true, + "swift_testing_all_expected": true, + "native_full_pass": true + }, + "identity_audit": [ + { + "bundle": "OpenTypeTests.xctest", + "expected": 499, + "started": 499, + "finished": 499, + "unique_identity_sets_equal": true + }, + { + "bundle": "UtterAudioTests.xctest", + "expected": 20, + "started": 20, + "finished": 20, + "unique_identity_sets_equal": true + }, + { + "bundle": "UtterBuiltinsTests.xctest", + "expected": 2, + "started": 2, + "finished": 2, + "unique_identity_sets_equal": true + }, + { + "bundle": "UtterContractsTests.xctest", + "expected": 123, + "started": 123, + "finished": 123, + "unique_identity_sets_equal": true + }, + { + "bundle": "UtterDataTests.xctest", + "expected": 58, + "started": 58, + "finished": 58, + "unique_identity_sets_equal": true + }, + { + "bundle": "UtterEvaluationTests.xctest", + "expected": 7, + "started": 7, + "finished": 7, + "unique_identity_sets_equal": true + }, + { + "bundle": "UtterIngressTests.xctest", + "expected": 12, + "started": 12, + "finished": 12, + "unique_identity_sets_equal": true + }, + { + "bundle": "UtterMacServicesTests.xctest", + "expected": 54, + "started": 54, + "finished": 54, + "unique_identity_sets_equal": true + }, + { + "bundle": "UtterModelsTests.xctest", + "expected": 34, + "started": 34, + "finished": 34, + "unique_identity_sets_equal": true + }, + { + "bundle": "UtterProcessingTests.xctest", + "expected": 107, + "started": 107, + "finished": 107, + "unique_identity_sets_equal": true + }, + { + "bundle": "UtterRemoteInferenceTests.xctest", + "expected": 89, + "started": 89, + "finished": 89, + "unique_identity_sets_equal": true + }, + { + "bundle": "UtterRemoteMicTests.xctest", + "expected": 54, + "started": 54, + "finished": 54, + "unique_identity_sets_equal": true + }, + { + "bundle": "UtterRuntimeTests.xctest", + "expected": 26, + "started": 26, + "finished": 26, + "unique_identity_sets_equal": true + }, + { + "bundle": "UtterSessionTests.xctest", + "expected": 58, + "started": 58, + "finished": 58, + "unique_identity_sets_equal": true + } + ], + "engine_results": [ + { + "bundle": "OpenTypeTests.xctest", + "engine": "xctest", + "exit": 0, + "executed": 499, + "skipped": 17, + "failures": 0, + "complete": true, + "expected_xctest": 499, + "timeout": false, + "command": [ + "sandbox-exec", + "-f", + "TASK_WORK/test-runtime-narrow.sb", + "/usr/bin/env", + "DYLD_FRAMEWORK_PATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/Library/Frameworks", + "DYLD_LIBRARY_PATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/usr/lib:/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx", + "/Applications/Xcode.app/Contents/Developer/usr/bin/xctest", + "TASK_WORK/frozen-products/OpenTypeTests.xctest" + ] + }, + { + "bundle": "OpenTypeTests.xctest", + "engine": "swift-testing", + "exit": 0, + "executed": 1, + "skipped": null, + "failures": 0, + "complete": true, + "expected_xctest": null, + "timeout": false, + "command": [ + "sandbox-exec", + "-f", + "TASK_WORK/test-runtime-narrow.sb", + "/usr/bin/env", + "DYLD_FRAMEWORK_PATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/Library/Frameworks", + "DYLD_LIBRARY_PATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/usr/lib:/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx", + "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/libexec/swift/pm/swiftpm-testing-helper", + "--test-bundle-path", + "TASK_WORK/frozen-products/OpenTypeTests.xctest/Contents/MacOS/OpenTypeTests", + "--testing-library", + "swift-testing" + ] + }, + { + "bundle": "UtterAudioTests.xctest", + "engine": "xctest", + "exit": 0, + "executed": 20, + "skipped": 0, + "failures": 0, + "complete": true, + "expected_xctest": 20, + "timeout": false, + "command": [ + "sandbox-exec", + "-f", + "TASK_WORK/test-runtime-narrow.sb", + "/usr/bin/env", + "DYLD_FRAMEWORK_PATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/Library/Frameworks", + "DYLD_LIBRARY_PATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/usr/lib:/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx", + "/Applications/Xcode.app/Contents/Developer/usr/bin/xctest", + "TASK_WORK/frozen-products/UtterAudioTests.xctest" + ] + }, + { + "bundle": "UtterAudioTests.xctest", + "engine": "swift-testing", + "exit": 69, + "executed": 0, + "skipped": null, + "failures": 0, + "complete": true, + "expected_xctest": null, + "timeout": false, + "command": [ + "sandbox-exec", + "-f", + "TASK_WORK/test-runtime-narrow.sb", + "/usr/bin/env", + "DYLD_FRAMEWORK_PATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/Library/Frameworks", + "DYLD_LIBRARY_PATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/usr/lib:/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx", + "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/libexec/swift/pm/swiftpm-testing-helper", + "--test-bundle-path", + "TASK_WORK/frozen-products/UtterAudioTests.xctest/Contents/MacOS/UtterAudioTests", + "--testing-library", + "swift-testing" + ] + }, + { + "bundle": "UtterBuiltinsTests.xctest", + "engine": "xctest", + "exit": 0, + "executed": 2, + "skipped": 0, + "failures": 0, + "complete": true, + "expected_xctest": 2, + "timeout": false, + "command": [ + "sandbox-exec", + "-f", + "TASK_WORK/test-runtime-narrow.sb", + "/usr/bin/env", + "DYLD_FRAMEWORK_PATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/Library/Frameworks", + "DYLD_LIBRARY_PATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/usr/lib:/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx", + "/Applications/Xcode.app/Contents/Developer/usr/bin/xctest", + "TASK_WORK/frozen-products/UtterBuiltinsTests.xctest" + ] + }, + { + "bundle": "UtterBuiltinsTests.xctest", + "engine": "swift-testing", + "exit": 69, + "executed": 0, + "skipped": null, + "failures": 0, + "complete": true, + "expected_xctest": null, + "timeout": false, + "command": [ + "sandbox-exec", + "-f", + "TASK_WORK/test-runtime-narrow.sb", + "/usr/bin/env", + "DYLD_FRAMEWORK_PATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/Library/Frameworks", + "DYLD_LIBRARY_PATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/usr/lib:/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx", + "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/libexec/swift/pm/swiftpm-testing-helper", + "--test-bundle-path", + "TASK_WORK/frozen-products/UtterBuiltinsTests.xctest/Contents/MacOS/UtterBuiltinsTests", + "--testing-library", + "swift-testing" + ] + }, + { + "bundle": "UtterContractsTests.xctest", + "engine": "xctest", + "exit": 0, + "executed": 123, + "skipped": 0, + "failures": 0, + "complete": true, + "expected_xctest": 123, + "timeout": false, + "command": [ + "sandbox-exec", + "-f", + "TASK_WORK/test-runtime-narrow.sb", + "/usr/bin/env", + "DYLD_FRAMEWORK_PATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/Library/Frameworks", + "DYLD_LIBRARY_PATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/usr/lib:/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx", + "/Applications/Xcode.app/Contents/Developer/usr/bin/xctest", + "TASK_WORK/frozen-products/UtterContractsTests.xctest" + ] + }, + { + "bundle": "UtterContractsTests.xctest", + "engine": "swift-testing", + "exit": 69, + "executed": 0, + "skipped": null, + "failures": 0, + "complete": true, + "expected_xctest": null, + "timeout": false, + "command": [ + "sandbox-exec", + "-f", + "TASK_WORK/test-runtime-narrow.sb", + "/usr/bin/env", + "DYLD_FRAMEWORK_PATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/Library/Frameworks", + "DYLD_LIBRARY_PATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/usr/lib:/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx", + "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/libexec/swift/pm/swiftpm-testing-helper", + "--test-bundle-path", + "TASK_WORK/frozen-products/UtterContractsTests.xctest/Contents/MacOS/UtterContractsTests", + "--testing-library", + "swift-testing" + ] + }, + { + "bundle": "UtterDataTests.xctest", + "engine": "xctest", + "exit": 0, + "executed": 58, + "skipped": 0, + "failures": 0, + "complete": true, + "expected_xctest": 58, + "timeout": false, + "command": [ + "sandbox-exec", + "-f", + "TASK_WORK/test-runtime-narrow.sb", + "/usr/bin/env", + "DYLD_FRAMEWORK_PATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/Library/Frameworks", + "DYLD_LIBRARY_PATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/usr/lib:/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx", + "/Applications/Xcode.app/Contents/Developer/usr/bin/xctest", + "TASK_WORK/frozen-products/UtterDataTests.xctest" + ] + }, + { + "bundle": "UtterDataTests.xctest", + "engine": "swift-testing", + "exit": 69, + "executed": 0, + "skipped": null, + "failures": 0, + "complete": true, + "expected_xctest": null, + "timeout": false, + "command": [ + "sandbox-exec", + "-f", + "TASK_WORK/test-runtime-narrow.sb", + "/usr/bin/env", + "DYLD_FRAMEWORK_PATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/Library/Frameworks", + "DYLD_LIBRARY_PATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/usr/lib:/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx", + "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/libexec/swift/pm/swiftpm-testing-helper", + "--test-bundle-path", + "TASK_WORK/frozen-products/UtterDataTests.xctest/Contents/MacOS/UtterDataTests", + "--testing-library", + "swift-testing" + ] + }, + { + "bundle": "UtterEvaluationTests.xctest", + "engine": "xctest", + "exit": 0, + "executed": 7, + "skipped": 0, + "failures": 0, + "complete": true, + "expected_xctest": 7, + "timeout": false, + "command": [ + "sandbox-exec", + "-f", + "TASK_WORK/test-runtime-narrow.sb", + "/usr/bin/env", + "DYLD_FRAMEWORK_PATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/Library/Frameworks", + "DYLD_LIBRARY_PATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/usr/lib:/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx", + "/Applications/Xcode.app/Contents/Developer/usr/bin/xctest", + "TASK_WORK/frozen-products/UtterEvaluationTests.xctest" + ] + }, + { + "bundle": "UtterEvaluationTests.xctest", + "engine": "swift-testing", + "exit": 69, + "executed": 0, + "skipped": null, + "failures": 0, + "complete": true, + "expected_xctest": null, + "timeout": false, + "command": [ + "sandbox-exec", + "-f", + "TASK_WORK/test-runtime-narrow.sb", + "/usr/bin/env", + "DYLD_FRAMEWORK_PATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/Library/Frameworks", + "DYLD_LIBRARY_PATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/usr/lib:/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx", + "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/libexec/swift/pm/swiftpm-testing-helper", + "--test-bundle-path", + "TASK_WORK/frozen-products/UtterEvaluationTests.xctest/Contents/MacOS/UtterEvaluationTests", + "--testing-library", + "swift-testing" + ] + }, + { + "bundle": "UtterIngressTests.xctest", + "engine": "xctest", + "exit": 0, + "executed": 12, + "skipped": 0, + "failures": 0, + "complete": true, + "expected_xctest": 12, + "timeout": false, + "command": [ + "sandbox-exec", + "-f", + "TASK_WORK/test-runtime-narrow.sb", + "/usr/bin/env", + "DYLD_FRAMEWORK_PATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/Library/Frameworks", + "DYLD_LIBRARY_PATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/usr/lib:/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx", + "/Applications/Xcode.app/Contents/Developer/usr/bin/xctest", + "TASK_WORK/frozen-products/UtterIngressTests.xctest" + ] + }, + { + "bundle": "UtterIngressTests.xctest", + "engine": "swift-testing", + "exit": 69, + "executed": 0, + "skipped": null, + "failures": 0, + "complete": true, + "expected_xctest": null, + "timeout": false, + "command": [ + "sandbox-exec", + "-f", + "TASK_WORK/test-runtime-narrow.sb", + "/usr/bin/env", + "DYLD_FRAMEWORK_PATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/Library/Frameworks", + "DYLD_LIBRARY_PATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/usr/lib:/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx", + "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/libexec/swift/pm/swiftpm-testing-helper", + "--test-bundle-path", + "TASK_WORK/frozen-products/UtterIngressTests.xctest/Contents/MacOS/UtterIngressTests", + "--testing-library", + "swift-testing" + ] + }, + { + "bundle": "UtterMacServicesTests.xctest", + "engine": "xctest", + "exit": 0, + "executed": 54, + "skipped": 0, + "failures": 0, + "complete": true, + "expected_xctest": 54, + "timeout": false, + "command": [ + "sandbox-exec", + "-f", + "TASK_WORK/test-runtime-narrow.sb", + "/usr/bin/env", + "DYLD_FRAMEWORK_PATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/Library/Frameworks", + "DYLD_LIBRARY_PATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/usr/lib:/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx", + "/Applications/Xcode.app/Contents/Developer/usr/bin/xctest", + "TASK_WORK/frozen-products/UtterMacServicesTests.xctest" + ] + }, + { + "bundle": "UtterMacServicesTests.xctest", + "engine": "swift-testing", + "exit": 69, + "executed": 0, + "skipped": null, + "failures": 0, + "complete": true, + "expected_xctest": null, + "timeout": false, + "command": [ + "sandbox-exec", + "-f", + "TASK_WORK/test-runtime-narrow.sb", + "/usr/bin/env", + "DYLD_FRAMEWORK_PATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/Library/Frameworks", + "DYLD_LIBRARY_PATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/usr/lib:/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx", + "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/libexec/swift/pm/swiftpm-testing-helper", + "--test-bundle-path", + "TASK_WORK/frozen-products/UtterMacServicesTests.xctest/Contents/MacOS/UtterMacServicesTests", + "--testing-library", + "swift-testing" + ] + }, + { + "bundle": "UtterModelsTests.xctest", + "engine": "xctest", + "exit": 0, + "executed": 34, + "skipped": 0, + "failures": 0, + "complete": true, + "expected_xctest": 34, + "timeout": false, + "command": [ + "sandbox-exec", + "-f", + "TASK_WORK/test-runtime-narrow.sb", + "/usr/bin/env", + "DYLD_FRAMEWORK_PATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/Library/Frameworks", + "DYLD_LIBRARY_PATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/usr/lib:/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx", + "/Applications/Xcode.app/Contents/Developer/usr/bin/xctest", + "TASK_WORK/frozen-products/UtterModelsTests.xctest" + ] + }, + { + "bundle": "UtterModelsTests.xctest", + "engine": "swift-testing", + "exit": 69, + "executed": 0, + "skipped": null, + "failures": 0, + "complete": true, + "expected_xctest": null, + "timeout": false, + "command": [ + "sandbox-exec", + "-f", + "TASK_WORK/test-runtime-narrow.sb", + "/usr/bin/env", + "DYLD_FRAMEWORK_PATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/Library/Frameworks", + "DYLD_LIBRARY_PATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/usr/lib:/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx", + "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/libexec/swift/pm/swiftpm-testing-helper", + "--test-bundle-path", + "TASK_WORK/frozen-products/UtterModelsTests.xctest/Contents/MacOS/UtterModelsTests", + "--testing-library", + "swift-testing" + ] + }, + { + "bundle": "UtterProcessingTests.xctest", + "engine": "xctest", + "exit": 0, + "executed": 107, + "skipped": 0, + "failures": 0, + "complete": true, + "expected_xctest": 107, + "timeout": false, + "command": [ + "sandbox-exec", + "-f", + "TASK_WORK/test-runtime-narrow.sb", + "/usr/bin/env", + "DYLD_FRAMEWORK_PATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/Library/Frameworks", + "DYLD_LIBRARY_PATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/usr/lib:/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx", + "/Applications/Xcode.app/Contents/Developer/usr/bin/xctest", + "TASK_WORK/frozen-products/UtterProcessingTests.xctest" + ] + }, + { + "bundle": "UtterProcessingTests.xctest", + "engine": "swift-testing", + "exit": 69, + "executed": 0, + "skipped": null, + "failures": 0, + "complete": true, + "expected_xctest": null, + "timeout": false, + "command": [ + "sandbox-exec", + "-f", + "TASK_WORK/test-runtime-narrow.sb", + "/usr/bin/env", + "DYLD_FRAMEWORK_PATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/Library/Frameworks", + "DYLD_LIBRARY_PATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/usr/lib:/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx", + "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/libexec/swift/pm/swiftpm-testing-helper", + "--test-bundle-path", + "TASK_WORK/frozen-products/UtterProcessingTests.xctest/Contents/MacOS/UtterProcessingTests", + "--testing-library", + "swift-testing" + ] + }, + { + "bundle": "UtterRemoteInferenceTests.xctest", + "engine": "xctest", + "exit": 0, + "executed": 89, + "skipped": 0, + "failures": 0, + "complete": true, + "expected_xctest": 89, + "timeout": false, + "command": [ + "sandbox-exec", + "-f", + "TASK_WORK/test-runtime-narrow.sb", + "/usr/bin/env", + "DYLD_FRAMEWORK_PATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/Library/Frameworks", + "DYLD_LIBRARY_PATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/usr/lib:/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx", + "/Applications/Xcode.app/Contents/Developer/usr/bin/xctest", + "TASK_WORK/frozen-products/UtterRemoteInferenceTests.xctest" + ] + }, + { + "bundle": "UtterRemoteInferenceTests.xctest", + "engine": "swift-testing", + "exit": 69, + "executed": 0, + "skipped": null, + "failures": 0, + "complete": true, + "expected_xctest": null, + "timeout": false, + "command": [ + "sandbox-exec", + "-f", + "TASK_WORK/test-runtime-narrow.sb", + "/usr/bin/env", + "DYLD_FRAMEWORK_PATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/Library/Frameworks", + "DYLD_LIBRARY_PATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/usr/lib:/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx", + "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/libexec/swift/pm/swiftpm-testing-helper", + "--test-bundle-path", + "TASK_WORK/frozen-products/UtterRemoteInferenceTests.xctest/Contents/MacOS/UtterRemoteInferenceTests", + "--testing-library", + "swift-testing" + ] + }, + { + "bundle": "UtterRemoteMicTests.xctest", + "engine": "xctest", + "exit": 0, + "executed": 54, + "skipped": 0, + "failures": 0, + "complete": true, + "expected_xctest": 54, + "timeout": false, + "command": [ + "sandbox-exec", + "-f", + "TASK_WORK/test-runtime-narrow.sb", + "/usr/bin/env", + "DYLD_FRAMEWORK_PATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/Library/Frameworks", + "DYLD_LIBRARY_PATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/usr/lib:/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx", + "/Applications/Xcode.app/Contents/Developer/usr/bin/xctest", + "TASK_WORK/frozen-products/UtterRemoteMicTests.xctest" + ] + }, + { + "bundle": "UtterRemoteMicTests.xctest", + "engine": "swift-testing", + "exit": 69, + "executed": 0, + "skipped": null, + "failures": 0, + "complete": true, + "expected_xctest": null, + "timeout": false, + "command": [ + "sandbox-exec", + "-f", + "TASK_WORK/test-runtime-narrow.sb", + "/usr/bin/env", + "DYLD_FRAMEWORK_PATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/Library/Frameworks", + "DYLD_LIBRARY_PATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/usr/lib:/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx", + "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/libexec/swift/pm/swiftpm-testing-helper", + "--test-bundle-path", + "TASK_WORK/frozen-products/UtterRemoteMicTests.xctest/Contents/MacOS/UtterRemoteMicTests", + "--testing-library", + "swift-testing" + ] + }, + { + "bundle": "UtterRuntimeTests.xctest", + "engine": "xctest", + "exit": 0, + "executed": 26, + "skipped": 0, + "failures": 0, + "complete": true, + "expected_xctest": 26, + "timeout": false, + "command": [ + "sandbox-exec", + "-f", + "TASK_WORK/test-runtime-narrow.sb", + "/usr/bin/env", + "DYLD_FRAMEWORK_PATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/Library/Frameworks", + "DYLD_LIBRARY_PATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/usr/lib:/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx", + "/Applications/Xcode.app/Contents/Developer/usr/bin/xctest", + "TASK_WORK/frozen-products/UtterRuntimeTests.xctest" + ] + }, + { + "bundle": "UtterRuntimeTests.xctest", + "engine": "swift-testing", + "exit": 69, + "executed": 0, + "skipped": null, + "failures": 0, + "complete": true, + "expected_xctest": null, + "timeout": false, + "command": [ + "sandbox-exec", + "-f", + "TASK_WORK/test-runtime-narrow.sb", + "/usr/bin/env", + "DYLD_FRAMEWORK_PATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/Library/Frameworks", + "DYLD_LIBRARY_PATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/usr/lib:/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx", + "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/libexec/swift/pm/swiftpm-testing-helper", + "--test-bundle-path", + "TASK_WORK/frozen-products/UtterRuntimeTests.xctest/Contents/MacOS/UtterRuntimeTests", + "--testing-library", + "swift-testing" + ] + }, + { + "bundle": "UtterSessionTests.xctest", + "engine": "xctest", + "exit": 0, + "executed": 58, + "skipped": 0, + "failures": 0, + "complete": true, + "expected_xctest": 58, + "timeout": false, + "command": [ + "sandbox-exec", + "-f", + "TASK_WORK/test-runtime-narrow.sb", + "/usr/bin/env", + "DYLD_FRAMEWORK_PATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/Library/Frameworks", + "DYLD_LIBRARY_PATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/usr/lib:/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx", + "/Applications/Xcode.app/Contents/Developer/usr/bin/xctest", + "TASK_WORK/frozen-products/UtterSessionTests.xctest" + ] + }, + { + "bundle": "UtterSessionTests.xctest", + "engine": "swift-testing", + "exit": 69, + "executed": 0, + "skipped": null, + "failures": 0, + "complete": true, + "expected_xctest": null, + "timeout": false, + "command": [ + "sandbox-exec", + "-f", + "TASK_WORK/test-runtime-narrow.sb", + "/usr/bin/env", + "DYLD_FRAMEWORK_PATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/Library/Frameworks", + "DYLD_LIBRARY_PATH=/Applications/Xcode.app/Contents/Developer/Platforms/MacOSX.platform/Developer/usr/lib:/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/lib/swift/macosx", + "/Applications/Xcode.app/Contents/Developer/Toolchains/XcodeDefault.xctoolchain/usr/libexec/swift/pm/swiftpm-testing-helper", + "--test-bundle-path", + "TASK_WORK/frozen-products/UtterSessionTests.xctest/Contents/MacOS/UtterSessionTests", + "--testing-library", + "swift-testing" + ] + } + ] +} diff --git a/docs/sdlc/changes/2026-10-16-preparation-responsiveness-test/evidence/privacy-canaries.json b/docs/sdlc/changes/2026-10-16-preparation-responsiveness-test/evidence/privacy-canaries.json new file mode 100644 index 00000000..3e1034d9 --- /dev/null +++ b/docs/sdlc/changes/2026-10-16-preparation-responsiveness-test/evidence/privacy-canaries.json @@ -0,0 +1,14 @@ +{ + "policy_sha256": "1c3ccabadb90565b1ddf23d4de039713845ba7d0f32970fa043456b8acdbcf67", + "canaries": { + "preferences-canary": { + "exit": 0, + "stdout": "false\nTASK_WORK/test-home" + }, + "private-path-canary": { + "exit": 0, + "stdout": "errno=1" + } + }, + "real_probe_absent_before_after": true +} diff --git a/docs/sdlc/changes/2026-10-16-preparation-responsiveness-test/evidence/protected-swift-test-complete-audit.json b/docs/sdlc/changes/2026-10-16-preparation-responsiveness-test/evidence/protected-swift-test-complete-audit.json new file mode 100644 index 00000000..b91a2c34 --- /dev/null +++ b/docs/sdlc/changes/2026-10-16-preparation-responsiveness-test/evidence/protected-swift-test-complete-audit.json @@ -0,0 +1,15 @@ +{ + "wrapper_exit": 0, + "xctest_unique": 1143, + "started": 1143, + "finished": 1143, + "skipped": 17, + "failed": 0, + "swift_testing_unique": 1, + "exact_frozen_discovery_identity_sets_match": true, + "private_policy_used": true, + "manifest_precompiled_outside_runtime_policy": true, + "native_swiftpm_sandbox_preserved": true, + "lockfile_unchanged": true, + "log_sha256": "b3e564c39430161757ad829724998094d73e9fd01443bb754ce585daeb7e8ad1" +} diff --git a/docs/sdlc/changes/2026-10-16-preparation-responsiveness-test/evidence/public-disclosure-audit.json b/docs/sdlc/changes/2026-10-16-preparation-responsiveness-test/evidence/public-disclosure-audit.json new file mode 100644 index 00000000..f8bff2ee --- /dev/null +++ b/docs/sdlc/changes/2026-10-16-preparation-responsiveness-test/evidence/public-disclosure-audit.json @@ -0,0 +1,7 @@ +{ + "scope": "All four changed Swift files and both new/updated SDLC bundles for this correction; public diff before push", + "files_scanned": 21, + "findings": [], + "raw_logs_not_included": true, + "public_certificate_metadata_is_expected": true +} diff --git a/docs/sdlc/changes/2026-10-16-preparation-responsiveness-test/intent.md b/docs/sdlc/changes/2026-10-16-preparation-responsiveness-test/intent.md new file mode 100644 index 00000000..a081d71f --- /dev/null +++ b/docs/sdlc/changes/2026-10-16-preparation-responsiveness-test/intent.md @@ -0,0 +1,69 @@ +# Intent: Make the preparation responsiveness check deterministic + +**Status:** approved +**Approved-by:** IchenDEV, explicit continuous scope authorization +**Approved-date:** 2026-10-16 +**Upstream:** [Blocked v0.0.54 candidate](../2026-10-16-dmg-developer-id-signing/release.md) +**Risk:** Medium, test reliability and an internal instrumentation seam + +## Problem and evidence + +Release run `38861433092` completed 1,143 XCTest cases with 18 skips and one +failure at `Tests/OpenTypeTests/UtilityTests.swift:271`. The preparation +responsiveness test observed zero heartbeats. Swift Testing's one case passed; +the production job was skipped. No signing, notarization, or publication ran. + +The same source passed local complete native tests and two exact-head CI runs. +The production function still executes preparation in `Task.detached`. The test +starts its probe after `Task.yield`, which does not guarantee that the probe +runs before fast preparation completes. A zero counter alone cannot distinguish +that race from real MainActor blocking. Do not rerun until green or remove the +responsiveness assertion. + +## Proposed bounded design and execution + +Reuse the existing path-scoped entry/exit barrier pattern used by startup +cleanup tests. Add optional, default-nil callbacks to the internal preparation +entry points, invoked inside the existing detached work around real preparation. +The test's MainActor observes worker entry before exit, then releases the +barrier. A detached watchdog prevents a broken MainActor implementation from +hanging the test. This removes assumptions about copy duration and task order. +Keep real file preparation and cleanup in the exercised path. + +No app behavior, signing, credentials, dependency pins, main/production controls, +or UI changes are intended. Keep the change to the preparation test and its +internal callback plumbing. Do not grow the existing oversized test file. + +## Acceptance and delivery + +- Preserve the exact first CI failure, complete counts, and skipped production. +- The synchronized test passes with detached preparation and rejects a controlled + synchronous-MainActor regression for the intended assertion, without hanging. +- Run the focused case and full local suites with refreshed complete bundles, + hashes, and privacy canaries. Preserve native SwiftPM build sandboxing, fixed + dependency pins, no dependency downloads, and at least 10 GiB free disk. +- Required SDLC/basic checks and release-style packaging pass. Independent + verification confirms the assertions still prove responsiveness. +- Deliver through a PR with full CI, then merge under the owner's authorization + and verify exact main CI before the next release candidate. +- Preserve failed v0.0.53 and v0.0.54 tags. Recheck and use the next unused stable + version, expected v0.0.55. Keep a separate production decision for that run. + +## Requested scope authorization + +The owner may approve this intent together with the concrete design and work +above, authorizing continuous local implementation, validation, independent +review, PR, and merge when all checks pass, without repeated intermediate stage +questions for this bounded correction. Record that explicit authorization in +the subsequent stage artifacts. A failed check or material scope change still +stops progression. Production approval is not included. + +## Rollback + +Revert this scoped test/instrumentation change through a PR. Preserve the full +responsiveness requirement, failed tags and first-failure records. Do not loosen +CI, signing, Gatekeeper, checksum, or production approval to publish. + +The owner answered "批准此范围连续修复并合并" to the bounded scope above. +This authorizes intent, design, execution, verification, and merge after checks +pass. It does not authorize production for a future release run. diff --git a/docs/sdlc/changes/2026-10-16-preparation-responsiveness-test/plan.md b/docs/sdlc/changes/2026-10-16-preparation-responsiveness-test/plan.md new file mode 100644 index 00000000..e7e892e1 --- /dev/null +++ b/docs/sdlc/changes/2026-10-16-preparation-responsiveness-test/plan.md @@ -0,0 +1,29 @@ +# Plan: Fix and deliver the preparation check + +**Status:** approved +**Approved-by:** IchenDEV, explicit continuous scope authorization +**Approved-date:** 2026-10-16 +**Upstream:** [spec](spec.md) + +1. Preserve v0.0.54 first-failure and skipped-production evidence. +2. Add the internal callbacks and replace the timing probe with the shared gate. +3. Build fresh tests without dependency resolution or downloads. Retain native + SwiftPM sandboxing, unchanged Package.resolved, and 10 GiB internal free disk. +4. Prove the focused test passes and detects a whole-worker MainActor mutation. + Restore the exact intended source and rebuild before complete testing. +5. Freeze full bundles, resources, discovery identities, runtime policy, and + hashes. Run both native engines under the existing privacy policy, then + SDLC/basic checks and a release-style signed packaging build. +6. Obtain independent technical verification. Publish sanitized evidence only. +7. Commit, push, create a PR, and merge only after exact-head CI passes. Verify + exact main CI before tagging the next unused stable version. Preserve failed + tags and request separate production approval for that concrete run. + +The owner explicitly authorized these stages and merge after checks pass in one +continuous decision. Record results and failures honestly; do not convert a new +failure into a passing result by retrying without diagnosis. + +Build-cache handling preserved all files, hashes, modes and symlinks on a local +APFS volume, with the original logical path retained. Only the byte-verified +original cache copy was removed. Source, pins, complete old bundles, and all +private evidence remain preserved. New build temporary files stay on that volume. diff --git a/docs/sdlc/changes/2026-10-16-preparation-responsiveness-test/spec.md b/docs/sdlc/changes/2026-10-16-preparation-responsiveness-test/spec.md new file mode 100644 index 00000000..d6d4b65f --- /dev/null +++ b/docs/sdlc/changes/2026-10-16-preparation-responsiveness-test/spec.md @@ -0,0 +1,31 @@ +# Spec: Deterministic preparation responsiveness + +**Status:** approved +**Approved-by:** IchenDEV, explicit continuous scope authorization +**Approved-date:** 2026-10-16 +**Upstream:** [intent](intent.md) + +The existing detached closure continues to own real generation preparation. +Two default-nil Sendable callbacks bracket that work. ModelStorage forwards them; +production callers keep the defaults. Tests reuse the existing lock and +semaphore gate, shared with the startup cleanup check. + +The MainActor starts preparation, waits for worker entry, and records entry +without exit before releasing the worker. A detached watchdog starts before any +MainActor suspension and releases after five seconds, so a whole-worker +MainActor regression fails an assertion instead of hanging. The test still +checks copied bytes and background candidate cleanup with a tiny fixture. + +No credentials, network calls, dependencies, signing policy, or product UI change. +Callbacks are internal instrumentation with no persistent state. No synchronous +copy is introduced. On any error, release the gate and clean the fixture. + +Verify the positive case and a temporary whole-worker MainActor mutation, restore +the exact source, then rebuild and freeze the complete refreshed test products. +Use native SwiftPM sandboxing for builds and the existing privacy policy for test +processes. Preserve pins and the 10 GiB internal disk floor. Release-style build, +complete local engine execution, independent review, and exact-head CI remain +required. Revert the scoped commit through a PR to roll back. + +The owner approved this concrete design through the continuous scope decision +recorded in intent.md. Production remains a separate protected decision. diff --git a/docs/sdlc/changes/2026-10-16-preparation-responsiveness-test/verification.md b/docs/sdlc/changes/2026-10-16-preparation-responsiveness-test/verification.md new file mode 100644 index 00000000..b9b9cdd2 --- /dev/null +++ b/docs/sdlc/changes/2026-10-16-preparation-responsiveness-test/verification.md @@ -0,0 +1,64 @@ +# Verification: Deterministic preparation responsiveness + +**Status:** approved +**Approved-by:** IchenDEV, explicit continuous scope authorization after passing checks +**Approved-date:** 2026-10-16 +**Upstream:** [plan](plan.md) + +## Local result + +The synchronized preparation test passes with a tiny real fixture. Forcing the +whole worker closure onto MainActor produces exactly the intended responsiveness +assertion failure, with one failed XCTest and no hang. The harness exit is zero +because it confirmed that expected failure. The original source was restored +byte-for-byte and tests rebuilt; the restored case passes. + +Both the complete frozen native engines and protected `swift test --skip-build +--skip-update --disable-automatic-resolution` pass all 1,143 unique XCTest cases +with 17 conditional skips and no failures, plus one Swift Testing case. Discovery +identities exactly match every started and finished case across all 14 bundles. +All 702 frozen product files, including 300 bundle files and sibling resources, +retain their hashes. Package.resolved retains its original 19 pins and hash. + +The first protected wrapper omitted the isolated user directory and encountered +four assertions in one existing catalog test. The corrected isolated wrapper +then failed before tests because SwiftPM's uncached manifest required a nested +sandbox. Precompiling that same isolated-home manifest outside the runtime policy +resolved the wrapper setup. Native SwiftPM sandboxing and the runtime privacy +policy stayed enabled. See [first failures](evidence/first-failures-and-resolution.json). +No unrelated product code was changed to make the wrapper pass. + +`bash scripts/sdlc-checks.sh` and `bash scripts/ci-basic-checks.sh` pass. The actual +release-style build for local version 0.0.55 passes App Developer ID signing, +resource checks, DMG checksum and mounted-content verification. This local +fixture is not notarized, published, installed, or launched. Production remains +separately protected. + +## Safety and scope + +Runtime canaries confirm denied real preferences/keychain paths and the isolated +test home. Build and test processes use a minimal environment without inherited +API credentials. Raw logs remain private; public evidence contains summaries, +hashes, repository-relative names, and redacted machine paths. + +A byte-verified relocation preserved the complete build cache and dependency +checkouts on a local APFS volume. The original logical build path remains a +symlink. The release-build guard stopped an attempted start below 10 GiB free; +work resumed only after space recovered. No user applications, data, credentials, +or session history were removed. + +## Delivery + +Independent final local review passed. See [independent report](evidence/independent-local-review.json). The owner explicitly authorized continuous +local verification and PR merge once checks pass. Exact-head PR CI and exact-main +CI remain required before a new immutable release tag. Failed v0.0.53 and v0.0.54 +remain unchanged. Production authorization is outside this scope. + +Revert this scoped source/test change through a PR to roll back. Restore a timing +assumption only with equivalent deterministic responsiveness coverage; do not +relax signing, CI, Gatekeeper, checksum, or production controls. + +The owner answered "批准此范围连续修复并合并" for this bounded correction. +All required local verification conditions above are now met; this records that +explicit conditional authorization, not agent-generated human approval. PR +merge remains conditional on exact-head CI, and production is excluded.