{ "revision": "repair30", "status": "BLOCKED: partial implementation; no native admission", "task_id": "P04-01", "current_table": true, "scope": { "conditions": 15, "additional_EV_obligation": true, "domains": 7, "safety_outcomes": [ "no stopped charging", "no double midnight settlement", "no orphan reservations" ], "packages": 30, "deliveries": 88, "original_credit": "16/88 formal; P04 receives zero credit", "CurrentAlphaScope": "unchanged", "frozen_main": "c0ea009b28a7649aca6a433a1a24dc0be5e7ab81" }, "domains": [ { "domain": "閉店", "normative_rule": "D-034 preserves started services on direct closure and releases waiting requests. Dependency closure stops progress and charging, retains reservations/service identity, and completes once after recovery. RELATED_FACILITY_INACTIVE wins over NO_POWER when both apply.", "current_source": [ { "path": "autoload/simulation_runtime.gd", "function": "_process_tick_commands", "line": 5765, "sha256": "45514aea9367ff678f4dc05166bb9b58121f240d4b5565edeb7ab258e3ded8e0", "function_sha256": "9de66a4bb84b12304300d49085f44546412319bd4aee91e67b61becf97e50294" }, { "path": "scripts/facility/facility_service.gd", "function": "_prepare_service_for_tick", "line": 853, "sha256": "ceb4a3e9224587423f273cdb2b56e6843ab176ac1fc4fe79dd498b5ed5c33b77", "function_sha256": "b35c2c0fb23a04258b71995dd7c3b6dfacbbcdf36106e2e3348acef0e18d21cc" }, { "path": "autoload/simulation_runtime.gd", "function": "_release_closed_business_queues", "line": 12672, "sha256": "45514aea9367ff678f4dc05166bb9b58121f240d4b5565edeb7ab258e3ded8e0", "function_sha256": "3a05fbe94877eeb750fb0d692501954555ab6a8005448ab3b6023dab9bad816b" } ], "approved_authority": [ "D-034", "D05-P04-DEPENDENCY", "D05-P04-PAUSE-REASON" ], "pending_D05": [], "phase": "APPLY_COMMANDS / FACILITY_COMPLETION / FACILITY_QUEUES", "relative_priority": "Command closure before completion; dependency hold during preparation; closed queue release after completion.", "status": "approved policy; fresh Q evidence pending", "observation_status": "historical observations; current M source inspected", "historical_evidence": "I native_bundle C; R/s2a.json; R/s3.json B1", "evidence": "Fresh exact-Q native proof pending; no old raw reused as Q", "nativeWindows": "pending" }, { "domain": "停電", "normative_rule": "BASELINE:183 covers real mana depletion. Legitimately stopped service has no progress or charge and preserves reservations. D05-P04-PAUSE-REASON makes dependency closure the displayed reason when dependency closure and power loss coincide.", "current_source": [ { "path": "autoload/simulation_runtime.gd", "function": "_advance_mana", "line": 10716, "sha256": "45514aea9367ff678f4dc05166bb9b58121f240d4b5565edeb7ab258e3ded8e0", "function_sha256": "05c54626ce6e355acd92994ab80aaf2177c5cf194885e66934552139e087599e" }, { "path": "scripts/facility/facility_service.gd", "function": "_prepare_service_for_tick", "line": 853, "sha256": "ceb4a3e9224587423f273cdb2b56e6843ab176ac1fc4fe79dd498b5ed5c33b77", "function_sha256": "b35c2c0fb23a04258b71995dd7c3b6dfacbbcdf36106e2e3348acef0e18d21cc" } ], "approved_authority": [ "BASELINE:183", "P04-01 safety acceptance", "D05-P04-PAUSE-REASON" ], "pending_D05": [], "phase": "MANA → FACILITY_COMPLETION", "relative_priority": "Projection before completion; RELATED chosen before NO_POWER.", "status": "approved policy; fresh Q evidence pending", "observation_status": "historical observations; current M source inspected", "evidence_scope": "S4 probe calls disconnect_nodes directly: isolated NO_POWER, not global depletion. Global depletion appears only in S3 B1 combined diagnostic. S1 covers separate staff/EV safety.", "historical_evidence": "R/s4.json; B/p04-s4-native-r28; R/s3.json B1 combined diagnostic", "evidence": "Fresh exact-Q native proof pending; no old raw reused as Q", "nativeWindows": "pending" }, { "domain": "破壊", "normative_rule": "Command destruction precedes completion. Accident/raid destruction follows completion and charging in minute N; that sale remains valid. Failure and reservation release for affected unfinished service occurs in N+1. D05-P04-DESTRUCTION is the authority, not BASELINE:183.", "current_source": [ { "path": "autoload/simulation_runtime.gd", "function": "_process_tick_commands", "line": 5765, "sha256": "45514aea9367ff678f4dc05166bb9b58121f240d4b5565edeb7ab258e3ded8e0", "function_sha256": "9de66a4bb84b12304300d49085f44546412319bd4aee91e67b61becf97e50294" }, { "path": "autoload/simulation_runtime.gd", "function": "_advance_defense", "line": 8599, "sha256": "45514aea9367ff678f4dc05166bb9b58121f240d4b5565edeb7ab258e3ded8e0", "function_sha256": "db38b51531276d2620999d57eed7a6219b73f8b8d9ff3706cf569f4797918527" }, { "path": "autoload/simulation_runtime.gd", "function": "_apply_defense_outcome_boundary", "line": 9826, "sha256": "45514aea9367ff678f4dc05166bb9b58121f240d4b5565edeb7ab258e3ded8e0", "function_sha256": "182c48282d96c6ccd1e5f636751db9de8cef2770ad433b291db89111c5fb5043" }, { "path": "scripts/facility/facility_service.gd", "function": "_prepare_service_for_tick", "line": 853, "sha256": "ceb4a3e9224587423f273cdb2b56e6843ab176ac1fc4fe79dd498b5ed5c33b77", "function_sha256": "b35c2c0fb23a04258b71995dd7c3b6dfacbbcdf36106e2e3348acef0e18d21cc" } ], "approved_authority": [ "D05-P04-DESTRUCTION" ], "pending_D05": [], "phase": "APPLY_COMMANDS vs INCIDENTS_AND_EVENTS", "relative_priority": "Command destruction before completion; incident destruction after completion: B4a charges25G then destroys in same tick; B4b next-tick failure/release.", "status": "approved policy; fresh Q evidence pending", "observation_status": "historical observations; current M source inspected", "historical_evidence": "R/s3.json B4a/B4b", "evidence": "Fresh exact-Q native proof pending; no old raw reused as Q", "nativeWindows": "pending" }, { "domain": "退出", "normative_rule": "D-034 release safety remains. Command exit precedes completion; AI planned exit follows completion and only applies to a deciding guest. Later despawn is distinct.", "current_source": [ { "path": "autoload/simulation_runtime.gd", "function": "_execute_leave_facility_queue", "line": 7575, "sha256": "45514aea9367ff678f4dc05166bb9b58121f240d4b5565edeb7ab258e3ded8e0", "function_sha256": "04733da2c6f9627e6d831f8bb6b620018d63305fe43bb927abf21a969288d90d" }, { "path": "autoload/simulation_runtime.gd", "function": "_advance_guest_ai_decisions", "line": 8760, "sha256": "45514aea9367ff678f4dc05166bb9b58121f240d4b5565edeb7ab258e3ded8e0", "function_sha256": "e33b41294e88dba840affd5cc0a5c58fe5d46f5d98a80a8d5f4e907a3b9a7b93" } ], "approved_authority": [ "D-034", "P04-01 safety acceptance", "D05-P04-EXIT" ], "pending_D05": [], "phase": "APPLY_COMMANDS vs AI_DECISIONS", "relative_priority": "Command exit before completion/charging; AI PLANNED_EXIT after them; despawn later.", "status": "approved policy; fresh Q evidence pending", "observation_status": "historical observations; current M source inspected", "historical_evidence": "R/s3.json B2a/B2b/B3 and B1 departure history", "evidence": "Fresh exact-Q native proof pending; no old raw reused as Q", "nativeWindows": "pending" }, { "domain": "課金", "normative_rule": "Charge only completed service, once per idempotency key; retain original price snapshot and reservation/ledger joins. At 00:00 prior-day settlement and upkeep precede completion; the sale belongs to the new day.", "current_source": [ { "path": "autoload/simulation_runtime.gd", "function": "_advance_facility_upkeep", "line": 1876, "sha256": "45514aea9367ff678f4dc05166bb9b58121f240d4b5565edeb7ab258e3ded8e0", "function_sha256": "33a969a14d1a15296059cecadc4bf7e5a35c9eb61d82cb9e2d6d9bbcf5c32c68" }, { "path": "autoload/simulation_runtime.gd", "function": "_complete_service_transaction", "line": 11817, "sha256": "45514aea9367ff678f4dc05166bb9b58121f240d4b5565edeb7ab258e3ded8e0", "function_sha256": "f2b6e96a8eeef3dd3f8419b4d9d5ef4e1d13241600ce970bdd78a924428cac6c" }, { "path": "autoload/simulation_runtime.gd", "function": "_apply_service_transaction", "line": 11833, "sha256": "45514aea9367ff678f4dc05166bb9b58121f240d4b5565edeb7ab258e3ded8e0", "function_sha256": "950474ff3ca8a867ee025c2b7635586d79f2385f79586fc66107191ceb329a9a" }, { "path": "scripts/operations/operations_coordinator.gd", "function": "_process_daily_close", "line": 1125, "sha256": "871a248ee101b6df543fd5cf0440b5d4b0f02c21fa145a99f0687888c1bc6f90", "function_sha256": "665ac0ac4d4c220e68e98810da063fd2ad7ae7dc9e1997944a1e7bea7a3c30e6" } ], "approved_authority": [ "P04-01 safety acceptance", "D05-P04-DEPENDENCY", "D05-P04-SHIFT-1800", "D05-P04-MIDNIGHT-DAY" ], "pending_D05": [], "phase": "TIME_BOUNDARIES → FACILITY_COMPLETION", "relative_priority": "Upkeep/daily close before sale; post-increment sale timestamp, exclusive close period_end;00:00 sale belongs to new day.", "status": "approved policy; fresh Q evidence pending", "observation_status": "historical observations; current M source inspected", "historical_evidence": "I native_bundle C; R/s2a.json; R/s4.json", "evidence": "Fresh exact-Q native proof pending; no old raw reused as Q", "nativeWindows": "pending" }, { "domain": "シフト交代", "normative_rule": "Approved 18:00 order remains: completion and payment before handover. No renewal of prior approval.", "current_source": [ { "path": "autoload/simulation_runtime.gd", "function": "_advance_facilities", "line": 8504, "sha256": "45514aea9367ff678f4dc05166bb9b58121f240d4b5565edeb7ab258e3ded8e0", "function_sha256": "f1efd0c23bdd60d1ef19a21879640b53b8b4d88844c0c881fe7cd724387ec274" }, { "path": "autoload/simulation_runtime.gd", "function": "_advance_staff_ai", "line": 8680, "sha256": "45514aea9367ff678f4dc05166bb9b58121f240d4b5565edeb7ab258e3ded8e0", "function_sha256": "0e222987f7c5e25583dbaba8fe63784aa563715067396e8d31d10bd191e7179b" } ], "approved_authority": [ "BASELINE:64", "BASELINE:67", "D05-P04-SHIFT-1800" ], "pending_D05": [], "phase": "FACILITY_COMPLETION → AI_DECISIONS", "relative_priority": "18:00 completion/payment before shift handover; day staff [17:59,18:00), night [18:00,18:01).", "status": "approved policy; fresh Q evidence pending", "observation_status": "historical observations; current M source inspected", "historical_evidence": "I C first1080 sale joins; R/s2b.json no-night1081/overtime", "evidence": "Fresh exact-Q native proof pending; no old raw reused as Q", "nativeWindows": "pending" }, { "domain": "00:00決算", "normative_rule": "A01 ownership-based upkeep is unchanged. Prior-day settlement/upkeep precede 00:00 service completion; its sale belongs to the new day. Replay/restore must not duplicate settlement.", "current_source": [ { "path": "scripts/core/simulation_kernel.gd", "function": "_handle_time_boundaries", "line": 254, "sha256": "341c0c878c4894adbac628d0db6362ff69fc3347bdd9e61e50936e15dc2d1edb", "function_sha256": "2ced47a2911b36def9d89de82a43afc69148ead44d19db6a2a6c7bce5a910ae9" }, { "path": "autoload/simulation_runtime.gd", "function": "_advance_operations_time", "line": 1919, "sha256": "45514aea9367ff678f4dc05166bb9b58121f240d4b5565edeb7ab258e3ded8e0", "function_sha256": "511580d1fac3d2785072e94c2981065fa47ba18b1c97122922645dac5c0d94ab" }, { "path": "scripts/operations/operations_coordinator.gd", "function": "_process_minute_boundaries", "line": 882, "sha256": "871a248ee101b6df543fd5cf0440b5d4b0f02c21fa145a99f0687888c1bc6f90", "function_sha256": "1312166dc17aee0ef470069a73ff3fe6b86d11d04ca7de76f3d04f1d2d14674e" }, { "path": "scripts/operations/operations_coordinator.gd", "function": "_process_daily_close", "line": 1125, "sha256": "871a248ee101b6df543fd5cf0440b5d4b0f02c21fa145a99f0687888c1bc6f90", "function_sha256": "665ac0ac4d4c220e68e98810da063fd2ad7ae7dc9e1997944a1e7bea7a3c30e6" } ], "approved_authority": [ "BASELINE:71", "BASELINE:72", "A01", "D05-P04-DEPENDENCY", "D05-P04-MIDNIGHT-DAY" ], "pending_D05": [], "phase": "pre-TIME_BOUNDARIES signals → TIME_BOUNDARIES → FACILITY_COMPLETION", "relative_priority": "Midnight signals, then upkeep/close, then completion.", "status": "approved policy; fresh Q evidence pending", "observation_status": "historical observations; current M source inspected", "historical_evidence": "I C paused/formal; R/s2a.json nonzero payroll/upkeep, replay and typed restore", "evidence": "Fresh exact-Q native proof pending; no old raw reused as Q", "nativeWindows": "pending" } ], "source_facts": "REPAIR30_SOURCE_FACTS.json", "authority": "D05_OWNER_APPROVAL.json preserves dependency/18:00; D05_REMAINING_APPROVAL.json binds all four actual 2026-10-18 answers; BASELINE/D-034/A01 unchanged.", "historical_superseded": [ "REPAIR17_STATUS.md", "REPAIR18_STATUS.md", "REPAIR19_CORRIGENDUM.md", "REPAIR19_STATUS.md", "REPAIR20_CORRIGENDUM.md", "REPAIR20_STATUS.md", "REPAIR21_STATUS.md", "REPAIR22–28 creation-time status and runbooks" ], "history_policy": "Historical source/proof pins retain their original revisions; CURRENT_STATUS.md is canonical. New approvals are not new native evidence.", "evidence_policy": "All old S1-S4/r22/native/full178 records are historical. None is relabelled as Q. Fresh native S1-S5 and full184/329 on final Q remain NOT RUN.", "pending": [ "Complete current-Q collector/wrapper/index binding and S5 drivers; see REPAIR30_STATUS.md", "Fresh native S1-S5 on final Q, then full184/329 on the same Q including checker", "Truthful index, formal registered validation on S --verify-only, whole-unit independent review, normal C integration", "nativeWindows individually pending for every condition" ], "priority_candidates_if_required": "D05_REMAINING_ORDER_CANDIDATE.json (superseded history)", "collection_plan": "REPAIR30_STATUS.md", "formal_acceptance": false, "original_unit_complete": false, "phase_order": [ { "priority": 1, "phase": "APPLY_COMMANDS", "status": "observed-current", "handlers": [ { "phase": "APPLY_COMMANDS", "handler_id": "simulation_runtime.commands", "function": "_process_tick_commands", "registration_line": 369 } ], "behavior": "Previous minute: commands → _process_tick_commands:5743. Operations gate requests current tick abort and returns before Clock changes; otherwise commands apply for minute+1." }, { "priority": 2, "phase": "TIME_BOUNDARIES", "status": "observed-current", "handlers": [ { "phase": "TIME_BOUNDARIES", "handler_id": "simulation_runtime.0_weather", "function": "_advance_weather", "registration_line": 366 }, { "phase": "TIME_BOUNDARIES", "handler_id": "simulation_runtime.a_upkeep", "function": "_advance_facility_upkeep", "registration_line": 368 }, { "phase": "TIME_BOUNDARIES", "handler_id": "simulation_runtime.operations", "function": "_advance_operations_time", "registration_line": 1766 } ], "behavior": "After APPLY: absolute_minute += 1, _sync_calendar_fields, _handle_time_boundaries:254 emits settlement_requested(completed_day) then day_started at00:00, before TIME_BOUNDARIES handlers. Handler order: weather, upkeep, operations. Runtime upkeep:1855; operations:1898 → coordinator _process_minute_boundaries:882: 00:00 upkeep, daily close, 06:00 morning, demand, arrivals (conditional boundaries and early returns)." }, { "priority": 3, "phase": "MANA", "status": "observed-current", "handlers": [ { "phase": "MANA", "handler_id": "simulation_runtime.mana", "function": "_advance_mana", "registration_line": 379 } ], "behavior": "Runtime _advance_mana:10694: proxy preflight → mana_network advance → mana_power_projection.apply → MANA_STATE_CHANGED events." }, { "priority": 4, "phase": "CONSTRUCTION", "status": "observed-current", "handlers": [ { "phase": "CONSTRUCTION", "handler_id": "simulation_runtime.construction", "function": "_advance_construction", "registration_line": 384 } ], "behavior": "Construction:8064 follows power and precedes logistics." }, { "priority": 5, "phase": "LOGISTICS", "status": "observed-current", "handlers": [ { "phase": "LOGISTICS", "handler_id": "simulation_runtime.logistics", "function": "_advance_inventory_and_logistics", "registration_line": 389 } ], "behavior": "Logistics:8472 precedes completion." }, { "priority": 6, "phase": "FACILITY_COMPLETION", "status": "observed-current", "handlers": [ { "phase": "FACILITY_COMPLETION", "handler_id": "simulation_runtime.facilities", "function": "_advance_facilities", "registration_line": 394 } ], "behavior": "Runtime _advance_facilities:8482: facility_service.advance_one_minute then kitchen. FacilityService _prepare_service_for_tick:853 checks BROKEN, related_facility_operating (RELATED_FACILITY_INACTIVE), power_available (NO_POWER), staff grace. Only ACTIVE services advance (:569). _complete_service:895 → Runtime _complete_service_transaction:11769 → _apply_service_transaction:11785 posts SERVICE_SALE / SERVICE_CASH_SWEEP at the post-increment minute (:11826–11838)." }, { "priority": 7, "phase": "VITALS_AND_ENVIRONMENT", "status": "observed-current", "handlers": [ { "phase": "VITALS_AND_ENVIRONMENT", "handler_id": "simulation_runtime.guest_vitals", "function": "_advance_guest_vitals", "registration_line": 399 } ], "behavior": "Guest vitals:8488 follows completion." }, { "priority": 8, "phase": "INCIDENTS_AND_EVENTS", "status": "observed-current", "handlers": [ { "phase": "INCIDENTS_AND_EVENTS", "handler_id": "simulation_runtime.authority_incidents", "function": "_advance_authority_incidents", "registration_line": 409 }, { "phase": "INCIDENTS_AND_EVENTS", "handler_id": "simulation_runtime.defense", "function": "_advance_defense", "registration_line": 414 }, { "phase": "INCIDENTS_AND_EVENTS", "handler_id": "simulation_runtime.relationship_events", "function": "_advance_relationship_events", "registration_line": 419 } ], "behavior": "String-sorted authority_incidents:8551 → defense:8577 → relationship_events:8615; after completion/charging." }, { "priority": 9, "phase": "FACILITY_QUEUES", "status": "observed-current", "handlers": [ { "phase": "FACILITY_QUEUES", "handler_id": "simulation_runtime.guest_queues", "function": "_advance_guest_queues", "registration_line": 404 } ], "behavior": "_advance_guest_queues:8502 releases closed queues first (_release_closed_business_queues:12624); closed queues spend no patience (:8516–8517)." }, { "priority": 10, "phase": "AI_DECISIONS", "status": "observed-current", "handlers": [ { "phase": "AI_DECISIONS", "handler_id": "simulation_runtime.staff_ai", "function": "_advance_staff_ai", "registration_line": 424 } ], "behavior": "_advance_staff_ai:8658: prune elevator waits, elevators, rescue, staff_service, prune waits, staff_commute (shift handover), staffing sync, cleaning, fatigue, rescue and staffing sync again, then _advance_guest_ai_decisions:8738. DECIDING PLANNED_EXIT → LEAVING; despawn occurs only on later minute (:8760–8762)." }, { "priority": 11, "phase": "PUBLISH_SNAPSHOT", "status": "observed-current", "handlers": [ { "phase": "PUBLISH_SNAPSHOT", "handler_id": "simulation_runtime.snapshot", "function": "_publish_snapshot", "registration_line": 374 }, { "phase": "PUBLISH_SNAPSHOT", "handler_id": "simulation_runtime.zz_save_checkpoints", "function": "_process_save_checkpoints", "registration_line": 431 } ], "behavior": "snapshot:12476 then zz_save_checkpoints:4514; persistence follows publication." } ], "safety_cases": [ { "item": "No charge while paused NO_POWER or RELATED", "status": "original", "phase": "FACILITY_COMPLETION", "source": "FacilityService _prepare_service_for_tick:853, ACTIVE-only gate:569, _complete_service:895", "priority": "Preparation before advance/completion/payment", "proof": "R/s4.json isolated power; I C and R/s2a.json dependency hold", "approval": "Dependency hold approved; both D05(a) options preserve safety" }, { "item": "Double-settlement idempotency", "status": "original", "phase": "TIME_BOUNDARIES", "source": "coordinator _process_daily_close:1125; _day_summaries replay:1127–1130; daily-close:N:1137", "priority": "Before facility completion", "proof": "I C; R/s2a.json same-boundary replay and separate-PID restore, unchanged accounting" }, { "item": "Orphan reservation release", "status": "original", "phase": "APPLY_COMMANDS / FACILITY_QUEUES", "source": "Runtime _execute_leave_facility_queue:7553 (release keys:7565–7569); _leave_guest_queue_boundary:9178; _release_closed_business_queues:12624; _release_closed_business_request:12642", "priority": "Command release before completion; closed-queue release afterward; closed patience not spent", "proof": "R/s3.json B2a/B2b/B3/B4b; I C; R/s2a.json reservation/service identity and restore" } ], "proof_legend": { "label": "Root-measured", "R": "B/audit-support/p04-raw-collect-r22", "I": "B/p04-evidence/index.json schema2; native_bundle/raw_references/versions/source_map/environment bind exact proofs", "pins": "REPAIR29_STATIC_SOURCE.json proof_pins; R/MANIFEST.json pins series and relocation, series retain raw paths/hashes" }, "authority_statuses": { "original": [ "P04-01 safety acceptance", "BASELINE:64,67,71,72,183" ], "approved": [ "A01 midnight ownership upkeep", "D05-P04-DEPENDENCY", "D05-P04-SHIFT-1800", "D-034 direct business closure" ], "pending D05": [ "a power vs closure/dependency", "b destruction", "c exit", "d cost time/day beyond A01 and18:00" ], "observed-current": "All phase and source behavior observations; not approval" }, "full178_applicability_context": "REPAIR29_STATIC_SOURCE.json full_source_static_comparison: full178 selected1339 includes f5; one test-source mismatch (test_required_kitchen.gd), no game-source mismatch; preserve Runner applicability binding, no blanket1338 identity or a61 full proof.", "current_source_commit": "c0ea009b28a7649aca6a433a1a24dc0be5e7ab81", "nativeWindows": { "EV": "pending", "closure_release": "pending", "dependency_stop": "pending", "destruction_stop": "pending", "exit_release": "pending", "midnight_replay": "pending", "midnight_settlement": "pending", "night_staff_absent": "pending", "overtime_task": "pending", "patience_release": "pending", "paused_midnight": "pending", "power_stop": "pending", "recovery_completion": "pending", "same_minute_replay": "pending", "save_restore": "pending", "shift_completion": "pending" } }