Skip to content
Source
Sign inSign up
pingdotgg/t3code

fix(server): resolve Codex usage tiers from initial run history #21898

Mergedjuliusmarmingemerged 12 commits intomain fromrefs/pull/21898/headmerged by juliusmarminge View on GitHub

Showing 7 changed files with 90 additions and 2 deletions (loading 4).

x
0 of 7 viewed, 7 left
72 additions and 1 deletionapps/server/src/persistence/Migrations/055_OrchestrationV2.test.tsModified
View file
@@ -1,11 +1,13 @@
import { assert, it } from "@effect/vitest";
import * as Effect from "effect/Effect";
import * as Layer from "effect/Layer";
+import * as Schema from "effect/Schema";
import * as SqlClient from "effect/sql/SqlClient";
​
import { migrationEntries, runMigrations } from "../Migrations.ts";
import * as NodeSqliteClient from "@t3tools/shared/nodeSqliteClient";
​
+const encodeJson = Schema.encodeSync(Schema.fromJsonString(Schema.Unknown));
const layer = it.layer(Layer.mergeAll(NodeSqliteClient.layer({ filename: ":memory:" })));
​
layer("055_OrchestrationV2", (it) => {
@@ -13,7 +15,7 @@
Effect.sync(() => {
assert.deepStrictEqual(
migrationEntries.map(([id]) => id),
- Array.from({ length: 64 }, (_, index) => index + 1),
+ Array.from({ length: 65 }, (_, index) => index + 1),
);
}),
);
@@ -36,6 +38,7 @@
[62, "ThreadFailureLookupIndex"],
[63, "DropUnusedV1Projections"],
[64, "CanonicalizeThreadPullRequestLinks"],
+ [65, "CodexUsageNativeTurnIndex"],
]);