gitoria

tracker

All repositories: gitoria

ReadmeCodePull requestsReleasesTicketsSettings
Commit78ee6b5678ee6b56Move remaining component styles into Style blocksmre78ee6b56/tests/seed-shortids.hl

1.4 KB

  1. // tests/seed-shortids.hl — GATE FIXTURE for mission 060 (tracker.worldapi.org#27, short ids): written by tests/browser.mjs into
  2. // the gate's storage while the app is STOPPED (one process per storage, hybriel#21), after every record already has its short
  3. // id. Self-assigned ids, one put() each.
  4. //
  5. // Short Person 01…60 no short id → the next start's backfill gives them one (the resume check stops it part way)
  6. // Dupe Person A, B BOTH carry 'aaaa1' → the next start keeps it for A (scanned first) and gives B a new one
  7. import { MPackDB } from 'hl:mpackdb'
  8. import { env } from 'hl:proc'
  9. storageDir = env('TRACKER_STORAGE')
  10. if (storageDir == null || !storageDir.startsWith('/')) { hlError('set TRACKER_STORAGE, absolute') }
  11. personsTable = new MPackDB(file = storageDir + '/persons.db', primaryKey = '@id', indexes = ['!oldId'])
  12. let i = 1
  13. while (i <= 60) {
  14. let nn = i < 10 ? '0' + i : '' + i
  15. personsTable.put({ id = 'sp00000000000p' + nn name = 'Short Person ' + nn urlSegment = 'Short-Person-' + nn tmdbId = null shows = [] oldId = 'sp' + nn })
  16. i = i + 1
  17. }
  18. personsTable.put({ id = 'sp0000000000dupa' name = 'Dupe Person A' urlSegment = 'Dupe-Person-A' tmdbId = null shows = [] oldId = 'spdupa' shortId = 'aaaa1' })
  19. personsTable.put({ id = 'sp0000000000dupb' name = 'Dupe Person B' urlSegment = 'Dupe-Person-B' tmdbId = null shows = [] oldId = 'spdupb' shortId = 'aaaa1' })
  20. personsTable.persist()
  21. console.log('seed short ids: 62 persons (60 without a short id, 2 sharing aaaa1)')

Branches

Latest commits

  • 78ee6b56Move remaining component styles into Style blocksmre
  • 7f04de33log: HM49Bmre
  • 00616cf3log: #49 batch merged, DP67 startedmre
  • d7232e86Merge hm49-styles: tracker#49 first batch of component stylesmre
  • 079f376dMove seven components' styles into Style blocksmre
  • 17d66feelog: #58 mergedmre
  • 69a6640bMerge hm58-map: tracker#58 project.hl only the mapmre
  • a85f7900Move route logic out of the project mapmre
  • 13dea5belog: #56 live, HM49 and HM58 startedmre
  • a31c8f2fdocs: tracker#36 remaining listmre
  • 975d06d1log: #36 live, DP66 startedmre
  • d6d03fa3mission: T36Bmre
  • e7512d00status: #36 rolled back, retry askedmre
  • c98e2043log: T36A rollbackmre
  • ae905f15Merge t36a: tracker#36 apply rechecks, reportmre
  • 796bfaceT36A: report validated fixes, failed live SSH check and verified rollbackmre
  • 55257852log: #53 live, #56 mergedmre
  • 78b39f1bMerge hm56-rows: tracker#56 list builders insert oncemre
  • 7aea52batmdb fix: protect owners without slugs and record passing gatesmre
  • 9b3c2559tmdb fix: revalidate planned identities and reserve target idsmre