tracker
All repositories: gitoria
2.3 KB
// tests/seed-franchises.hl — GATE FIXTURE for tracker.worldapi.org#19 (mission 066, tests/franchises.mjs): movies with TMDB ids// for the collection seed, written into the gate's storage AFTER tests/seed-show.hl, before the server starts. What the fake TMDB// says about them (tests/franchises.mjs):// 9101 Gate Alien (1979), 9102 Gate Aliens (1986), 9103 Gate Alien 3 (1992) → collection 900 "Gate Alien Collection", whose// parts come OUT of release order, with a part we don't have (9999) and an ADULT one we have (9105, adult = true: never// asked, never in the timeline)// 9104 Gate Loner (2000) → collection 901, its only part we have → no timeline// 9106 Gate Standalone (2001) → no collection// 9107 Gate Missing (2002) → TMDB answers 404// Self-assigned ids, one put() each (never update(), see seed-show.hl).import { MPackDB } from 'hl:mpackdb'import { env } from 'hl:proc'storageDir = env('TRACKER_STORAGE')if (storageDir == null || !storageDir.startsWith('/')) { hlError('set TRACKER_STORAGE, absolute') }showsTable = new MPackDB(file = storageDir + '/shows.db', primaryKey = '@id', indexes = ['!oldId'])movie = (id, tmdbId, title, release, slug, adult) => {showsTable.put({adult = adult id = id title = title summary = null tmdbSummary = null tmdbId = tmdbIdlanguage = 'en' type = 'movie' release = release year = toNumber(release.slice(0, 4)) image = null urlSegment = slugepisodesCount = null homepage = null imdbId = null seasonsCount = null status = 'Released' tagline = nulltvdbId = null tvmzId = null genres = [] cast = [] seasons = [] oldId = 'fr-' + tmdbId})return true}movie('fr0000000000f101', 9101, 'Gate Alien', '1979-05-25', 'gate-alien', false)movie('fr0000000000f102', 9102, 'Gate Aliens', '1986-07-18', 'gate-aliens', false)movie('fr0000000000f103', 9103, 'Gate Alien 3', '1992-05-22', 'gate-alien-3', false)movie('fr0000000000f104', 9104, 'Gate Loner', '2000-01-01', 'gate-loner', false)movie('fr0000000000f105', 9105, 'Gate Adult Alien', '1990-01-01', 'gate-adult-alien', true)movie('fr0000000000f106', 9106, 'Gate Standalone', '2001-01-01', 'gate-standalone', false)movie('fr0000000000f107', 9107, 'Gate Missing', '2002-01-01', 'gate-missing', false)showsTable.persist()console.log('seed-franchises: 7 movies')
Branches
Latest commits
- 1f2df72amission RV39mre
- 6c1936f9log+status: GC planmre
- 2846a840log: m569 result, GC hypothesismre
- b24cd2d5log: Anton on hl:fetch, mission 569mre
- 7d42cac1log+status: SL1 measured, fetch stalls remainmre
- 8e5f2ceflog: SL1 deployedmre
- 29f34212log: SL1 deploy startedmre
- 529dd741Merge sl1-slices: slice details repair and person fill (SL1)mre
- 8a83316blog: SL1 result, session drain slowermre
- 35e93e8dSL1: slice the details repair and person fill: catalog lists changed in place, 40 ms fill steps, people created in steps, writes one table per tickmre
- 72c9119flog+status: SL1 startedmre
- d74620fcmission SL1: slice repair and person fillmre
- 5d542d73log+status: ST1 resultmre
- 3945eb81ST1: stall diagnosis reportmre
- 404733aclog: ST1 startedmre
- 3e3d5a55mission ST1: stall diagnosismre
- 9c3180eblog+status: RV28d measured after deploymre
- fdf10b1alog: RV28d deployed on day38bmre
- 320005e9log: RV28d merged, deploy runningmre
- a8fef27dRV28d: reportmre