gitoriaLog in with ident

tracker

All repositories: gitoria

ReadmeCodePull requestsReleasesTicketsSettings
Commit06b078e306b078e3tracker mission 028 (code order) 3/5 project.hl is the map: config, routes, wiring and a feature → file index (914 → 258 lines); the background jobs (daily sync run, backfills, details repair, credits job, merge, short ids, collection seed) moved unchanged into lib/jobs.hl (a class: their state is reassigned every step, a static cannot be; one instance made after the server), the login callback into lib/users.hl, poster/photo serving into lib/images.hl, the /shows/<slug> rule into lib/shows.hl showsMovedPath; route handlers are thin wrappers; gates 342/0, 32/0, 52/0, real-copy pages identicalmre06b078e3/project.hl

17.0 KB

  1. // project.hl — tracker.worldapi.org: THE MAP (mission 028, docs: README "Files"). Config, the routes and how the parts are wired;
  2. // what each feature does is in the file named here, not in this one.
  3. //
  4. // login (ident only, the header's selector + button) lib/users.hl, components/main.hl, login.js, /login/* below
  5. // titles: records, slugs, kinds, list caches lib/shows.hl a title's page: components/show.hl
  6. // public lists /movies /series /shows /genres, home lib/catalog.hl components/{movies,allseries,allshows,genre,home,tilelist}.hl
  7. // follows · watches · /my/* lib/follows.hl · lib/watches.hl · components/{myshows,mymovies,unwatched,schedule}.hl
  8. // search, web search, import lib/search.hl (+ search-helpers.hl) components/search.hl
  9. // people, a person's page and filmography fill lib/people.hl components/person.hl
  10. // cast + crew, the credits job lib/credits.hl (+ credits-helpers.hl)
  11. // a title completed from TMDB (details repair) lib/details.hl
  12. // TMDB / TVmaze requests, posters lib/tmdb.hl
  13. // the sync of one title · which titles a day lib/sync.hl (+ sync-helpers.hl) · lib/dailysync.hl
  14. // adult flag + kind backfills lib/backfill.hl
  15. // short ids (/<shortId>) lib/shortids.hl
  16. // franchises + timelines · TMDB collection seed lib/franchises.hl · lib/collections.hl components/franchise*.hl, timelineedit.hl
  17. // duplicate titles merged lib/merge.hl
  18. // the background jobs and their clocks lib/jobs.hl (one instance, made below after the server)
  19. // poster + photo files lib/images.hl
  20. // shared helpers (env, paths, dates, ids, lists) lib/util.hl
  21. // styles · design tokens components/styles.hl · shared/tokens.hl
  22. //
  23. // Config (env; no committed secret — the first deploy registers this app in ident and sets these, done by the architect, as
  24. // with ident's own .env for SMTP): TRACKER_PORT (45008), TRACKER_URL (this app's own public address, for the return URL),
  25. // IDENT_URL (https://ident.worldapi.org), TRACKER_KEY (pk_…), TRACKER_SECRET (sk_…), TRACKER_STORAGE, TRACKER_SESSIONS,
  26. // TRACKER_WATCH, TMDB_READ_TOKEN; the jobs' switches and limits: lib/jobs.hl (README "Config").
  27. import WebFramework from 'hl:web'
  28. import { Response } from 'hl:http1'
  29. import { env } from 'hl:proc'
  30. import { now } from 'hl:time'
  31. import Styles from './components/styles.hl'
  32. import Home from './components/home.hl'
  33. import LoginFailed from './components/loginfailed.hl'
  34. import Show from './components/show.hl'
  35. import Unwatched from './components/unwatched.hl'
  36. import Schedule from './components/schedule.hl'
  37. import MyShows from './components/myshows.hl'
  38. import MyMovies from './components/mymovies.hl'
  39. import Movies from './components/movies.hl'
  40. import AllShows from './components/allshows.hl'
  41. import AllSeries from './components/allseries.hl'
  42. import Search from './components/search.hl'
  43. import Person from './components/person.hl'
  44. import Genre from './components/genre.hl'
  45. import Franchises from './components/franchises.hl'
  46. import Franchise from './components/franchise.hl'
  47. import FranchiseEdit from './components/franchiseedit.hl'
  48. import TimelineEdit from './components/timelineedit.hl'
  49. import { dark, darker } from './shared/tokens.hl'
  50. import { postersDir, profilesDir } from './lib/util.hl'
  51. import { loginCallbackOf } from './lib/users.hl'
  52. import { imageResponse, isSafePosterName } from './lib/images.hl'
  53. import { ensureIndex } from './lib/search.hl'
  54. import { showsMovedPath, warmTitleCaches, warmEpisodeKeys, movedSlugs, movedPathOf, personById } from './lib/shows.hl'
  55. import { allWatchedEpisodeIds } from './lib/watches.hl'
  56. import { allFollowedShowIds } from './lib/follows.hl'
  57. import { ensureShortIds, shortIdPath } from './lib/shortids.hl'
  58. import { guestPersonId } from './lib/people.hl'
  59. import { moveCopiedSummaries } from './lib/dailysync.hl'
  60. import { ensureFranchises } from './lib/franchises.hl'
  61. import Jobs from './lib/jobs.hl'
  62. static appTitle = "tracker"
  63. // ---- THE INSTALLABLE APP (tracker.worldapi.org#10), the same way calendar.worldapi.org does it: hl:web's own web app
  64. // manifest (/__hl/manifest.webmanifest, linked from every head with the apple-touch-icon and theme-color) and service
  65. // worker (/__hl/sw.js) from these settings — no JavaScript of ours. Icons in icons/ (icon.svg is the source, the PNGs
  66. // are rendered from it with rsvg-convert, README "Icons"). The theme colour is the header's background (darker), the
  67. // splash background the page's (dark) — both off the tokens, not written out again.
  68. appThemeColor = darker.value
  69. appBackgroundColor = dark.value
  70. appIcons = [
  71. { src = '/icons/icon-192.png' sizes = '192x192' purpose = 'any' }
  72. { src = '/icons/icon-512.png' sizes = '512x512' purpose = 'any' }
  73. { src = '/icons/icon-192.png' sizes = '192x192' purpose = 'maskable' }
  74. { src = '/icons/icon-512.png' sizes = '512x512' purpose = 'maskable' }
  75. ]
  76. appTouchIcon = '/icons/apple-touch-icon.png'
  77. appFavicon = '/icons/favicon.svg'
  78. // OFFLINE: only the shell — the header and `/` (components/main.hl says "You are offline" while the browser has no
  79. // network). The data pages are not kept: without a network they get hl:web's "Unavailable offline" page.
  80. offline = [ Home ]
  81. styles = Styles
  82. port = env('TRACKER_PORT') != null ? toNumber(env('TRACKER_PORT')) : 45008
  83. watching = env('TRACKER_WATCH') != '0'
  84. // read by hl:web's own manifest config (WebFramework.hl `cfg.sessionDir`), not the constructor call below
  85. sessionDir = env('TRACKER_SESSIONS') != null ? env('TRACKER_SESSIONS') : null
  86. // ---- the function routes: each checks its input, asks the topic, answers ---------------------------------------------------
  87. // /login/callback?ident_code=… (lib/users.hl): the code exchanged, this app's session signed in, back to the page (`?next=`)
  88. loginCallback = (&route, &req) => { return loginCallbackOf(server.sessions, req) }
  89. // /posters/<name>, /profiles/<name> (lib/images.hl): the file, else the placeholder
  90. posterRoute = (&route, &req) => { return imageResponse(postersDir, route.params != null ? route.params.name : null, 'poster') }
  91. profileRoute = (&route, &req) => { return imageResponse(profilesDir, route.params != null ? route.params.name : null, 'photo') }
  92. // the old addresses of the personal lists (tracker.worldapi.org#8): they all live under /my/ now — a permanent redirect so old
  93. // links keep working (architect's decision)
  94. movedTo = (&path) => { return new Response('moved to ' + path, { status = 301 headers = { 'Location' = path 'Content-Type' = 'text/plain; charset=utf-8' } }) }
  95. notFoundText = (&text) => { return new Response(text, { status = 404 headers = { 'Content-Type' = 'text/plain; charset=utf-8' } }) }
  96. unwatchedMoved = (&route, &req) => { return movedTo('/my/unwatched') }
  97. scheduleMoved = (&route, &req) => { return movedTo('/my/schedule') }
  98. // mission 058: the show page's genre pills linked `/genre/<x>` (no page there) — the genre pages are `/genres/<x>`
  99. genreMoved = (&route, &req) => {
  100. let g = route.params != null ? route.params.genre : null
  101. return movedTo(isSafePosterName(g) ? '/genres/' + g : '/')
  102. }
  103. // mission 060 (tracker.worldapi.org#27): `/<shortId>` → 301 to the title's or person's page (lib/shortids.hl); upper case is
  104. // read as lower case; anything else is a 404
  105. shortIdRoute = (&route, &req) => {
  106. let sid = route.params != null ? route.params.sid : null
  107. let path = sid != null && hlTypeName(sid) == 'String' ? shortIdPath(sid.toLowerCase()) : null
  108. if (path == null) { return notFoundText('not found') }
  109. return movedTo(path)
  110. }
  111. // mission 062: a GUEST STAR's link (components/show.hl castRowsOf) — `/person/tmdb/<tmdbId>?show=<show id>` creates the person
  112. // (lib/people.hl guestPersonId) or finds the one we have, then 302 → `/person/<slug>`. A function route: the browser loads it
  113. // itself (hl:web's client router hands every non-component link to the browser)
  114. guestRoute = (&route, &req) => {
  115. let t = route.params != null ? route.params.tmdb : null
  116. let tmdbId = t != null && hlTypeName(t) == 'String' && t.length <= 10 ? toNumber(t) : null
  117. if (tmdbId == null || tmdbId < 1) { return notFoundText('not found') }
  118. let q = req.query != null ? req.query : {}
  119. let r = guestPersonId(tmdbId, q.show)
  120. let p = r.id != null ? personById(r.id) : null
  121. if (p == null || p.urlSegment == null) { return notFoundText('not found: ' + (r.error != null ? r.error : 'no such person')) }
  122. return new Response('see /person/' + p.urlSegment, { status = 302 headers = { 'Location' = '/person/' + p.urlSegment 'Cache-Control' = 'no-store' 'Content-Type' = 'text/plain; charset=utf-8' } })
  123. }
  124. // /shows/<slug> (tracker.worldapi.org#21, mission 068): a series or movie (or a merged duplicate's slug) answers 301 to its page
  125. // (lib/shows.hl showsMovedPath). hl:web has no way for a component route to answer a redirect, so this is a FUNCTION route, and
  126. // for a show (or an unknown slug: the page's own "Not found") it renders the title page the way hl:web renders a component
  127. // route (WebFramework.hl `on http.request`, the `component` branch): the Show component matched at /series/<slug> — same
  128. // component, same params — with the cookie's session, a new one (and its cookie) when the browser brought none. In the browser
  129. // a link to /shows/<slug> is then a full page load; every other title page stays a client-side navigation.
  130. showsRoute = (&route, &req) => {
  131. let slug = route.params != null ? route.params.slug : null
  132. let to = showsMovedPath(slug)
  133. if (to != null) { return movedTo(to) }
  134. let m = server.router.match('/series/' + slug)
  135. let s = req.session
  136. let fresh = s == null
  137. if (fresh) { s = server.sessions.mint() }
  138. let res = server.page(m, s, server.hostOf(req.headers['host']), server.requestHeaders(req.headers))
  139. if (fresh) { res.headers['Set-Cookie'] = server.sessions.cookieHeader(s.id) }
  140. return res
  141. }
  142. // tracker#31 (mission 026): the slug of a merged duplicate, or a keeper's former slug → 301 to the keeper's page (lib/shows.hl
  143. // movedSlugs, read at boot). A component route cannot redirect, so each such slug gets its own function route under /movies/ and
  144. // /series/ (/shows/ is showsRoute). A title merged while this process runs answers the keeper's page under its old slug (shows.hl
  145. // showBySlug) until the next start.
  146. slugMoved = (&route, &req) => {
  147. let to = movedPathOf(req.path)
  148. if (to == null) { return notFoundText('not found') }
  149. return movedTo(to)
  150. }
  151. routes = [
  152. { pattern = "/favicon.ico" file = "./icons/favicon.ico" headers = { 'Cache-Control' = 'no-cache' } }
  153. // the installable app (tracker.worldapi.org#10): the icons (manifest and service worker are hl:web's own, from appIcons / offline)
  154. { pattern = "/icons/icon-192.png" file = "./icons/icon-192.png" headers = { 'Cache-Control' = 'no-cache' } }
  155. { pattern = "/icons/icon-512.png" file = "./icons/icon-512.png" headers = { 'Cache-Control' = 'no-cache' } }
  156. { pattern = "/icons/apple-touch-icon.png" file = "./icons/apple-touch-icon.png" headers = { 'Cache-Control' = 'no-cache' } }
  157. { pattern = "/icons/favicon.svg" file = "./icons/favicon.svg" headers = { 'Cache-Control' = 'no-cache' } }
  158. { pattern = "/login/callback" function = loginCallback }
  159. { pattern = "/login/failed" component = LoginFailed }
  160. { pattern = "/login.js" file = "./login.js" headers = { 'Cache-Control' = 'no-cache' } }
  161. { pattern = "/posters/:name" function = posterRoute }
  162. // tracker.worldapi.org#13: every movie / every series, 24 per page — the page is a PATH segment (`/movies/page/2`), a
  163. // page component cannot read `?page=` (hybriel#11) — and the movies the user follows
  164. { pattern = "/movies" component = Movies }
  165. { pattern = "/movies/page/:page" component = Movies }
  166. // tracker.worldapi.org#21 (mission 068): series and shows split — /series lists the series, /shows the shows; a title's page
  167. // is /movies/<slug>, /series/<slug> or /shows/<slug> (one component; /shows/<slug> is showsRoute above)
  168. { pattern = "/movies/:slug" component = Show }
  169. { pattern = "/series" component = AllSeries }
  170. { pattern = "/series/page/:page" component = AllSeries }
  171. { pattern = "/series/:slug" component = Show }
  172. { pattern = "/shows" component = AllShows }
  173. { pattern = "/shows/page/:page" component = AllShows }
  174. { pattern = "/shows/:slug" function = showsRoute }
  175. { pattern = "/my/movies" component = MyMovies }
  176. { pattern = "/my/unwatched" component = Unwatched }
  177. { pattern = "/my/schedule" component = Schedule }
  178. // #21: /my/series and /my/shows (one component, components/myshows.hl; any other word there is its "Not found")
  179. { pattern = "/my/:tv" component = MyShows }
  180. { pattern = "/unwatched" function = unwatchedMoved }
  181. { pattern = "/schedule" function = scheduleMoved }
  182. // tracker.worldapi.org#14: the search — `/search/<text>` (hl:web gives a page no query string, so not `?q=`)
  183. { pattern = "/search/:q?" component = Search }
  184. // tracker.worldapi.org#16: a person's page (the show page's cast and the search link here) and their photo
  185. { pattern = "/person/tmdb/:tmdb" function = guestRoute }
  186. { pattern = "/person/:slug" component = Person }
  187. { pattern = "/profiles/:name" function = profileRoute }
  188. // mission 058 (tracker.worldapi.org#25): a genre's movies and series, like /movies (the page in the path)
  189. { pattern = "/genres/:genre" component = Genre }
  190. { pattern = "/genres/:genre/page/:page" component = Genre }
  191. { pattern = "/genre/:genre" function = genreMoved }
  192. // tracker.worldapi.org#19 (mission 066): franchises and timelines, the creator's editor (`/franchises/edit` before the slug)
  193. { pattern = "/franchises" component = Franchises }
  194. { pattern = "/franchises/edit" component = FranchiseEdit }
  195. { pattern = "/franchises/:slug" component = Franchise }
  196. { pattern = "/timelines/:tslug" component = Franchise }
  197. { pattern = "/timelines/:slug/edit" component = TimelineEdit }
  198. { pattern = "/" component = Home }
  199. // mission 060 (tracker.worldapi.org#27): a short id → its page (LAST: every named one-segment route above wins)
  200. { pattern = "/:sid" function = shortIdRoute }
  201. ]
  202. // WHO GETS THE PUSH: the login state reaches the tabs of one session (components/main.hl trackerSignedIn/Out).
  203. tagOf = (&session) => { return session != null && session.data != null ? session.data.tag : null }
  204. audience = {
  205. trackerSignedIn = (tag, &session) => { return tag != null && tagOf(session) == tag }
  206. trackerSignedOut = (tag, &session) => { return tag != null && tagOf(session) == tag }
  207. }
  208. // cookies are per host, not per port: an own name keeps this app's session apart from
  209. // ident's own (and from any other worldapi app sharing a dev host), see ident README "Design
  210. // tokens" / hybriel#10 hybriel#17.
  211. sessionCookie = 'trackersid'
  212. // tracker.worldapi.org#14: the search index (lib/search.hl) is built once here at boot (~0.6 s on the real data), not by the
  213. // first search
  214. searchIndexReady = ensureIndex()
  215. // mission 060: every short id in use (one map over shows AND persons) and the records still without one, before the first request
  216. shortIdsReady = ensureShortIds()
  217. // tracker#30 (mission 025): the slim list caches (lib/shows.hl cardOf / episodeRowsOf) of every followed title, before the first
  218. // /my/ load — not filled by that load
  219. titleCachesStart = now()
  220. titleCachesWarm = warmTitleCaches(allFollowedShowIds())
  221. episodeKeysWarm = warmEpisodeKeys(allWatchedEpisodeIds())
  222. console.log('list caches: ' + titleCachesWarm + ' followed titles, ' + episodeKeysWarm + ' watched episodes in ' + (now() - titleCachesStart) + ' ms')
  223. // tracker#18, ONCE (lib/dailysync.hl moveCopiedSummaries): a `summary` that is only the migrated copy of tmdbSummary is MOVED to
  224. // `migratedSummary` (mission 070: kept, not shown) — the current TMDB text shows; the creator's own texts stay
  225. summariesMoved = moveCopiedSummaries()
  226. if (summariesMoved.ran) { console.log('summaries: moved ' + summariesMoved.moved + ' copies of tmdbSummary to migratedSummary, kept ' + summariesMoved.kept + ' own texts, errors ' + summariesMoved.errors + ', ' + summariesMoved.ms + ' ms') }
  227. // mission 066: which timelines every title is in (one scan of the timelines), before the first show page
  228. franchisesReady = ensureFranchises()
  229. // tracker#31: the moved slugs' routes first, then `routes` as written (hl:web reads the written list for the pages it serves)
  230. movedSlugList = movedSlugs()
  231. withMovedSlugs = () => {
  232. let out = []
  233. for (m of movedSlugList) {
  234. out.push({ pattern = '/movies/' + m.slug function = slugMoved })
  235. out.push({ pattern = '/series/' + m.slug function = slugMoved })
  236. }
  237. for (r of routes) { out.push(r) }
  238. return out
  239. }
  240. allRoutes = withMovedSlugs()
  241. console.log('moved slugs: ' + movedSlugList.length + ' (301 to the keeper)')
  242. server = new WebFramework(routes = allRoutes, styles = styles, port = port, sessionCookie = sessionCookie, watchMode = watching)
  243. // ---- THE BACKGROUND JOBS (lib/jobs.hl): the daily TMDB sync, the backfills, the details repair, the credits job, the duplicate
  244. // merge, the short-id backfill, the collection seed — constructing it starts their clocks and logs which ones are off
  245. jobs = new Jobs()
  246. on Error(e) { console.log('error absorbed: ' + e.message) }

Branches

Latest commits

  • 06b078e3tracker mission 028 (code order) 3/5 project.hl is the map: config, routes, wiring and a feature → file index (914 → 258 lines); the background jobs (daily sync run, backfills, details repair, credits job, merge, short ids, collection seed) moved unchanged into lib/jobs.hl (a class: their state is reassigned every step, a static cannot be; one instance made after the server), the login callback into lib/users.hl, poster/photo serving into lib/images.hl, the /shows/<slug> rule into lib/shows.hl showsMovedPath; route handlers are thin wrappers; gates 342/0, 32/0, 52/0, real-copy pages identicalmre
  • 94716fd2tracker mission 028 (code order) 2/5 util + topics: lib/util.hl holds envOr, storageDir, postersDir, profilesDir, newId, hexDigits, todayStr, dateOr, textOr, hasId, listOr, firstOf, sortDesc once (were copied into up to 5 files); tmdbsync.hl split into tmdb.hl (TMDB/TVmaze requests), sync.hl (one title's sync), sync-helpers.hl, backfill.hl; details.hl split into details.hl, credits.hl, credits-helpers.hl (isIncomplete to shows.hl); search-helpers.hl (words, query, ranking, slugs); collections.hl (the TMDB collection seed, out of franchises.hl); deltasync.hl renamed dailysync.hl; no behaviour change: gates 342/0, 32/0, 52/0, real-copy pages identicalmre
  • 186079b0tracker mission 028 (code order) 1/5 move: every root .hl except project.hl into lib/ (styles.hl into components/), import paths only; gates 342/0, 32/0, 52/0; real-copy pages identicalmre
  • 4f47f181tracker: report 027mre
  • dc1d4be4tracker mission 027: Hybriel master 06617221 vendored (plugin allocator fixes 3a781359 + 413f60e4); real copy RSS through first-start jobs + 400 loads flat ~2.55 GB (190aa11d 2.3 -> 5.6 GB), page times <= 1.1x; gates 342/0, 32/0, 52/0mre
  • 84e1b3e1tracker: reports 025 + 026mre
  • dc40d859tracker#31 (mission 026): duplicate titles merged — the 68 type+tmdbId pairs held by 157 records were the old tracker's (all migrated); merge.hl repair job (own clock, before the TMDB jobs) keeps one keeper per title (follows/watches > old short id > oldest), moves follows, watches, seasons, cast, credits, timelines, tombstones the rest (mergedInto, never deleted), slugs + short ids 301 to the keeper; stray seasons merged into their listed twin (Reacher S3 watches) or linked when watched; search import re-checks before its put; deploy.sh waits up to 90 s for 200; real copy 68 -> 0 dup ids, az5b2 follows/watches equal; gates 342/0, 32/0, 52/0mre
  • 2667da05tracker#30 (mission 025): /my/ pages from slim cached title cards, episode rows and watch sets (after the jobs /my/series 1.8 s -> 0.06 s, /my/unwatched 4.1 -> 0.18 s); timeline page shows its name once; franchise widget under the poster/title; movies with TV leftovers (First Contact) go through the details repair; tools/count-tmdb-ids.hl; gates 327/0, 52/0, 32/0mre
  • 3909810dantcolony#40: mission references in README/STATUS/docs point to the moved missionsmre
  • e63b1d28antcolony#40: history (LOG.md), worker briefs (missions/) and reports moved here from antcolony, numbered per project; old numbers in antcolony docs/mission-map.mdmre
  • 1cda451dtracker: Hybriel master 190aa11d (#127 both shapes, GC correctness fc838894) — conductor adopts despite /my/series 2.4x after jobs (memory 8.0 → 1.7 GB boot); see reports/071mre
  • c1fa2f2etracker (mission 071): Hybriel master 190aa11d measured on the real copy vs the live binary 8590df63 — NOT adopted (after the first-start jobs /my/series 2.4x slower, /series 1.6x, RSS swings 7.4-12.2 GB; fresh it is flat at 1.7-2.2 GB and /my/unwatched faster), vendor stays 8efba065, candidate kept in .scratch/w071/vendor-190aa11d; tests/kinds.mjs: collection seed off (its TMDB request broke check 1 in 1 of 4 runs); tests/realdata-071.sh + realdata-071-bench.mjs + tools/realdata-071-table.py; README + STATUS (numbers, how to repeat); gates 325/0, 32/0, 50/0mre
  • 8081350atracker docs (mission 070): README (summary, Config HL_GC_BYTES — kept at Hybriel's default, the 256 MiB setting is taken out of docker-compose.yml again: the jobs grew to 12+ GB with it too, see STATUS), Test (three gates), Deploy (first start ~50 min: kinds then seed, restart once after collections done, memory numbers), Vendored Hybriel 8efba065 + #48 audit, Files; STATUS mission 070 entry (merges, migrated counts, lambda audit, gates, RSS old vs new, how to repeat, open points); docs/kinds.md + docs/franchises.md job order; tests/realdata-070-*.sh, tools/count-migrated.hl, tools/ref-params.py, tools/lambda-audit.pymre
  • 1ad19c8ctracker: re-vendor Hybriel master 8efba065 (#126 GC by bytes, #48 lambda parameters copy) (mission 070): bin/hybriel sha256 50361e95…, plugins core crypto data fetch fs http http1 mpackdb proc smtp time web; lambda audit: 13 lambdas change a passed record/list (11 through a local alias), no caller relies on it — unchanged; 319 read-only lambda parameters get & (no copy per call: /my/schedule 2.35 → 0.46 s, /my/unwatched 13.7 → 5.7 s on the real copy); /my/unwatched one merge sort instead of n² inserts; docker-compose HL_GC_BYTES=268435456; deploy.sh runs kinds.mjs + franchises.mjs too (default ports 8700–8710); tests/realdata-070.mjs; gates browser 325/0, kinds 32/0, franchises 50/0mre
  • 46b21389tracker (mission 070, conductor): the sync never destroys migrated data — the one-time summary step MOVES a copied summary to migratedSummary (marker summaries-moved.txt) instead of clearing it; a migrated record's first title/genres/homepage/tagline TMDB replaces → migratedTitle/migratedGenres/migratedHomepage/migratedTagline, a migrated season's/episode's title/summary → migratedTitle/migratedSummary (set once); tests/peek-shows.hl prints them; gate 325/0mre
  • 749019b0Merge t19 (tracker#19 franchises + timelines) into main (mission 070): conflicts README/STATUS/show.hl/project.hl/browser.mjs/faketmdb.mjs, both sides kept; franchise/timeline pages get #20's typed heading (Franchise | …, Timeline | …), their title links via titlePath (/movies|/series|/shows); the collection seed waits for repair, kinds and credits too; franchises.mjs URLs + 2 new checks; gates browser 323/0, kinds 32/0, franchises 50/0mre
  • daf49feaMerge t20 (tracker#20 typed headings + #21 series/shows split) into main (mission 070): conflicts README/STATUS/show.hl/project.hl/search.hl/components/search.hl/browser.mjs/faketmdb.mjs, both sides kept; clock order backfill → repair → kinds → credits; withDetailsFields stores tmdbType + kind; gates: browser.mjs URLs → /series|/movies, typed h1 selectors; kinds.mjs repair/credits off, fixture name = seed name; browser 323/0, kinds 32/0mre
  • 20e09d89Merge t18 (tracker#18 delta sync) into main (mission 070): conflicts README/STATUS/show.hl/project.hl/browser.mjs, both sides kept; pageShowOf summary = summaryOfmre
  • f83571c3tracker#18 (mission 067): daily sync by change lists — TMDB /tv|movie/changes (since the stored day, paged) + TVmaze /updates/shows → only our changed titles (followed: full step, unfollowed: light step — changed seasons, no TVmaze), full walk on first run / gap > 14 days / failed list; show record refreshed (title, tmdbSummary, tagline, status, genres …; renamed titles re-indexed); summary = the creator's own text (page: summary > tmdbSummary > tvmazeSummary), one-time clear of copied summaries (9,647 on the live copy); gate 261, tests/realdata-018*.mjs, README + STATUSmre
  • 1ed5457etracker#20 + #21 (mission 068): typed headings "<Type> | <name>" in type colours; TV titles split into Series (/series) and Shows (/shows) by TMDB type + Reality/Talk/News genres — kind stored by sync/import/adult backfill + new kind backfill (resumes), /movies/<slug>, /shows/<slug> of a series/movie → 301, /my/series + /my/shows, home 5 tiles + 3 rows, search/filmography labels; gates kinds 32 + browser 266, tests/realdata-068.mjs, tools/count-kinds.hl, docs/kinds.md, README + STATUSmre