Skip to content

Question Inheritance

The page at /admin/question-inheritance is a read-only inspect tool. It shows how live league defaults, question groups, and a selected definition combine right now.

It does not apply match overrides, and it does not replay what a match used at play time. Match overrides live on Matches. To see why a published question issued, use Issuance Explorer.

Edit values on League Defaults, Question groups, Question Definitions, or Match Questions. This page does not write.

Data source

The admin page is a thin HTML shell. Alpine.js loads:

  • League ids via GET /api/leagues
  • Inspect payload via GET /api/leagues/{id}/question-inheritance

Query: kind=in_game|match and definition_id (fills group / definition columns). The inspect API also accepts a match id and returns issuance traces; this page calls the league endpoint only and ignores traces.

Deep-link: ?league=&kind=&definition_id=. If issuance_id is present, the page redirects to Issuance Explorer.

How to read it

Panel Meaning
Definition Starting point. Pick an in-game question definition or Match question definition.
Layer chips League, group (in-game), definition. Open jumps to that layer’s edit page.
Settings Live league / group / definition now. Highlighted cells win (override) or also apply (AND / max). inherit = this layer can set a value but did not. n/a = the setting does not exist on that layer. Click a row for the one-line why.

Allowlists: NULL = all active; [] = none. Ignore-period skips only the match-wide period map. Ignore-max skips only the match-wide max. Neither skips definition issuance_max_count / issuance_period_distribution or the group map. Pivotal caps ignore those flags.

{} = Issue ASAP (no period caps). [] / {dist: even} = even-fill not yet materialized (match-wide); group even = 1 per registered key, or an even split of max_per_match when that ceiling is set; definition even = 1 per registered key.

Workflow

  1. Open Manage → Question Inheritance.
  2. Pick a league.
  3. Toggle In-game vs Match Questions.
  4. Select a definition to fill group and definition columns.

Code map

Concern Location
REST inspect GET /api/leagues/{id}/question-inheritance, GET /api/matches/{id}/question-inheritance
Ops + schemas src/lib/question_inheritance/
Admin HTML shell src/api/admin/routes/question_inheritance.py
Template src/api/admin/templates/question_inheritance/index.jinja2
Alpine app src/api/admin/static/js/question_inheritance_app.js
CSS src/api/admin/static/css/question_inheritance.css
Tests src/api/tests/admin/test_question_inheritance.py, src/api/tests/test_question_inheritance.py