[constants] Refactor 1000 to MS_PER_SECOND

- Extracted MS_PER_SECOND to src/constants.mjs
- Replaced literal 1000 in src/relay-health.mjs, src/utils.mjs, src/lib.mjs, src/lock-ops.mjs
- Updated test/scheduler-lock-failure-schema.contract.test.mjs to copy constants.mjs
- Added task log and artifacts

Co-authored-by: PR0M3TH3AN <[email protected]>
This commit is contained in:
google-labs-jules[bot]andPR0M3TH3AN committed 2026-02-19 21:34:50 +00:00
1 parent 510e05ab54
commit 2174e8bc4d
11 files changed
+54 -9

No files matched your search

+2 -1
View File
@@ -1,11 +1,12 @@
import fs from 'node:fs';
import { MS_PER_SECOND } from './constants.mjs';
export function todayDateStr() {
return new Date().toISOString().slice(0, 10);
}
export function nowUnix() {
return Math.floor(Date.now() / 1000);
return Math.floor(Date.now() / MS_PER_SECOND);
}
export function getIsoWeekStr(dateInput) {