Skip to content

Commit 55db065

Browse files
committed
v2.22.2: Upgrade pg-id library version; fix BigIntArrayType and StringArrayType typings
1 parent 637e72c commit 55db065

File tree

8 files changed

+290
-308
lines changed

8 files changed

+290
-308
lines changed

docs/functions/BigIntArrayType.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88

99
> **BigIntArrayType**(): `object`
1010
11-
Defined in: [src/pg/types/BigIntArrayType.ts:17](https://github.com/clickup/ent-framework/blob/master/src/pg/types/BigIntArrayType.ts#L17)
11+
Defined in: [src/pg/types/BigIntArrayType.ts:18](https://github.com/clickup/ent-framework/blob/master/src/pg/types/BigIntArrayType.ts#L18)
1212

1313
An array of IDs. Notice that:
1414
1. Node-postgres natively supports this type on read path, but on write path,

docs/functions/StringArrayType.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88

99
> **StringArrayType**(): `object`
1010
11-
Defined in: [src/pg/types/StringArrayType.ts:13](https://github.com/clickup/ent-framework/blob/master/src/pg/types/StringArrayType.ts#L13)
11+
Defined in: [src/pg/types/StringArrayType.ts:14](https://github.com/clickup/ent-framework/blob/master/src/pg/types/StringArrayType.ts#L14)
1212

1313
An array of Strings. Note: node-postgres natively supports this type on read
1414
path, but on write path, we have to stringify by ourselves.

internal/init-db.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ rm -f $LOG
77
trap "rm -f $LOG" EXIT
88

99
for schema in sh000{0..4}; do
10-
DB_ID_ENV_NO=1 psql -v ON_ERROR_STOP=on \
10+
PG_ID_ENV_NO=1 psql -v ON_ERROR_STOP=on \
1111
-c "SET client_min_messages TO WARNING; CREATE SCHEMA IF NOT EXISTS $schema; SET search_path TO $schema" \
1212
-f "$(npm root)/@clickup/pg-id/pg-id-up.sql" >> $LOG 2>&1 \
1313
|| { cat $LOG; exit 1; }

package-lock.json

Lines changed: 277 additions & 294 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "@clickup/ent-framework",
33
"description": "A PostgreSQL graph-database-alike library with microsharding and row-level security",
4-
"version": "2.22.1",
4+
"version": "2.22.2",
55
"license": "MIT",
66
"keywords": [
77
"postgresql",
@@ -46,7 +46,7 @@
4646
"table": "^6.8.0"
4747
},
4848
"devDependencies": {
49-
"@clickup/pg-id": "2.12.2",
49+
"@clickup/pg-id": "^2.16.1",
5050
"@types/jest": "^29.5.5",
5151
"@types/lodash": "^4.14.175",
5252
"@types/node": "^20.4.1",

pg-id.config.sql

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,7 @@
11
-- Example constants to run Ent Framework unit tests.
22
\set CONST_ENV_MUL 10
33
\set CONST_SHARD_MUL 10000
4-
\set CONST_RND_MUL 100000000000000
5-
\set CONST_RND_BITS 46
6-
\set CONST_RND_TS_MUL 1000000000
7-
\set CONST_RND_TS_START 1262304000
8-
\set CONST_MUL 10000007141763
9-
\set CONST_SUM 10000003795571
10-
\set CONST_MOD 10000009458232
4+
\set CONST_RND_TS_START 1577836800
5+
\set CONST_MUL 17141763000000
6+
\set CONST_SUM 13795571000000
7+
\set CONST_MOD 19458232000000

src/pg/types/BigIntArrayType.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,11 @@
11
import { types } from "pg";
2+
import type { DesperateAny } from "../../internal/misc";
23

34
/**
45
* It is in pg-types/lib/textParsers.js (1016::regtype is "bigint[]"), just not
56
* exported to TS types.
67
*/
7-
const BIGINT_ARRAY_OID = 1016;
8+
const BIGINT_ARRAY_OID: DesperateAny = 1016;
89

910
/**
1011
* An array of IDs. Notice that:

src/pg/types/StringArrayType.ts

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,11 @@
11
import { types } from "pg";
2+
import type { DesperateAny } from "../../internal/misc";
23

34
/**
45
* It is in pg-types/lib/textParsers.js (1015::regtype is "character
56
* varying[]"), just not exported to TS types.
67
*/
7-
const VARCHAR_ARRAY_OID = 1015;
8+
const VARCHAR_ARRAY_OID: DesperateAny = 1015;
89

910
/**
1011
* An array of Strings. Note: node-postgres natively supports this type on read

0 commit comments

Comments
 (0)