---
title: Prune stale rows of unused league formats
type: task
status: completed
description: >-
  Formats no 2026 league uses hold 2026 projection rows the hourly run never refreshes; re-measure
  with the existing prune script and put the new orphans to the operator.
base_uri: user:task/league/prune-stale-rows-of-unused-league-formats.md
created_at: '2026-10-29T22:36:37.217Z'
entity_id: 8eb5cad5-d158-42be-94cf-2ed016fab428
finished_at: '2026-10-30T02:31:56.753Z'
observations:
  - ████████████████████████████████████████████████
  - ████████████████████████████████████████████████
  - ████████████████████████████████████████████████
  - ████████████████████████████████████████████████
  - ████████████████████████████████████████████████
  - ████████████████████████████████████████████████
  - ████████████████████████████████████████████████
owner_identity_uri: █████████████████████████
priority: Low
public_read: true
relations:
  - relates [[███████████████████████-██████-████████-██████-██████████]]
  - relates [[███████████████████████-████-███████████-████-██████-██████-██████████]]
tags:
  - user:tag/league-xo-football.md
updated_at: '2026-10-30T02:39:57.091Z'
visibility_analyzed_at: '2026-11-05T23:49:51.172Z'
---

## Problem

Formats that no 2026 league uses still hold 2026 projection rows the hourly run never refreshes, so they go stale from week to week (measured 2026-10-29):

- 46 league formats hold 2026 rows in `league_format_player_projection_values` (425,044 rows) and its rest-of-season and season siblings. 36-38 of them have no `seasons` row; 10 are used only by past seasons.
- 46 scoring formats hold 2026 points rows (1,093,112 weekly). 31 of them, including `c04dc7b4`, `c76d2425` and `f5aa57a4`, have no live configuration reference, being referenced only by league formats no season uses. The other 15 are still referenced, and `b7855f1f` is pinned by 3 saved data views.

`scripts/prune-orphan-league-formats.mjs` already deletes an orphan format with its derived rows and protects pinned formats and the sfb15 pair, but nothing schedules it. The operator ruled KEEP on 11 held league formats on 2026-09-19 (`████████████████████████████████████████████████████████`); about 26 orphans have appeared since.

## Plan

- [x] Re-measure with the prune script's dry run (`NODE_ENV=production node scripts/prune-orphan-league-formats.mjs` without `--confirm`), split into the 11 formats under the 2026-09-19 KEEP ruling and the new orphans.
- [x] Put the new orphans to the operator for a prune ruling, with the dry-run counts; prune the approved set with `--confirm`.
- [x] Decide what the 2026 rows of formats used only by past seasons should be: stop writing them, or refresh them hourly. Neither should leave a stale current-season row that a pinned view can read.

## Done when

No format holds a current-season row that nothing refreshes, and every remaining orphan format is under an operator ruling.
