Files
mtusi2026lab4/evidence/tests/student-test-lb.md
T
ricoromaandClaude Opus 5.5 6551839807 docs: add upload-consistency verify evidence and report
Capture the cleaner pass under a paused S3 (row stays marked pending,
next pass removes it), re-run failure checks (32 of 32 with red runs of
the new checks), student tests and the isolated run on 87c48b9, and
describe the marked three-step cleanup and its rolling-update window in
the report.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-21 21:42:31 +03:00

5.4 KiB
Raw Blame History

make student_test через балансировщик

  • Дата: 2026-10-21, 18:35:35–18:36:25 UTC (пересъёмка после правок change upload-consistency по verify); счёт по модулям — повторный прогон 18:36–18:37 с тем же итогом (197 passed, 32 deselected).
  • Commit: 87c48b9; вне commit — только файлы evidence/ и REPORT.md второго этапа правок (код стенда собран из чистого дерева этого commit).
  • Стенд: рабочий mtusi-lab4 после make rolling_update с этого commit — BASE_URL=http://localhost:8080 (HAProxy), EXPECT_REPLICAS=2 (API_REPLICAS): реплики 17d8dd756626 и b3c055808ddf, PostgreSQL, Valkey, S3, уборщик cleaner на том же образе. Тесты реплик выполняются, проверки отказов (fault) — нет (-m 'not fault', их гоняет make failure_checks, failure-checks.md).
  • Что изменилось с прежнего снимка (commit 5b42bd2): три новых сценария по замечаниям verify — «Исход фиксации неизвестен» (attachments), «Загрузка дольше grace» и «Сбой уборки после удаления объекта» (storage-consistency, теперь 9 сценариев). Итог — 215 сценариев в 13 спеках, из них 36 покрыты проверками отказов (было 212 и 33); проверок отказов в наборе 32 (было 29), поэтому deselected — 32. Число выполняемых тестов то же — 197.
  • Файлы исключений сверки покрытия сняты на стенде лабы 4 (commit 8dc925e: evidence/cache/hits.md, evidence/auth/passwords-and-tokens.md, evidence/idempotency/replay-after-restart.md, evidence/replicas/test-persistence.md, evidence/attachments/failover.md, evidence/attachments/storage.md): test_exclusion_evidence_exists зелёный.

Итог

$ make student_test
coverage: 215 scenarios in 13 specs, 200 tested (36 by make failure_checks), 15 excluded
===================== 197 passed, 32 deselected in 48.84s ======================
exit=0

По модулям

  21 student-tests/test_api_conventions.py PASSED
  33 student-tests/test_attachments.py PASSED
   4 student-tests/test_chat_cache.py PASSED
  13 student-tests/test_chats.py PASSED
  12 student-tests/test_contract.py PASSED
   9 student-tests/test_coverage.py PASSED
   3 student-tests/test_data_storage.py PASSED
   4 student-tests/test_health.py PASSED
  20 student-tests/test_idempotency.py PASSED
  10 student-tests/test_identification.py PASSED
   2 student-tests/test_load_balancing.py PASSED
  15 student-tests/test_messages.py PASSED
  14 student-tests/test_pagination.py PASSED
   4 student-tests/test_race.py PASSED
  12 student-tests/test_rubric.py PASSED
  10 student-tests/test_sessions.py PASSED
  11 student-tests/test_users.py PASSED

Строки тестов реплик и гонок (-rsP)

uploaded via 17d8dd756626, downloaded via ['17d8dd756626', 'b3c055808ddf']
sent via 17d8dd756626, replayed via ['b3c055808ddf']
409 via ['17d8dd756626', 'b3c055808ddf']
one session, 20 requests: {'b3c055808ddf': 10, '17d8dd756626': 10}
written via 17d8dd756626, read via {'b3c055808ddf': 3, '17d8dd756626': 3}
race: 10 clients x 10 messages, statuses {201: 100}, max in flight 10; history: 100 messages, 100 unique ids, 4 pages by 30
username race: 10 clients, statuses {409: 9, 201: 1}, max in flight 10
key race: 10 clients, statuses {201: 10}, max in flight 10; history: 1 messages
key race: 10 clients, statuses {201: 10}, max in flight 10; history: 1 messages
key race through replicas: {'b3c055808ddf': 5, '17d8dd756626': 5}
  • Вложения лабы 4: 33 теста спека attachments (test_attachments.py) и пять сценариев рубрики «4» лабы 4 в test_rubric.py (слишком большой файл, повреждённое изображение, подмена MIME, чужое attachment_id, вложение другого чата): каждая ошибка клиента — 4xx в формате контракта, не 500. «Скачивание через другую реплику»: загрузку принял 17d8dd756626, оригинал отдал и b3c055808ddf.
  • Новый после verify тест test_filename_not_utf8 (сценарий «Имя не в UTF-8»): filename=a%FFb.png, a%C3.png, a%ED%A0%80b.png — 400, %C3%A9t%C3%A9.png — 201 с été.png. На коде до правки (8dc925e) все три первых давали 201 (U+FFFD вместо байта).
  • Уровень 4 лаб 2–3: 100 сообщений от 10 клиентов — 100 уникальных в истории; гонка регистрации — один 201; гонка одного ключа через реплики — одно сообщение.
  • Сверка покрытия: все 215 сценариев 13 спеков — тест (200, из них 36 проверками отказов, в том числе все 9 сценариев storage-consistency) или исключение с доказательством (15).