@xata.io/drizzle 0.0.0-alpha.vf960929e852e3f3ca4565120bd57d2bd0b5684d5 → 0.0.0-alpha.vf987dba2f06d05234a7a3521610b53c0c3f84d72

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.
@@ -8,10 +8,10 @@
8
8
  https://rollupjs.org/troubleshooting/#warning-treating-module-as-external-dependency
9
9
  drizzle-orm (imported by "src/http/driver.ts", "src/http/session.ts" and "src/shared/utils.ts")
10
10
  drizzle-orm/pg-core (imported by "src/http/driver.ts" and "src/http/session.ts")
11
- created dist/index.cjs, dist/index.mjs in 347ms
11
+ created dist/index.cjs, dist/index.mjs in 475ms
12
12
  
13
13
  src/index.ts → dist/index.d.ts...
14
- created dist/index.d.ts in 7.2s
14
+ created dist/index.d.ts in 6.8s
15
15
  
16
16
  src/pg/index.ts → dist/pg.cjs, dist/pg.mjs...
17
17
  (!) Unresolved dependencies
@@ -19,7 +19,7 @@
19
19
  drizzle-orm (imported by "src/pg/driver.ts", "src/pg/session.ts" and "src/shared/utils.ts")
20
20
  drizzle-orm/pg-core (imported by "src/pg/driver.ts" and "src/pg/session.ts")
21
21
  pg (imported by "src/pg/session.ts")
22
- created dist/pg.cjs, dist/pg.mjs in 52ms
22
+ created dist/pg.cjs, dist/pg.mjs in 37ms
23
23
  
24
24
  src/pg/index.ts → dist/pg.d.ts...
25
- created dist/pg.d.ts in 1.6s
25
+ created dist/pg.d.ts in 1.5s
package/CHANGELOG.md CHANGED
@@ -1,13 +1,13 @@
1
1
  # @xata.io/drizzle
2
2
 
3
- ## 0.0.0-alpha.vf960929e852e3f3ca4565120bd57d2bd0b5684d5
3
+ ## 0.0.0-alpha.vf987dba2f06d05234a7a3521610b53c0c3f84d72
4
4
 
5
5
  ### Patch Changes
6
6
 
7
7
  - Force canary build
8
8
 
9
- - Updated dependencies []:
10
- - @xata.io/client@0.0.0-alpha.vf960929e852e3f3ca4565120bd57d2bd0b5684d5
9
+ - Updated dependencies [[`cc673c9`](https://github.com/xataio/client-ts/commit/cc673c9a7885351082020e360630eab5db78c652)]:
10
+ - @xata.io/client@0.0.0-alpha.vf987dba2f06d05234a7a3521610b53c0c3f84d72
11
11
 
12
12
  ## 0.0.22
13
13
 
package/dist/index.d.ts CHANGED
@@ -17,7 +17,7 @@ declare class XataHttpPreparedQuery<T extends PreparedQueryConfig> extends PgPre
17
17
  private _isResponseInArrayMode;
18
18
  private customResultMapper?;
19
19
  static readonly [entityKind]: string;
20
- constructor(client: XataHttpClient, query: Query, logger: Logger, fields: SelectedFieldsOrdered<PgColumn> | undefined, _isResponseInArrayMode: boolean, customResultMapper?: ((rows: unknown[][]) => T['execute']) | undefined);
20
+ constructor(client: XataHttpClient, query: Query, logger: Logger, fields: SelectedFieldsOrdered<PgColumn> | undefined, _isResponseInArrayMode: boolean, customResultMapper?: ((rows: unknown[][]) => T["execute"]) | undefined);
21
21
  execute(placeholderValues?: Record<string, unknown> | undefined): Promise<T['execute']>;
22
22
  all(placeholderValues?: Record<string, unknown> | undefined): Promise<T['all']>;
23
23
  values(placeholderValues?: Record<string, unknown> | undefined): Promise<T['values']>;
package/dist/pg.d.ts CHANGED
@@ -13,7 +13,7 @@ declare class XataPreparedQuery<T extends PreparedQueryConfig> extends PgPrepare
13
13
  static readonly [entityKind]: string;
14
14
  private rawQueryConfig;
15
15
  private queryConfig;
16
- constructor(client: XataClient, queryString: string, params: unknown[], logger: Logger, fields: SelectedFieldsOrdered<PgColumn> | undefined, name: string | undefined, _isResponseInArrayMode: boolean, customResultMapper?: ((rows: unknown[][]) => T['execute']) | undefined);
16
+ constructor(client: XataClient, queryString: string, params: unknown[], logger: Logger, fields: SelectedFieldsOrdered<PgColumn> | undefined, name: string | undefined, _isResponseInArrayMode: boolean, customResultMapper?: ((rows: unknown[][]) => T["execute"]) | undefined);
17
17
  execute(placeholderValues?: Record<string, unknown> | undefined): Promise<T['execute']>;
18
18
  all(placeholderValues?: Record<string, unknown> | undefined): Promise<T['all']>;
19
19
  values(placeholderValues?: Record<string, unknown> | undefined): Promise<T['values']>;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@xata.io/drizzle",
3
- "version": "0.0.0-alpha.vf960929e852e3f3ca4565120bd57d2bd0b5684d5",
3
+ "version": "0.0.0-alpha.vf987dba2f06d05234a7a3521610b53c0c3f84d72",
4
4
  "description": "",
5
5
  "main": "./dist/index.cjs",
6
6
  "module": "./dist/index.mjs",
@@ -23,7 +23,7 @@
23
23
  "url": "https://github.com/xataio/client-ts/issues"
24
24
  },
25
25
  "dependencies": {
26
- "@xata.io/client": "0.0.0-alpha.vf960929e852e3f3ca4565120bd57d2bd0b5684d5"
26
+ "@xata.io/client": "0.0.0-alpha.vf987dba2f06d05234a7a3521610b53c0c3f84d72"
27
27
  },
28
28
  "devDependencies": {
29
29
  "@types/pg": "^8.11.6",
@@ -78,10 +78,9 @@ function getDrizzleClient(type: string, branch: string) {
78
78
 
79
79
  describe.concurrent.each([{ type: 'pg' }, { type: 'http' }])('Drizzle $type', ({ type }) => {
80
80
  beforeAll(async () => {
81
- await api.database.createDatabase({
82
- workspace,
83
- database,
84
- data: { region, branchName: 'main' },
81
+ await api.databases.createDatabase({
82
+ pathParams: { workspaceId: workspace, dbName: database },
83
+ body: { region, branchName: 'main' },
85
84
  headers: { 'X-Features': 'feat-pgroll-migrations=1' }
86
85
  });
87
86
 
@@ -155,12 +154,15 @@ describe.concurrent.each([{ type: 'pg' }, { type: 'http' }])('Drizzle $type', ({
155
154
  });
156
155
 
157
156
  afterAll(async () => {
158
- await api.database.deleteDatabase({ workspace, database });
157
+ await api.databases.deleteDatabase({ pathParams: { workspaceId: workspace, dbName: database } });
159
158
  });
160
159
 
161
160
  beforeEach(async (ctx) => {
162
161
  ctx.branch = `test-${Math.random().toString(36).substring(7)}`;
163
- await api.branches.createBranch({ workspace, database, region, branch: ctx.branch, from: 'main' });
162
+ await api.branch.createBranch({
163
+ pathParams: { workspace, region, dbBranchName: `${database}:${ctx.branch}` },
164
+ body: { from: 'main' }
165
+ });
164
166
 
165
167
  const { db, client } = getDrizzleClient(type, ctx.branch);
166
168
  await client?.connect();
@@ -171,7 +173,7 @@ describe.concurrent.each([{ type: 'pg' }, { type: 'http' }])('Drizzle $type', ({
171
173
 
172
174
  afterEach(async (ctx) => {
173
175
  await ctx.client?.end();
174
- await api.branches.deleteBranch({ workspace, database, region, branch: ctx.branch });
176
+ await api.branch.deleteBranch({ pathParams: { workspace, region, dbBranchName: `${database}:${ctx.branch}` } });
175
177
  });
176
178
 
177
179
  /*
@@ -6285,7 +6287,7 @@ describe.concurrent.each([{ type: 'pg' }, { type: 'http' }])('Drizzle $type', ({
6285
6287
  async function waitForReplication(): Promise<void> {
6286
6288
  try {
6287
6289
  await new Promise((resolve) => setTimeout(resolve, 2000));
6288
- await api.branches.getBranchList({ workspace, database, region });
6290
+ await api.branch.getBranchList({ pathParams: { workspace, dbName: database, region } });
6289
6291
  } catch (error) {
6290
6292
  console.log(`Replication not ready yet, retrying...`);
6291
6293
  return await waitForReplication();