ikke flyttet endnu: gameplay endpoints, reveal->scoreboard transition eller bred session-detail refaktor
Test
.venv/bin/python manage.py test fupogfakta.tests.FupOgFaktaExtractionSliceTests lobby.tests.StartRoundTests lobby.tests.GuessSubmissionTests lobby.tests.RevealRoundFlowTests --verbosity=1
Refs #312
## Hvad er lavet
- flyttet første FupOgFakta-specifikke helper-slice ud af `lobby/views.py` til cartridge-moduler:
- `fupogfakta/services.py`
- `fupogfakta/payloads.py`
- beholdt `lobby/views.py` som facade via importerede aliaser, så endpoint-kontrakter og eksisterende patches/tests ikke blev bredt refaktoreret
- tilføjet målrettede cartridge-tests i `fupogfakta/tests.py`
- beholdt og udbygget issue-artifactet i `docs/ISSUE-312-LOBBY-FUPOGFAKTA-EXTRACTION-MAP.md`
## Scope / boundary
Dette er kun første extraction-slice for #312:
- flyttet: round-question query/selection, mixed-answer prep, score resolution, lie/reveal/leaderboard payload builders
- ikke flyttet endnu: gameplay endpoints, reveal->scoreboard transition eller bred session-detail refaktor
## Test
- `.venv/bin/python manage.py test fupogfakta.tests.FupOgFaktaExtractionSliceTests lobby.tests.StartRoundTests lobby.tests.GuessSubmissionTests lobby.tests.RevealRoundFlowTests --verbosity=1`
CI is red for CI / test-and-quality on this head SHA.
The failure matches the code state in lobby/views.py: the PR imports _build_leaderboard, _build_lie_started_payload, _build_reveal_payload, _get_current_round_question, _prepare_mixed_answers, _resolve_scores, and _select_round_question from the new extraction modules, but the file still defines functions with those exact names locally. That means the imported names are immediately redefined, so the extraction is effectively unused and lint should fail on redefinition/unused-import noise.
Please either remove the old local helper implementations and use the extracted modules, or drop the new imports until the extraction is wired through cleanly. When a new head SHA is up and CI is green, review can re-run.
Blocker: this SHA is not merge-klar anymore.
- CI is red for `CI / test-and-quality` on this head SHA.
- The failure matches the code state in `lobby/views.py`: the PR imports `_build_leaderboard`, `_build_lie_started_payload`, `_build_reveal_payload`, `_get_current_round_question`, `_prepare_mixed_answers`, `_resolve_scores`, and `_select_round_question` from the new extraction modules, but the file still defines functions with those exact names locally. That means the imported names are immediately redefined, so the extraction is effectively unused and lint should fail on redefinition/unused-import noise.
Please either remove the old local helper implementations and use the extracted modules, or drop the new imports until the extraction is wired through cleanly. When a new head SHA is up and CI is green, review can re-run.
God refaktorering på denne head SHA (7de843e44b). Den opfølgende fix fjerner de gamle lokale helper-definitioner i lobby/views.py, så view-laget bruger de udtrukne fupogfakta-moduler rent. CI er grøn på både push og pull_request, og jeg fandt ingen nye blockers i denne SHA.
God refaktorering på denne head SHA (7de843e44bb87f3ff823c949b07c8115ffb26f72). Den opfølgende fix fjerner de gamle lokale helper-definitioner i lobby/views.py, så view-laget bruger de udtrukne fupogfakta-moduler rent. CI er grøn på både push og pull_request, og jeg fandt ingen nye blockers i denne SHA.
Kort check: /healthz OK, migrate --check --noinput OK, manage.py smoke_staging OK.
Tester-status: ny staging deploy verificeret efter seneste smoke, og staging smoke er nu grøn.
- Deployeret build observeret på staging: app-dir opdateret 2026-03-17 06:54:48 UTC
- Smoke artifact: `/opt/wpp-staging/app/artifacts/smoke/smoke-20260317T073117Z.json`
- Resultat: PASS
Kort check: `/healthz` OK, `migrate --check --noinput` OK, `manage.py smoke_staging` OK.
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
Refs #312
Hvad er lavet
lobby/views.pytil cartridge-moduler:fupogfakta/services.pyfupogfakta/payloads.pylobby/views.pysom facade via importerede aliaser, så endpoint-kontrakter og eksisterende patches/tests ikke blev bredt refaktoreretfupogfakta/tests.pydocs/ISSUE-312-LOBBY-FUPOGFAKTA-EXTRACTION-MAP.mdScope / boundary
Dette er kun første extraction-slice for #312:
Test
.venv/bin/python manage.py test fupogfakta.tests.FupOgFaktaExtractionSliceTests lobby.tests.StartRoundTests lobby.tests.GuessSubmissionTests lobby.tests.RevealRoundFlowTests --verbosity=1God refaktorering. Udtrækket af payload/service-hjælpere er sammenhængende, testdækket, og jeg fandt ingen blockers i denne slice.
New commits pushed, approval review dismissed automatically according to repository settings
Blocker: this SHA is not merge-klar anymore.
CI / test-and-qualityon this head SHA.lobby/views.py: the PR imports_build_leaderboard,_build_lie_started_payload,_build_reveal_payload,_get_current_round_question,_prepare_mixed_answers,_resolve_scores, and_select_round_questionfrom the new extraction modules, but the file still defines functions with those exact names locally. That means the imported names are immediately redefined, so the extraction is effectively unused and lint should fail on redefinition/unused-import noise.Please either remove the old local helper implementations and use the extracted modules, or drop the new imports until the extraction is wired through cleanly. When a new head SHA is up and CI is green, review can re-run.
God refaktorering på denne head SHA (
7de843e44b). Den opfølgende fix fjerner de gamle lokale helper-definitioner i lobby/views.py, så view-laget bruger de udtrukne fupogfakta-moduler rent. CI er grøn på både push og pull_request, og jeg fandt ingen nye blockers i denne SHA.Tester-status: ny staging deploy verificeret efter seneste smoke, og staging smoke er nu grøn.
/opt/wpp-staging/app/artifacts/smoke/smoke-20260317T073117Z.jsonKort check:
/healthzOK,migrate --check --noinputOK,manage.py smoke_stagingOK.