@axiom-lattice/pg-stores 1.0.64 → 1.0.66

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,5 +1,5 @@
1
1
 
2
- > @axiom-lattice/pg-stores@1.0.64 build /home/runner/work/agentic/agentic/packages/pg-stores
2
+ > @axiom-lattice/pg-stores@1.0.66 build /home/runner/work/agentic/agentic/packages/pg-stores
3
3
  > tsup src/index.ts --format cjs,esm --dts --sourcemap
4
4
 
5
5
  CLI Building entry: src/index.ts
@@ -8,13 +8,13 @@
8
8
  CLI Target: es2020
9
9
  CJS Build start
10
10
  ESM Build start
11
- CJS dist/index.js 203.81 KB
12
- CJS dist/index.js.map 375.16 KB
13
- CJS ⚡️ Build success in 606ms
14
- ESM dist/index.mjs 198.79 KB
15
- ESM dist/index.mjs.map 375.00 KB
16
- ESM ⚡️ Build success in 613ms
11
+ CJS dist/index.js 203.86 KB
12
+ CJS dist/index.js.map 375.22 KB
13
+ CJS ⚡️ Build success in 411ms
14
+ ESM dist/index.mjs 198.84 KB
15
+ ESM dist/index.mjs.map 375.06 KB
16
+ ESM ⚡️ Build success in 434ms
17
17
  DTS Build start
18
- DTS ⚡️ Build success in 14047ms
18
+ DTS ⚡️ Build success in 12103ms
19
19
  DTS dist/index.d.ts 47.54 KB
20
20
  DTS dist/index.d.mts 47.54 KB
package/CHANGELOG.md CHANGED
@@ -1,5 +1,18 @@
1
1
  # @axiom-lattice/pg-stores
2
2
 
3
+ ## 1.0.66
4
+
5
+ ### Patch Changes
6
+
7
+ - 1314313: fix table migration
8
+
9
+ ## 1.0.65
10
+
11
+ ### Patch Changes
12
+
13
+ - Updated dependencies [55bc767]
14
+ - @axiom-lattice/core@2.1.75
15
+
3
16
  ## 1.0.64
4
17
 
5
18
  ### Patch Changes
package/dist/index.js CHANGED
@@ -264,7 +264,7 @@ var createThreadsTable = {
264
264
 
265
265
  // src/migrations/thread_tenant_migration.ts
266
266
  var addThreadTenantId = {
267
- version: 15,
267
+ version: 23,
268
268
  name: "add_thread_tenant_id",
269
269
  up: async (client) => {
270
270
  await client.query(`
@@ -623,7 +623,7 @@ var addAssistantTenantId = {
623
623
 
624
624
  // src/migrations/assistant_pk_migration.ts
625
625
  var changeAssistantPrimaryKey = {
626
- version: 15,
626
+ version: 112,
627
627
  name: "change_assistant_primary_key",
628
628
  up: async (client) => {
629
629
  const tableExists = await client.query(`
@@ -1780,7 +1780,7 @@ var PostgreSQLSkillStore = class {
1780
1780
  `
1781
1781
  INSERT INTO lattice_skills (id, tenant_id, name, description, license, compatibility, metadata, content, sub_skills, created_at, updated_at)
1782
1782
  VALUES ($1, $2, $3, $4, $5, $6, $7, $8, $9, $10, $11)
1783
- ON CONFLICT (id) DO UPDATE SET
1783
+ ON CONFLICT (tenant_id, id) DO UPDATE SET
1784
1784
  tenant_id = EXCLUDED.tenant_id,
1785
1785
  name = EXCLUDED.name,
1786
1786
  description = EXCLUDED.description,
@@ -1977,7 +1977,7 @@ var import_pg5 = require("pg");
1977
1977
 
1978
1978
  // src/migrations/database_config_migrations.ts
1979
1979
  var createDatabaseConfigsTable = {
1980
- version: 4,
1980
+ version: 111,
1981
1981
  name: "create_database_configs_table",
1982
1982
  up: async (client) => {
1983
1983
  await client.query(`
@@ -3438,7 +3438,7 @@ var addUserStatusColumn = {
3438
3438
  `);
3439
3439
  await client.query(`
3440
3440
  CREATE INDEX IF NOT EXISTS idx_lattice_users_status
3441
- ON lattice_users(tenant_id, status)
3441
+ ON lattice_users(status)
3442
3442
  `);
3443
3443
  await client.query(`
3444
3444
  UPDATE lattice_users
@@ -4543,7 +4543,7 @@ var addPriorityAndCommandColumns = {
4543
4543
 
4544
4544
  // src/migrations/add_custom_run_config_column.ts
4545
4545
  var addCustomRunConfigColumn = {
4546
- version: 102,
4546
+ version: 114,
4547
4547
  name: "add_custom_run_config_column",
4548
4548
  up: async (client) => {
4549
4549
  await client.query(`
@@ -6265,7 +6265,7 @@ var PostgreSQLEvalStore = class {
6265
6265
  /** Delete a run and its results */
6266
6266
  async deleteRun(tenantId, id) {
6267
6267
  await this.ensureInitialized();
6268
- await this.pool.query(`DELETE FROM lattice_eval_run_results WHERE run_id = $1 AND tenant_id = $2`, [id, tenantId]);
6268
+ await this.pool.query(`DELETE FROM lattice_eval_run_results WHERE run_id = $1 AND run_id IN (SELECT id FROM lattice_eval_runs WHERE tenant_id = $2)`, [id, tenantId]);
6269
6269
  const { rowCount } = await this.pool.query(
6270
6270
  `DELETE FROM lattice_eval_runs WHERE id = $1 AND tenant_id = $2`,
6271
6271
  [id, tenantId]