gitoria

tracker

All repositories: gitoria

ReadmeCodePull requestsReleasesTicketsSettings
Commit8d3b0f208d3b0f20widget: the franchise link's 44 px tap area no longer overlaps the Prequel/Sequel rowmre8d3b0f20/tests/seed-adult.hl

4.0 KB

  1. // tests/seed-adult.hl — GATE FIXTURE for mission 054 (adult titles): written by tests/browser.mjs into the gate's storage
  2. // while the app is STOPPED (one process per storage, hybriel#21), late in the gate. Self-assigned ids, one put() each.
  3. //
  4. // Adult Gate Movie adult = true (known), followed by alice (TRACKER_SEED_USER) → only on her /my/movies + its page
  5. // Flagless Gate Movie adult unknown, TMDB (fake 1012) says not adult → listed once the backfill asked
  6. // Flagless Adult Movie adult unknown, TMDB (fake 1013) says adult → never listed
  7. // Flagless Gate Series adult unknown, TMDB (fake tv 1014) not adult → on /shows once asked (a released episode)
  8. // Backfill Movie 01…10 adult unknown, TMDB 1101…1110 not adult → the backfill's bulk (resume + latency checks)
  9. // Gone Gate Movie adult unknown, TMDB answers 404 (1120) → marked, stays hidden, never asked again
  10. // All carry `tmdbSync` (tracker#33): they stand for synced titles — the backfill's subject, not the details repair's.
  11. import { MPackDB } from 'hl:mpackdb'
  12. import { env } from 'hl:proc'
  13. import { now } from 'hl:time'
  14. storageDir = env('TRACKER_STORAGE')
  15. if (storageDir == null || !storageDir.startsWith('/')) { hlError('set TRACKER_STORAGE, absolute') }
  16. userId = env('TRACKER_SEED_USER')
  17. showsTable = new MPackDB(file = storageDir + '/shows.db', primaryKey = '@id', indexes = ['!oldId'])
  18. seasonsTable = new MPackDB(file = storageDir + '/seasons.db', primaryKey = '@id', indexes = ['!oldId'])
  19. episodesTable = new MPackDB(file = storageDir + '/episodes.db', primaryKey = '@id', indexes = ['!oldId'])
  20. followsTable = new MPackDB(file = storageDir + '/follows.db', primaryKey = '@id', indexes = ['!oldId'])
  21. movie = (key, title, tmdbId, release, adult, slug) => {
  22. return { id = 'ad0000000000' + key title = title summary = null tmdbSummary = null tmdbId = tmdbId
  23. language = 'en' type = 'movie' release = release year = toNumber(release.slice(0, 4)) image = null urlSegment = slug
  24. episodesCount = null homepage = null imdbId = null seasonsCount = null status = null tagline = null
  25. tvdbId = null tvmzId = null genres = [] cast = [] seasons = [] oldId = 'ad' + key adult = adult tmdbSync = 1 }
  26. }
  27. showsTable.put(movie('mvad', 'Adult Gate Movie', 1011, '2001-02-01', true, 'adult-gate-movie'))
  28. showsTable.put(movie('mvfl', 'Flagless Gate Movie', 1012, '2001-02-02', null, 'flagless-gate-movie'))
  29. showsTable.put(movie('mvfa', 'Flagless Adult Movie', 1013, '2001-02-03', null, 'flagless-adult-movie'))
  30. let i = 1
  31. while (i <= 10) {
  32. let nn = i < 10 ? '0' + i : '' + i
  33. showsTable.put(movie('bf' + nn, 'Backfill Movie ' + nn, 1100 + i, '1990-01-' + nn, null, 'backfill-movie-' + nn))
  34. i = i + 1
  35. }
  36. showsTable.put(movie('mvgo', 'Gone Gate Movie', 1120, '2001-02-04', null, 'gone-gate-movie'))
  37. seasonsTable.put({ id = 'ad00000000sefl' seasonNumber = 1 title = null release = null summary = null show = 'ad0000000000srfl' episodes = ['ad00000000epfl'] oldId = 'adsefl' })
  38. episodesTable.put({ id = 'ad00000000epfl' episodeNumber = 1 seasonNumber = 1 title = 'Flagless Pilot' summary = null release = '2001-03-03' show = 'ad0000000000srfl' season = 'ad00000000sefl' oldId = 'adepfl' })
  39. showsTable.put({ id = 'ad0000000000srfl' title = 'Flagless Gate Series' summary = null tmdbSummary = null tmdbId = 1014
  40. language = 'en' type = 'series' release = '2001-03-03' year = 2001 image = null urlSegment = 'flagless-gate-series'
  41. episodesCount = 1 homepage = null imdbId = null seasonsCount = 1 status = 'Ended' tagline = null
  42. tvdbId = null tvmzId = null genres = [] cast = [] seasons = ['ad00000000sefl'] oldId = 'adsrfl' adult = null tmdbSync = 1 })
  43. if (userId != null && userId != '') {
  44. followsTable.put({ id = 'adf00000000000f1' show = 'ad0000000000mvad' user = userId at = now() oldId = 'gate-follow-adult' })
  45. }
  46. showsTable.persist()
  47. seasonsTable.persist()
  48. episodesTable.persist()
  49. followsTable.persist()
  50. console.log('seed-adult: 15 titles (1 adult, 14 unknown)' + (userId != null && userId != '' ? ', ' + userId + ' follows Adult Gate Movie' : ''))

Branches

Latest commits

  • 8d3b0f20widget: the franchise link's 44 px tap area no longer overlaps the Prequel/Sequel rowmre
  • 1d98dcfdbrowser gate: the badges' size check reads the padding box (the 44 px tap area is transparent border)mre
  • 2f9e29ffreports/MK-mobile.md, deploy.sh GATES: tests/mobile.mjs, theme check markermre
  • 7cfc8ab5a season of more than 150 episodes starts closed on its title page; the phone gate checks itmre
  • 59095c59tests/mobile.mjs: the phone gate (390 px touch, tap targets, /franchises paging)mre
  • 105309detap targets: every row link, the TMDB/IMDb badges, the widget links, the franchise names and the login-failed link are 44 px high on a phonemre
  • f0b86c8efranchises: 40 loose timelines per page (/franchises/page/N) and a merge sort for the names (1,546 timelines: 20 s and 54,000 px before)mre
  • b9e841a7Merge branch 'sy-sync'mre
  • d1ae2701sync components.hybriel 4922f9c: modal and pagination 44 px targets (vendored copies, verbatim) (SY)mre
  • 043624b2theme: sync from layouts 4994037 (list rows stack, td word-keep, heading code, edited tap target)mre
  • 05d89fd0deploy: security gate (tests/security.mjs)mre
  • 2ae8a47bMerge branch 'sk-sec'mre
  • 8fee5d52sessions last 99 years (creator 2026-10-23: logins never expire; only sign out ends them)mre
  • 944ad51eSK: report reports/SK-sec.md, LOGsk
  • 415487c1SK: import budget per user + id type check, gate checkssk
  • 7b8a4f74security audit SK: nosniff + image sandbox headers, face id checks, adult follow, login budget + new session at login, guest-link budget, tests/security.mjssk
  • f0f26c5areports: T18 section (gates, boot-gate, 3x3 table, search + short-id compare)mre
  • 2a8682a1deploy.sh GATES: tests/warmstart.mjsmre
  • 3761338breports/T17-boot.md: handoff (phase table, fix, numbers so far, open proof)mre
  • 52e09eb2boot: sync window 1000 ms (the gates ask for a complete start), README boot-time sectionmre