PASS: topology_and_limits {"api_replicas": 2, "broker": "Valkey Streams with AOF fsync always", "worker_processes": 2}
/Users/vanek/Desktop/VNPlabs/VNPlab6/mtusi2026lab6/.venv/bin/python scripts/check_contract.py
PASS: offline skeleton structure, local refs and Python syntax; application NOT tested.
/Users/vanek/Desktop/VNPlabs/VNPlab6/mtusi2026lab6/.venv/bin/python scripts/validate_openapi.py
PASS: full OpenAPI 3.1 and JSON Schema validation; application NOT tested.
/Users/vanek/Desktop/VNPlabs/VNPlab6/mtusi2026lab6/.venv/bin/python tests/smoke.py --base-url "http://127.0.0.1:63012"
PASS: lab6 public API scenario; infrastructure and grading evidence remain separate.
PASS: public_smoke_and_schema {}
PASS: 10 clients sent 100 messages; history contains exactly 100 unique messages.
test_chat_access (test_api.ApiTests.test_chat_access) ... ok
test_chat_pagination_and_cursor_owner (test_api.ApiTests.test_chat_pagination_and_cursor_owner) ... ok
test_cursor_cannot_be_used_for_another_chat_or_changed (test_api.ApiTests.test_cursor_cannot_be_used_for_another_chat_or_changed) ... ok
test_default_page_size (test_api.ApiTests.test_default_page_size) ... ok
test_duplicate_username (test_api.ApiTests.test_duplicate_username) ... ok
test_framework_errors_and_request_ids (test_api.ApiTests.test_framework_errors_and_request_ids) ... ok
test_identification_and_authentication_order (test_api.ApiTests.test_identification_and_authentication_order) ... ok
test_invalid_chat_members (test_api.ApiTests.test_invalid_chat_members) ... ok
test_invalid_chat_title (test_api.ApiTests.test_invalid_chat_title) ... ok
test_invalid_limits_and_cursors (test_api.ApiTests.test_invalid_limits_and_cursors) ... ok
test_invalid_message_fields (test_api.ApiTests.test_invalid_message_fields) ... ok
test_invalid_user_fields (test_api.ApiTests.test_invalid_user_fields) ... ok
test_malformed_json_and_encoding (test_api.ApiTests.test_malformed_json_and_encoding) ... ok
test_message_pagination_and_changing_limit (test_api.ApiTests.test_message_pagination_and_changing_limit) ... ok
test_unicode_and_text_preservation (test_api.ApiTests.test_unicode_and_text_preservation) ... ok
test_wrong_content_type (test_api.ApiTests.test_wrong_content_type) ... ok
test_access_and_authentication (test_attachments.AttachmentTests.test_access_and_authentication) ... ok
test_attachment_only_message_and_other_member (test_attachments.AttachmentTests.test_attachment_only_message_and_other_member) ... ok
test_chunked_limit_without_content_length (test_attachments.AttachmentTests.test_chunked_limit_without_content_length) ... ok
test_content_length_limit_before_body (test_attachments.AttachmentTests.test_content_length_limit_before_body) ... ok
test_corruption_and_mime_spoof (test_attachments.AttachmentTests.test_corruption_and_mime_spoof) ... ok
test_filename_rejected_before_storage (test_attachments.AttachmentTests.test_filename_rejected_before_storage) ... ok
test_foreign_and_unknown_attachment_ids (test_attachments.AttachmentTests.test_foreign_and_unknown_attachment_ids) ... ok
test_idempotency_includes_ordered_attachment_ids (test_attachments.AttachmentTests.test_idempotency_includes_ordered_attachment_ids) ... ok
test_invalid_attachment_lists (test_attachments.AttachmentTests.test_invalid_attachment_lists) ... ok
test_pixel_limit_before_decode (test_attachments.AttachmentTests.test_pixel_limit_before_decode) ... ok
test_png_and_jpeg_originals (test_attachments.AttachmentTests.test_png_and_jpeg_originals) ... ok
test_simultaneous_registration_of_one_username (test_concurrency.ConcurrencyTests.test_simultaneous_registration_of_one_username) ... ok
test_ten_clients_send_one_hundred_messages (test_concurrency.ConcurrencyTests.test_ten_clients_send_one_hundred_messages) ... ok
test_conflict_and_semantic_json_replay (test_idempotency.IdempotencyTests.test_conflict_and_semantic_json_replay) ... ok
test_key_format_and_missing_key (test_idempotency.IdempotencyTests.test_key_format_and_missing_key) ... ok
test_parallel_replay_across_replicas (test_idempotency.IdempotencyTests.test_parallel_replay_across_replicas) ... ok
test_replay_rechecks_session_and_access (test_idempotency.IdempotencyTests.test_replay_rechecks_session_and_access) ... ok
test_scope_is_user_and_chat (test_idempotency.IdempotencyTests.test_scope_is_user_and_chat) ... ok
test_logout_revokes_only_one_session (test_sessions.SessionTests.test_logout_revokes_only_one_session) ... ok
test_password_validation (test_sessions.SessionTests.test_password_validation) ... ok
test_sql_like_message_is_plain_text (test_sessions.SessionTests.test_sql_like_message_is_plain_text) ... ok
test_unicode_password_with_colon_and_private_response (test_sessions.SessionTests.test_unicode_password_with_colon_and_private_response) ... ok
test_wrong_password_and_basic_only_for_login (test_sessions.SessionTests.test_wrong_password_and_basic_only_for_login) ... ok

----------------------------------------------------------------------
Ran 39 tests in 7.761s

OK
PASS: student_api_regressions {}
PASS: worker_offline_api_broker_restart {"attachment_id": "ef3471d3-538e-4d3f-8406-edfb2e78d803", "job_id": "29387d95-7e9f-4d86-b645-024cb36049cf", "message_id": "4ae76a83-fddf-4d6a-aa4c-1dffe8910540", "variants": {"thumbnail": {"size": [256, 160], "bytes": 5813}, "crop": {"size": [128, 128], "bytes": 2462}, "optimized": {"size": [320, 200], "bytes": 2462}}}
PASS: outbox_crash_before_publish {"job_id": "630dde85-21c6-4a82-bcee-5ea7aafa21b8", "automatic_recovery": true}
PASS: outbox_crash_after_publish {"job_id": "5c9d0c57-07b5-41d9-951e-d07ed3ce2126", "automatic_recovery": true}
PASS: worker_crash_after_objects {"job_id": "e7e67187-45e2-49ad-b845-7c80952abaed", "attempt": 2, "canonical_objects": 4, "duplicate_noop": true}
PASS: worker_crash_before_ack {"job_id": "646cabc2-c06f-43a9-98ed-97a0ed430eef", "attempt": 1, "canonical_objects": 4, "duplicate_noop": true}
PASS: bounded_retry_failed_registry_replay {"job_id": "9f0223e7-c7f7-41ce-a6b6-a6b2a6827db7", "max_automatic_attempts": 5, "audit": [{"event": "processing", "attempt": 1, "error_code": null, "at": "2026-11-19T15:11:43.910272+00:00"}, {"event": "retry", "attempt": 1, "error_code": "storage_unavailable", "at": "2026-11-19T15:11:43.913931+00:00"}, {"event": "processing", "attempt": 2, "error_code": null, "at": "2026-11-19T15:11:44.162093+00:00"}, {"event": "retry", "attempt": 2, "error_code": "storage_unavailable", "at": "2026-11-19T15:11:44.163784+00:00"}, {"event": "processing", "attempt": 3, "error_code": null, "at": "2026-11-19T15:11:44.672423+00:00"}, {"event": "retry", "attempt": 3, "error_code": "storage_unavailable", "at": "2026-11-19T15:11:44.674937+00:00"}, {"event": "processing", "attempt": 4, "error_code": null, "at": "2026-11-19T15:11:45.176057+00:00"}, {"event": "retry", "attempt": 4, "error_code": "storage_unavailable", "at": "2026-11-19T15:11:45.17712+00:00"}, {"event": "processing", "attempt": 5, "error_code": null, "at": "2026-11-19T15:11:45.941529+00:00"}, {"event": "failed", "attempt": 5, "error_code": "retry_exhausted", "at": "2026-11-19T15:11:45.944804+00:00"}, {"event": "operator_replay", "attempt": 5, "error_code": null, "at": "2026-11-19T15:11:47.029399+00:00"}, {"event": "processing", "attempt": 6, "error_code": null, "at": "2026-11-19T15:11:47.203814+00:00"}, {"event": "ready", "attempt": 6, "error_code": null, "at": "2026-11-19T15:11:47.601272+00:00"}], "ready_replay_rejected": true}
PASS: permanent_error {"job_id": "28022e30-0cd6-4df1-a41b-56905cf4feda", "attempt": 1, "error_code": "invalid_image"}
PASS: image_subprocess_timeout {"job_id": "c0f7e1b2-59a1-496e-a60a-8ed3fdb19f59", "timeout_seconds": 5, "task_memory_mb": 640, "recovered": true}
PASS: image_subprocess_memory {"job_id": "f1e4caee-86d7-4185-9787-92687c0650a3", "timeout_seconds": 5, "task_memory_mb": 640, "recovered": true}
PASS: image_semantics {"cases": [{"case": "small_alpha_on_white", "variants": {"thumbnail": {"size": [17, 9], "bytes": 635}, "crop": {"size": [128, 128], "bytes": 883}, "optimized": {"size": [17, 9], "bytes": 56}}}, {"case": "exif_orientation_6_and_floor", "variants": {"thumbnail": {"size": [160, 256], "bytes": 1270}, "crop": {"size": [128, 128], "bytes": 886}, "optimized": {"size": [201, 321], "bytes": 210}}}]}
PASS: staging_cleanup {"active_preserved": true, "orphan_removed": true, "ready_removed": true, "expired_failed_removed": true, "expired_replay_rejected": true}
PASS: broker_offline_outbox {"attachment_id": "28321e5b-8b43-471a-973d-9b55cbc07b39", "recovered": true}
/Users/vanek/Desktop/VNPlabs/VNPlab6/mtusi2026lab6/.venv/bin/python tests/resilience.py --mode persistence --action-script "scripts/restart.sh" --base-url "http://127.0.0.1:63012"
Executing explicit persistence hook; hook output suppressed to avoid leaking secrets.
PASS: persistence preserved confirmed data and existing session. Hook scope needs operator evidence.
PASS: public_persistence {"restart_proof": {"passed": true, "before": {"ea2b13aebb92a1ea2741de72078489e6b05ebcc41f1ca74a2604c0ad7d355983": {"service": "api", "started_at": "2026-11-19T15:10:30.841890222Z", "volumes": []}, "67eade4e281a4cfed3f55d87ab398097e12ee12155f82cbe19eb240a4e92b41a": {"service": "api", "started_at": "2026-11-19T15:10:30.809775805Z", "volumes": []}, "d675c92d195a1bb37db5860c3cf49a2a918eb3e98cfd9c855f8f89931138724b": {"service": "broker", "started_at": "2026-11-19T15:12:24.444290385Z", "volumes": ["lab5-check-c81d43a829_broker_data"]}, "f9b2e0b6e448dda6d845d9715d64e1216fc0f3f58c3e05ec22de30d305c2d3e6": {"service": "cleanup", "started_at": "2026-11-19T15:10:11.903050713Z", "volumes": []}, "e4abde6d7d326be2a1425d81667ab967dd655ce1eb39c1b0c1bd2f9956f3e91f": {"service": "grafana", "started_at": "2026-11-19T15:09:46.76721934Z", "volumes": ["lab5-check-c81d43a829_grafana_data"]}, "1e9b604ee9fe91572a4efd3b629a00819d86ab2b45ed1f04a1df66428cfe1920": {"service": "lb", "started_at": "2026-11-19T15:10:17.66400909Z", "volumes": []}, "487c1937cced6d3b86d6a67cae2b76fdfc2b534e6cf15b6cf2242b96b19c8af4": {"service": "loki", "started_at": "2026-11-19T15:09:46.088598506Z", "volumes": ["lab5-check-c81d43a829_loki_data"]}, "f31970f75546cfcf6c390fad538eb9a7ebc25d26c481caef09bf679a5af8e8d9": {"service": "otel-collector", "started_at": "2026-11-19T15:09:46.409972798Z", "volumes": []}, "82576012c7b7b5a5a352207679f4c327fe50cbd5c56337de33c16ec15b2b0501": {"service": "postgres", "started_at": "2026-11-19T15:09:46.08945334Z", "volumes": ["lab5-check-c81d43a829_postgres_data"]}, "6e305e5121dc3113f906c5689d1006091714d72b452acaabd07e3d366f1d13f6": {"service": "prometheus", "started_at": "2026-11-19T15:09:46.555234256Z", "volumes": ["lab5-check-c81d43a829_prometheus_data"]}, "fb35c350ab7fcff516b44e4f6933b1e293c896e6cee9bf29d06e71ba99a0f931": {"service": "publisher", "started_at": "2026-11-19T15:12:10.913909129Z", "volumes": []}, "8cdcd8bdac73e3bc827ef7bc5a77bad0696c1023cd330eb10206dcc6b29529cf": {"service": "s3", "started_at": "2026-11-19T15:10:08.720162878Z", "volumes": ["d6e81fdf6ec0a4bd30cb0461085c08461b951f8ae9c696222d04b21152ff6560"]}, "053f3a4b4e5cd9b28510f08e9bd8d07374c586af075cb62d5c5b49f62af5a6ac": {"service": "s3-storage", "started_at": "2026-11-19T15:09:46.086474548Z", "volumes": ["lab5-check-c81d43a829_s3_data"]}, "84473a25dbb67b410a0db8d8b0e029b84b264b3238da1961c7693f13d9e99634": {"service": "tempo", "started_at": "2026-11-19T15:09:46.086451215Z", "volumes": ["lab5-check-c81d43a829_tempo_data"]}, "7f3ff970cf57bedf3a8800a6bed5cc3a83f749dab07d9ac42425d14c7eafee80": {"service": "valkey", "started_at": "2026-11-19T15:09:46.08714634Z", "volumes": ["lab5-check-c81d43a829_valkey_data"]}, "521131dedb68623718c9d5d5c8dc8b0924dbfe6ec90acd3b21e08189a9a1a1e5": {"service": "worker", "started_at": "2026-11-19T15:12:21.892301301Z", "volumes": []}}, "after": {"ea2b13aebb92a1ea2741de72078489e6b05ebcc41f1ca74a2604c0ad7d355983": {"service": "api", "started_at": "2026-11-19T15:12:30.097473346Z", "volumes": []}, "67eade4e281a4cfed3f55d87ab398097e12ee12155f82cbe19eb240a4e92b41a": {"service": "api", "started_at": "2026-11-19T15:12:30.048159138Z", "volumes": []}, "d675c92d195a1bb37db5860c3cf49a2a918eb3e98cfd9c855f8f89931138724b": {"service": "broker", "started_at": "2026-11-19T15:12:28.168864679Z", "volumes": ["lab5-check-c81d43a829_broker_data"]}, "f9b2e0b6e448dda6d845d9715d64e1216fc0f3f58c3e05ec22de30d305c2d3e6": {"service": "cleanup", "started_at": "2026-11-19T15:12:35.75098096Z", "volumes": []}, "e4abde6d7d326be2a1425d81667ab967dd655ce1eb39c1b0c1bd2f9956f3e91f": {"service": "grafana", "started_at": "2026-11-19T15:12:28.016722095Z", "volumes": ["lab5-check-c81d43a829_grafana_data"]}, "1e9b604ee9fe91572a4efd3b629a00819d86ab2b45ed1f04a1df66428cfe1920": {"service": "lb", "started_at": "2026-11-19T15:12:27.799505637Z", "volumes": []}, "487c1937cced6d3b86d6a67cae2b76fdfc2b534e6cf15b6cf2242b96b19c8af4": {"service": "loki", "started_at": "2026-11-19T15:12:29.867573388Z", "volumes": ["lab5-check-c81d43a829_loki_data"]}, "f31970f75546cfcf6c390fad538eb9a7ebc25d26c481caef09bf679a5af8e8d9": {"service": "otel-collector", "started_at": "2026-11-19T15:12:29.704735929Z", "volumes": []}, "82576012c7b7b5a5a352207679f4c327fe50cbd5c56337de33c16ec15b2b0501": {"service": "postgres", "started_at": "2026-11-19T15:12:28.084774804Z", "volumes": ["lab5-check-c81d43a829_postgres_data"]}, "6e305e5121dc3113f906c5689d1006091714d72b452acaabd07e3d366f1d13f6": {"service": "prometheus", "started_at": "2026-11-19T15:12:28.052574179Z", "volumes": ["lab5-check-c81d43a829_prometheus_data"]}, "fb35c350ab7fcff516b44e4f6933b1e293c896e6cee9bf29d06e71ba99a0f931": {"service": "publisher", "started_at": "2026-11-19T15:12:35.770825668Z", "volumes": []}, "8cdcd8bdac73e3bc827ef7bc5a77bad0696c1023cd330eb10206dcc6b29529cf": {"service": "s3", "started_at": "2026-11-19T15:12:28.115603887Z", "volumes": ["d6e81fdf6ec0a4bd30cb0461085c08461b951f8ae9c696222d04b21152ff6560"]}, "053f3a4b4e5cd9b28510f08e9bd8d07374c586af075cb62d5c5b49f62af5a6ac": {"service": "s3-storage", "started_at": "2026-11-19T15:12:35.714312418Z", "volumes": ["lab5-check-c81d43a829_s3_data"]}, "84473a25dbb67b410a0db8d8b0e029b84b264b3238da1961c7693f13d9e99634": {"service": "tempo", "started_at": "2026-11-19T15:12:28.142091095Z", "volumes": ["lab5-check-c81d43a829_tempo_data"]}, "7f3ff970cf57bedf3a8800a6bed5cc3a83f749dab07d9ac42425d14c7eafee80": {"service": "valkey", "started_at": "2026-11-19T15:12:28.230646637Z", "volumes": ["lab5-check-c81d43a829_valkey_data"]}, "521131dedb68623718c9d5d5c8dc8b0924dbfe6ec90acd3b21e08189a9a1a1e5": {"service": "worker", "started_at": "2026-11-19T15:12:27.946355887Z", "volumes": []}}, "same_containers_and_volumes": true}}
/Users/vanek/Desktop/VNPlabs/VNPlab6/mtusi2026lab6/.venv/bin/python tests/resilience.py --mode failover --action-script "scripts/stop-one.sh" --base-url "http://127.0.0.1:63012"
Executing explicit failover hook; hook output suppressed to avoid leaking secrets.
{"observed_instances_before": 2, "successful_writes": 110, "failed_attempts": 1, "first_recovery_seconds": 2.561}
PASS: failover preserved confirmed data and existing session. Hook scope needs operator evidence.
PASS: public_api_failover {}
PASS: all lab5 grade-4 criteria completed
Removed isolated test stack: lab5-check-c81d43a829
