Seeded defect in a throwaway copy of HEAD: record writes a watchdog without asking the gate for an end.
FAIL  with a running clock the tick names its end and the record keeps it (4078.619333ms)
FAIL  no clock and no night: prompt and record refuse, say why, and leave no record behind (5014.266041ms)
FAIL  a clock that has passed gives no end: a task made now would outlive the run (2706.002167ms)
FAIL  a clock file that cannot be read gives no end, and the message is the clock's own (3160.188083ms)
FAIL  a night that has not ended is an end too, and one that has ended is not (3227.827333ms)
FAIL  watchdog.mode off is the owner saying no, and prompt and record both refuse even with a clock (4658.5965ms)
ℹ tests 6
ℹ suites 0
ℹ pass 0
ℹ fail 6
ℹ cancelled 0
ℹ skipped 0
ℹ todo 0
ℹ duration_ms 24506.590709

FAIL  failing tests:

test at test/watchdog.test.mjs:86:1
FAIL  with a running clock the tick names its end and the record keeps it (4078.619333ms)
  AssertionError [ERR_ASSERTION]: The input did not match the regular expression /It ends at 2026-11-29T20:03:01\.377Z, set by the clock/. Input:
  
  'recorded task-1 in /private/var/folders/9c/r4br37hn6pqc6vl_bb88mnt00000gn/T/100x-test-Rh65F7/project/.100x/watchdog.json. It ends at 2026-11-30T17:03:03.037Z, set by nothing. Delete the scheduled task then, or at finish.\n'
  
      at TestContext.<anonymous> (file:///private/tmp/red/test/watchdog.test.mjs:95:10)
      at Test.runInAsyncScope (node:async_hooks:226:14)
      at Test.run (node:internal/test_runner/test:1402:25)
      at Test.start (node:internal/test_runner/test:1262:17)
      at startSubtestAfterBootstrap (node:internal/test_runner/harness:387:17) {
    generatedMessage: true,
    code: 'ERR_ASSERTION',
    actual: 'recorded task-1 in /private/var/folders/9c/r4br37hn6pqc6vl_bb88mnt00000gn/T/100x-test-Rh65F7/project/.100x/watchdog.json. It ends at 2026-11-30T17:03:03.037Z, set by nothing. Delete the scheduled task then, or at finish.\n',
    expected: /It ends at 2026-11-29T20:03:01\.377Z, set by the clock/,
    operator: 'match',
    diff: 'simple'
  }

test at test/watchdog.test.mjs:113:1
FAIL  no clock and no night: prompt and record refuse, say why, and leave no record behind (5014.266041ms)
  AssertionError [ERR_ASSERTION]: record task-1
  
  0 !== 1
  
      at TestContext.<anonymous> (file:///private/tmp/red/test/watchdog.test.mjs:117:12)
      at Test.runInAsyncScope (node:async_hooks:226:14)
      at Test.run (node:internal/test_runner/test:1402:25)
      at Test.processPendingSubtests (node:internal/test_runner/test:974:18)
      at Test.postRun (node:internal/test_runner/test:1542:19)
      at node:internal/test_runner/test:1305:31
      at node:internal/process/task_queues:158:7
      at AsyncResource.runInAsyncScope (node:async_hooks:226:14)
      at AsyncResource.runMicrotask (node:internal/process/task_queues:155:8) {
    generatedMessage: false,
    code: 'ERR_ASSERTION',
    actual: 0,
    expected: 1,
    operator: 'strictEqual',
    diff: 'simple'
  }

test at test/watchdog.test.mjs:126:1
FAIL  a clock that has passed gives no end: a task made now would outlive the run (2706.002167ms)
  AssertionError [ERR_ASSERTION]: Expected values to be strictly equal:
  
  0 !== 1
  
      at TestContext.<anonymous> (file:///private/tmp/red/test/watchdog.test.mjs:133:10)
      at Test.runInAsyncScope (node:async_hooks:226:14)
      at Test.run (node:internal/test_runner/test:1402:25)
      at Test.processPendingSubtests (node:internal/test_runner/test:974:18)
      at Test.postRun (node:internal/test_runner/test:1542:19)
      at Test.run (node:internal/test_runner/test:1467:12)
      at async Test.processPendingSubtests (node:internal/test_runner/test:974:7) {
    generatedMessage: true,
    code: 'ERR_ASSERTION',
    actual: 0,
    expected: 1,
    operator: 'strictEqual',
    diff: 'simple'
  }

test at test/watchdog.test.mjs:139:1
FAIL  a clock file that cannot be read gives no end, and the message is the clock's own (3160.188083ms)
  AssertionError [ERR_ASSERTION]: Expected values to be strictly equal:
  
  0 !== 1
  
      at TestContext.<anonymous> (file:///private/tmp/red/test/watchdog.test.mjs:143:10)
      at Test.runInAsyncScope (node:async_hooks:226:14)
      at Test.run (node:internal/test_runner/test:1402:25)
      at Test.processPendingSubtests (node:internal/test_runner/test:974:18)
      at Test.postRun (node:internal/test_runner/test:1542:19)
      at Test.run (node:internal/test_runner/test:1467:12)
      at async Test.processPendingSubtests (node:internal/test_runner/test:974:7) {
    generatedMessage: true,
    code: 'ERR_ASSERTION',
    actual: 0,
    expected: 1,
    operator: 'strictEqual',
    diff: 'simple'
  }

test at test/watchdog.test.mjs:149:1
FAIL  a night that has not ended is an end too, and one that has ended is not (3227.827333ms)
  AssertionError [ERR_ASSERTION]: The input did not match the regular expression /^the night night-\d{8}-\d{4}$/. Input:
  
  'nothing'
  
      at TestContext.<anonymous> (file:///private/tmp/red/test/watchdog.test.mjs:156:10)
      at Test.runInAsyncScope (node:async_hooks:226:14)
      at Test.run (node:internal/test_runner/test:1402:25)
      at Test.processPendingSubtests (node:internal/test_runner/test:974:18)
      at Test.postRun (node:internal/test_runner/test:1542:19)
      at Test.run (node:internal/test_runner/test:1467:12)
      at async Test.processPendingSubtests (node:internal/test_runner/test:974:7) {
    generatedMessage: true,
    code: 'ERR_ASSERTION',
    actual: 'nothing',
    expected: /^the night night-\d{8}-\d{4}$/,
    operator: 'match',
    diff: 'simple'
  }

test at test/watchdog.test.mjs:166:1
FAIL  watchdog.mode off is the owner saying no, and prompt and record both refuse even with a clock (4658.5965ms)
  AssertionError [ERR_ASSERTION]: record task-1
  
  0 !== 1
  
      at TestContext.<anonymous> (file:///private/tmp/red/test/watchdog.test.mjs:172:12)
      at Test.runInAsyncScope (node:async_hooks:226:14)
      at Test.run (node:internal/test_runner/test:1402:25)
      at Test.processPendingSubtests (node:internal/test_runner/test:974:18)
      at Test.postRun (node:internal/test_runner/test:1542:19)
      at Test.run (node:internal/test_runner/test:1467:12)
      at async Test.processPendingSubtests (node:internal/test_runner/test:974:7) {
    generatedMessage: false,
    code: 'ERR_ASSERTION',
    actual: 0,
    expected: 1,
    operator: 'strictEqual',
    diff: 'simple'
  }
