feat(web): add IwoooS handoff readiness

This commit is contained in:
Your Name
2026-05-20 10:33:31 +08:00
parent a0617aecc0
commit ff7c921de7
11 changed files with 644 additions and 8 deletions

View File

@@ -189,6 +189,7 @@ def validate(root: Path) -> None:
"s2_35_iwooos_host_owner_decision_record_formal_record_queue_packets",
"s2_36_iwooos_host_owner_decision_record_formal_record_queue_review_checklist",
"s2_37_iwooos_host_owner_decision_record_formal_record_queue_review_outcome_lanes",
"s2_38_iwooos_host_owner_decision_record_human_handoff_readiness_packets",
]
assert_equal(
"progress_delta_ledger.delta_ids",
@@ -572,6 +573,16 @@ def validate(root: Path) -> None:
"host_decision_record_formal_record_queue_review_maintenance_rollback_incomplete_outcome_lane",
"host_decision_record_formal_record_queue_review_runtime_gate_required_outcome_lane",
]
expected_iwooos_host_owner_decision_record_human_handoff_readiness_packet_ids = [
"host_decision_record_handoff_readiness_identity_trace_packet",
"host_decision_record_handoff_readiness_owner_boundary_packet",
"host_decision_record_handoff_readiness_decision_summary_packet",
"host_decision_record_handoff_readiness_scope_expiry_packet",
"host_decision_record_handoff_readiness_scan_limits_packet",
"host_decision_record_handoff_readiness_credential_boundary_packet",
"host_decision_record_handoff_readiness_maintenance_rollback_packet",
"host_decision_record_handoff_readiness_runtime_gate_packet",
]
assert_equal(
"iwooos_projection.summary.frontend_surface_coverage_group_count",
iwooos_projection["summary"]["frontend_surface_coverage_group_count"],
@@ -712,6 +723,11 @@ def validate(root: Path) -> None:
iwooos_projection["summary"]["host_owner_decision_record_formal_record_queue_review_outcome_lane_count"],
len(expected_iwooos_host_owner_decision_record_formal_record_queue_review_outcome_lane_ids),
)
assert_equal(
"iwooos_projection.summary.host_owner_decision_record_human_handoff_readiness_packet_count",
iwooos_projection["summary"]["host_owner_decision_record_human_handoff_readiness_packet_count"],
len(expected_iwooos_host_owner_decision_record_human_handoff_readiness_packet_ids),
)
iwooos_progress = iwooos_projection["progress"]
assert_equal("iwooos_projection.progress.overall_percent", iwooos_progress["overall_percent"], progress["overall_percent"])
assert_equal(
@@ -2663,6 +2679,107 @@ def validate(root: Path) -> None:
f"iwooos_projection.host_owner_decision_record_formal_record_queue_review_outcome_lanes.{item['lane_id']}.not_authorization",
item["not_authorization"],
)
iwooos_host_owner_decision_record_human_handoff_readiness_packets = iwooos_projection[
"host_owner_decision_record_human_handoff_readiness_packets"
]
assert_equal(
"iwooos_projection.host_owner_decision_record_human_handoff_readiness_packets.ids",
[item["packet_id"] for item in iwooos_host_owner_decision_record_human_handoff_readiness_packets],
expected_iwooos_host_owner_decision_record_human_handoff_readiness_packet_ids,
)
assert_equal(
"iwooos_projection.host_owner_decision_record_human_handoff_readiness_packets.display_order",
[item["display_order"] for item in iwooos_host_owner_decision_record_human_handoff_readiness_packets],
list(range(1, len(expected_iwooos_host_owner_decision_record_human_handoff_readiness_packet_ids) + 1)),
)
expected_iwooos_host_owner_decision_record_human_handoff_readiness_fields = [
"record_identity_and_trace",
"human_record_owner_contact_boundary",
"decision_summary_and_no_execution_statement",
"approved_scope_and_expiry_window",
"observe_only_and_future_scan_limits",
"metadata_only_credential_boundary",
"maintenance_constraints_and_rollback_owner",
"independent_runtime_gate_and_no_action_buttons",
]
assert_equal(
"iwooos_projection.host_owner_decision_record_human_handoff_readiness_packets.readiness_fields",
[item["readiness_field"] for item in iwooos_host_owner_decision_record_human_handoff_readiness_packets],
expected_iwooos_host_owner_decision_record_human_handoff_readiness_fields,
)
for item in iwooos_host_owner_decision_record_human_handoff_readiness_packets:
assert_equal(
f"iwooos_projection.host_owner_decision_record_human_handoff_readiness_packets.{item['packet_id']}.display_mode",
item["display_mode"],
"owner_decision_record_human_handoff_readiness_only",
)
assert_equal(
f"iwooos_projection.host_owner_decision_record_human_handoff_readiness_packets.{item['packet_id']}.source_outcome_lane_id",
item["source_outcome_lane_id"],
"host_decision_record_formal_record_queue_review_ready_for_human_record_owner_handoff_outcome_lane",
)
assert_equal(
f"iwooos_projection.host_owner_decision_record_human_handoff_readiness_packets.{item['packet_id']}.human_record_owner_handoff_started_count",
item["human_record_owner_handoff_started_count"],
0,
)
assert_equal(
f"iwooos_projection.host_owner_decision_record_human_handoff_readiness_packets.{item['packet_id']}.human_record_owner_handoff_ready_count",
item["human_record_owner_handoff_ready_count"],
0,
)
assert_equal(
f"iwooos_projection.host_owner_decision_record_human_handoff_readiness_packets.{item['packet_id']}.formal_record_queue_review_passed_count",
item["formal_record_queue_review_passed_count"],
0,
)
assert_equal(
f"iwooos_projection.host_owner_decision_record_human_handoff_readiness_packets.{item['packet_id']}.formal_record_queue_enqueued_count",
item["formal_record_queue_enqueued_count"],
0,
)
assert_false(
f"iwooos_projection.host_owner_decision_record_human_handoff_readiness_packets.{item['packet_id']}.decision_record_created",
item["decision_record_created"],
)
assert_equal(
f"iwooos_projection.host_owner_decision_record_human_handoff_readiness_packets.{item['packet_id']}.owner_decision_received_count",
item["owner_decision_received_count"],
0,
)
assert_equal(
f"iwooos_projection.host_owner_decision_record_human_handoff_readiness_packets.{item['packet_id']}.owner_decision_accepted_count",
item["owner_decision_accepted_count"],
0,
)
assert_false(
f"iwooos_projection.host_owner_decision_record_human_handoff_readiness_packets.{item['packet_id']}.owner_approval_record_created",
item["owner_approval_record_created"],
)
assert_false(
f"iwooos_projection.host_owner_decision_record_human_handoff_readiness_packets.{item['packet_id']}.runtime_gate_opened",
item["runtime_gate_opened"],
)
assert_false(
f"iwooos_projection.host_owner_decision_record_human_handoff_readiness_packets.{item['packet_id']}.raw_payload_allowed",
item["raw_payload_allowed"],
)
assert_false(
f"iwooos_projection.host_owner_decision_record_human_handoff_readiness_packets.{item['packet_id']}.secret_value_collection_allowed",
item["secret_value_collection_allowed"],
)
assert_false(
f"iwooos_projection.host_owner_decision_record_human_handoff_readiness_packets.{item['packet_id']}.runtime_execution_authorized",
item["runtime_execution_authorized"],
)
assert_false(
f"iwooos_projection.host_owner_decision_record_human_handoff_readiness_packets.{item['packet_id']}.action_buttons_allowed",
item["action_buttons_allowed"],
)
assert_true(
f"iwooos_projection.host_owner_decision_record_human_handoff_readiness_packets.{item['packet_id']}.not_authorization",
item["not_authorization"],
)
assert_equal(
"iwooos_projection.non_blocking_lane_ids",
iwooos_projection["non_blocking_lane_ids"],
@@ -2709,6 +2826,7 @@ def validate(root: Path) -> None:
"display_host_owner_decision_record_formal_record_queue_packets",
"display_host_owner_decision_record_formal_record_queue_review_checklist",
"display_host_owner_decision_record_formal_record_queue_review_outcome_lanes",
"display_host_owner_decision_record_human_handoff_readiness_packets",
"display_evidence_refs",
"display_forbidden_actions",
]:
@@ -2814,6 +2932,11 @@ def validate(root: Path) -> None:
"enqueue_host_owner_decision_record_from_formal_record_queue_review_outcome",
"create_host_owner_decision_record_from_formal_record_queue_review_outcome",
"open_runtime_gate_from_formal_record_queue_review_outcome",
"treat_host_owner_decision_record_handoff_readiness_as_approval",
"start_human_record_owner_handoff_from_readiness_packet",
"mark_human_record_owner_handoff_ready_from_frontend",
"create_host_owner_decision_record_from_handoff_readiness",
"open_runtime_gate_from_handoff_readiness",
"apply_runtime_blocking_control",
"switch_github_primary",
"production_deploy",