Skip to content

Commit 35a1751

Browse files
refactor(server): keep manifest age parsing private
1 parent eced382 commit 35a1751

2 files changed

Lines changed: 1 addition & 3 deletions

File tree

‎apps/server/src/provider/ModelManifest.test.ts‎

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,6 @@ import {
1717
make,
1818
resolveProviderCatalog,
1919
type ModelManifestData,
20-
manifestUpdatedAtMs,
2120
encodeManifestCache,
2221
} from "./ModelManifest.ts";
2322

@@ -382,7 +381,6 @@ describe("ModelManifest service", () => {
382381
const fs = yield* FileSystem.FileSystem;
383382
const path = yield* Path.Path;
384383
const config = yield* ServerConfig.ServerConfig;
385-
assert.isAbove(manifestUpdatedAtMs(BUNDLED_MODEL_MANIFEST), 0);
386384
const cachePath = path.join(config.stateDir, "model-manifest.json");
387385
// A cache of the manifest as it was before the release edited it. The
388386
// fetch time is irrelevant: the remote may be unreachable now, so

‎apps/server/src/provider/ModelManifest.ts‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -138,7 +138,7 @@ export const BUNDLED_MODEL_MANIFEST: ModelManifestData =
138138
Schema.decodeUnknownSync(ModelManifestSchema)(bundledManifestJson);
139139

140140
/** Epoch millis of the manifest's `updatedAt`, or 0 when absent or unparsable. */
141-
export function manifestUpdatedAtMs(manifest: ModelManifestData): number {
141+
function manifestUpdatedAtMs(manifest: ModelManifestData): number {
142142
if (manifest.updatedAt === undefined) return 0;
143143
const parsed = Date.parse(manifest.updatedAt);
144144
return Number.isNaN(parsed) ? 0 : parsed;

0 commit comments

Comments
 (0)