gitoria

tracker

All repositories: gitoria

ReadmeCodePull requestsReleasesTicketsSettings
Commit86fe543086fe5430log: HM62 startedmre86fe5430/tests/seed-reduced.hl

2.1 KB

  1. // tests/seed-reduced.hl — GATE FIXTURE for tracker#33 (mission 029): written by tests/browser.mjs into the gate's storage while the
  2. // app is STOPPED (one process per storage, hybriel#21). Two titles like the old tracker's MIGRATED rows that were never synced
  3. // (old `oldId`, no `tmdbSync`, no `detailsAt`, no `minimal`/`imported` — #26's test let them pass) and one complete title TMDB
  4. // has no poster for (like The Remaining):
  5. // Reduced Gate Series tv 1401: no seasons, no poster, no genres, no status → the details repair completes it
  6. // Reduced Gate Movie movie 1402: no poster, no genres, no IMDb id → completed when its page is opened
  7. // Posterless Gate Movie movie 1403, synced (`tmdbSync`), no poster on TMDB → complete: the placeholder, never asked
  8. import { MPackDB } from 'hl:mpackdb'
  9. import { env } from 'hl:proc'
  10. storageDir = env('TRACKER_STORAGE')
  11. if (storageDir == null || !storageDir.startsWith('/')) { hlError('set TRACKER_STORAGE, absolute') }
  12. showsTable = new MPackDB(file = storageDir + '/shows.db', primaryKey = '@id', indexes = ['!oldId'])
  13. title = (id, tmdbId, type, name, slug, release, synced) => {
  14. return { adult = false id = id title = name summary = null tmdbSummary = 'An old text of ' + name + '.' tmdbId = tmdbId
  15. language = 'en' type = type release = release year = toNumber(release.slice(0, 4)) image = null urlSegment = slug
  16. episodesCount = null homepage = null imdbId = null seasonsCount = null status = null tagline = null kind = type == 'movie' ? null : 'series'
  17. tvdbId = null tvmzId = null genres = [] cast = [] seasons = [] oldId = 'rd-' + tmdbId creditsAt = 1 tmdbSync = synced ? 1 : null }
  18. }
  19. showsTable.put(title('rd00000000000sr1', 1401, 'series', 'Reduced Gate Series', 'reduced-gate-series', '2010-04-01', false))
  20. showsTable.put(title('rd00000000000mv1', 1402, 'movie', 'Reduced Gate Movie', 'reduced-gate-movie', '1999-09-09', false))
  21. showsTable.put(title('rd00000000000mv2', 1403, 'movie', 'Posterless Gate Movie', 'posterless-gate-movie', '2026-09-17', true))
  22. showsTable.persist()
  23. console.log('seed reduced: 2 never-synced migrated titles (series 1401, movie 1402), 1 synced movie without a poster (1403)')

Branches

Latest commits

  • 86fe5430log: HM62 startedmre
  • 755307bbmission HM62mre
  • 4b2f2995HM61 report: tracker#61 packed people ordermre
  • 48faa84flog: #60 deploy startedmre
  • 90734c6cMerge branch 'hm60-shortids'mre
  • e0db0d1bHM60 report: tracker#60 packed short-ID ownersmre
  • 3c79b576Pack short-ID ownership into byte buffersmre
  • e822524bstatus wordingmre
  • 1c7f0480log: HM60/HM61 startedmre
  • 2841d215missions HM60 HM61mre
  • 289c6ce4HM1 report: heap object breakdownmre
  • 2e7d6257log: HM1 startedmre
  • 2f790465mission HM1: heap object breakdownmre
  • a18957falog: evening re-measure after CBmre
  • aac9a98dlog: evening re-measure startmre
  • 45163bd4log: person/tmdb error hypothesismre
  • cb38de2blog: swap 503 causemre
  • fd10c3d5log: CB livemre
  • 7557c025log: CB deploy try 2mre
  • 06a7534aMerge branch 'cb'mre