gitoria

tracker

All repositories: gitoria

ReadmeCodePull requestsReleasesTicketsSettings
Commit3e164b633e164b63Tracker: status after CL1mre3e164b63/tools/count-incomplete.hl

2.5 KB

  1. // tools/count-incomplete.hl — tracker#33 (mission 029): how many titles are still REDUCED. ONLY on a COPY or a stopped app (opening
  2. // a table rewrites its files; hl:mpackdb: one process per storage):
  3. // TRACKER_STORAGE=$PWD/.scratch/<copy>/storage/mpackdb ./bin/hybriel tools/count-incomplete.hl [--list]
  4. // Counts every live (not merged) non-adult title the details repair still has to do (details.hl needsDetails = shows.hl
  5. // isIncomplete: TMDB's details never went through this app) — by type and origin (migrated / filmography fill / search import)
  6. // and by what its page misses (shows.hl missingParts). Then the COMPLETE titles that still miss a part — TMDB has none (The
  7. // Remaining: no poster, no IMDb id). The last line is the answer: `reduced titles: N` (0 after the repair). `--list` also prints
  8. // every reduced title (type, slug, missing parts). A title whose adult flag is still unknown (adult backfill: TMDB 404) is
  9. // counted too, apart — its completion asks TMDB once more (404 → `detailsCheck`, adult → the flag; never shown either way).
  10. import { args } from 'hl:proc'
  11. import { allShows, missingParts } from '../lib/shows.hl'
  12. import { needsDetails } from '../lib/details.hl'
  13. list = args().includes('--list')
  14. reduced = {}
  15. missing = {}
  16. completeMissing = {}
  17. let total = 0
  18. let n = 0
  19. let adult = 0
  20. for (s of allShows()) {
  21. if (s.mergedInto == null && s.tmdbId != null) {
  22. total = total + 1
  23. if (s.adult == true) { adult = adult + 1 }
  24. let parts = missingParts(s)
  25. if (needsDetails(s)) {
  26. n = n + 1
  27. let origin = s.minimal == true ? 'fill' : (s.oldId != null && ('' + s.oldId).slice(0, 5) == 'tmdb-' ? 'import' : 'migrated')
  28. let k = s.type + ' ' + origin + (s.adult == null ? ' (adult flag unknown)' : '')
  29. reduced[k] = reduced[k] == null ? 1 : reduced[k] + 1
  30. for (p of parts) { missing[p] = missing[p] == null ? 1 : missing[p] + 1 }
  31. if (parts.length > 0) { missing['any'] = missing['any'] == null ? 1 : missing['any'] + 1 }
  32. if (list) { console.log('reduced ' + s.type + ' ' + s.urlSegment + ' ' + parts.join(',')) }
  33. } else if (s.adult != true) {
  34. for (p of parts) { completeMissing[p] = completeMissing[p] == null ? 1 : completeMissing[p] + 1 }
  35. }
  36. }
  37. }
  38. console.log('titles with a TMDB id: ' + total + ' (adult ' + adult + ', never completed)')
  39. for (k of reduced.keys()) { console.log(' reduced ' + k + ': ' + reduced[k]) }
  40. console.log(' their pages miss: ' + JSON.stringify(missing))
  41. console.log('complete titles missing a part (TMDB has none): ' + JSON.stringify(completeMissing))
  42. console.log('reduced titles: ' + n)

Branches

Latest commits

  • 3e164b63Tracker: status after CL1mre
  • 9d686bb3Tracker: CL1 reviewedmre
  • b8bba562CL1: crash loop report (SIGPIPE confirmed, trap wrapper option)mre
  • 298785f2Tracker: CL1 startedmre
  • 36b22710Tracker: port slot, CL1 briefmre
  • a401190fTracker: GO for the crash loopmre
  • e195d372Tracker: token pathsmre
  • 7f541d11Tracker conductor: CONDUCTOR.md, short STATUS.md, old status + decisions archive to archive/2026-10-31mre
  • 8dd423f7README: login.js stays by caramboleyo's explicit rulemre
  • d8df1493tracker: standby service on port 45018 and a gap-free hand-over in deploy.sh step 4mre
  • 36dd1686ident#31: the selector's sign-in returns to the page the user started on (return attribute = the login callback with next), gate checkmre
  • ff9b838etracker: the Ended status pill uses the same red as layouts (pill danger); gate updatedmre
  • 40d9719eTP2: LOG line and report for the tracker pillsmre
  • ab3f2ba5tracker: status, genres, TMDB/IMDb/TVDB/TVmaze links and list kinds use the theme's pill; dense season list with the season check centred on its title line; gates for bothmre
  • 521061d6tracker header on phones: signed in, the brand fits whole at 360 and 390 px (tighter gaps and side paddings, slightly smaller brand, narrow screens and signed in only); mobile gate checks itmre
  • 18114a53tracker: franchises gate waits for the signed-out selector instead of the removed Log in buttonmre
  • 08561d73ident selector back in the header (creator 2026-10-24): selector top right signed in and out on phone and desktop, no second Log in button, new gate checks (WIP: gates not re-run after the last edits)mre
  • 59ef1e4atests/browser: repair 'done' check counts the 404 titles the first run already finished (race: failed=1 when Bulk Film 79 ran before the restart)mre
  • 5925fc4dreports/MK-mobile.md: rebase update, gate countsmre
  • 6adbc7f0extlink badges: background-clip after the background shorthand (it reset the clip: the pills were 44 px tall); gates check the lookmre