tempest.games 0.1.19 → 0.1.20

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.
@@ -5,7 +5,7 @@
5
5
  import * as os2 from "os";
6
6
  import { resolve } from "path";
7
7
 
8
- // /home/runner/work/wayforge/wayforge/apps/tempest.games/node_modules/postgres/src/index.js
8
+ // ../../node_modules/.pnpm/postgres@3.4.5/node_modules/postgres/src/index.js
9
9
  import os from "os";
10
10
  import fs from "fs";
11
11
 
@@ -368,7 +368,7 @@ var inferType = function inferType2(x) {
368
368
  var escapeBackslash = /\\/g;
369
369
  var escapeQuote = /"/g;
370
370
  function arrayEscape(x) {
371
- return x.replace(escapeBackslash, "\\\\").replace(escapeQuote, '\\"');
371
+ return x.replace(escapeBackslash, "\\\\").replace(escapeQuote, "\\\"");
372
372
  }
373
373
  var arraySerializer = function arraySerializer2(xs, serializer, options, typarray) {
374
374
  if (Array.isArray(xs) === false)
@@ -855,7 +855,8 @@ function Connection(options, queues = {}, { onopen = noop, onend = noop, onclose
855
855
  }
856
856
  function queryError(query2, err) {
857
857
  "query" in err || "parameters" in err || Object.defineProperties(err, {
858
- stack: { value: err.stack + query2.origin.replace(/.*\n/, "\n"), enumerable: options.debug },
858
+ stack: { value: err.stack + query2.origin.replace(/.*\n/, `
859
+ `), enumerable: options.debug },
859
860
  query: { value: query2.string, enumerable: options.debug },
860
861
  parameters: { value: query2.parameters, enumerable: options.debug },
861
862
  args: { value: query2.args, enumerable: options.debug },
@@ -1388,7 +1389,7 @@ function Subscribe(postgres2, options) {
1388
1389
  }
1389
1390
  function pong() {
1390
1391
  const x2 = Buffer.alloc(34);
1391
- x2[0] = "r".charCodeAt(0);
1392
+ x2[0] = 114;
1392
1393
  x2.fill(state2.lsn, 1);
1393
1394
  x2.writeBigInt64BE(BigInt(Date.now() - Date.UTC(2000, 0, 1)) * BigInt(1000), 25);
1394
1395
  stream2.write(x2);
@@ -1560,7 +1561,7 @@ function largeObject(sql, oid, mode = 131072 | 262144) {
1560
1561
  });
1561
1562
  }
1562
1563
 
1563
- // /home/runner/work/wayforge/wayforge/apps/tempest.games/node_modules/postgres/src/index.js
1564
+ // ../../node_modules/.pnpm/postgres@3.4.5/node_modules/postgres/src/index.js
1564
1565
  Object.assign(Postgres, {
1565
1566
  PostgresError,
1566
1567
  toPascal,
@@ -1954,7 +1955,7 @@ function osUsername() {
1954
1955
  }
1955
1956
  }
1956
1957
 
1957
- // ../../node_modules/.pnpm/drizzle-orm@0.36.1_@libsql+client-wasm@0.14.0_@types+react@18.3.12_bun-types@1.1.34_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/entity.js
1958
+ // ../../node_modules/.pnpm/drizzle-orm@0.36.3_@types+react@18.3.12_bun-types@1.1.35_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/entity.js
1958
1959
  var entityKind = Symbol.for("drizzle:entityKind");
1959
1960
  var hasOwnEntityKind = Symbol.for("drizzle:hasOwnEntityKind");
1960
1961
  function is(value, type) {
@@ -1979,7 +1980,7 @@ function is(value, type) {
1979
1980
  return false;
1980
1981
  }
1981
1982
 
1982
- // ../../node_modules/.pnpm/drizzle-orm@0.36.1_@libsql+client-wasm@0.14.0_@types+react@18.3.12_bun-types@1.1.34_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/logger.js
1983
+ // ../../node_modules/.pnpm/drizzle-orm@0.36.3_@types+react@18.3.12_bun-types@1.1.35_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/logger.js
1983
1984
  class ConsoleLogWriter {
1984
1985
  static [entityKind] = "ConsoleLogWriter";
1985
1986
  write(message) {
@@ -2012,7 +2013,7 @@ class NoopLogger {
2012
2013
  }
2013
2014
  }
2014
2015
 
2015
- // ../../node_modules/.pnpm/drizzle-orm@0.36.1_@libsql+client-wasm@0.14.0_@types+react@18.3.12_bun-types@1.1.34_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/query-promise.js
2016
+ // ../../node_modules/.pnpm/drizzle-orm@0.36.3_@types+react@18.3.12_bun-types@1.1.35_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/query-promise.js
2016
2017
  class QueryPromise {
2017
2018
  static [entityKind] = "QueryPromise";
2018
2019
  [Symbol.toStringTag] = "QueryPromise";
@@ -2033,10 +2034,10 @@ class QueryPromise {
2033
2034
  }
2034
2035
  }
2035
2036
 
2036
- // ../../node_modules/.pnpm/drizzle-orm@0.36.1_@libsql+client-wasm@0.14.0_@types+react@18.3.12_bun-types@1.1.34_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/table.utils.js
2037
+ // ../../node_modules/.pnpm/drizzle-orm@0.36.3_@types+react@18.3.12_bun-types@1.1.35_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/table.utils.js
2037
2038
  var TableName = Symbol.for("drizzle:Name");
2038
2039
 
2039
- // ../../node_modules/.pnpm/drizzle-orm@0.36.1_@libsql+client-wasm@0.14.0_@types+react@18.3.12_bun-types@1.1.34_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/table.js
2040
+ // ../../node_modules/.pnpm/drizzle-orm@0.36.3_@types+react@18.3.12_bun-types@1.1.35_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/table.js
2040
2041
  var Schema = Symbol.for("drizzle:Schema");
2041
2042
  var Columns = Symbol.for("drizzle:Columns");
2042
2043
  var ExtraConfigColumns = Symbol.for("drizzle:ExtraConfigColumns");
@@ -2080,15 +2081,15 @@ function getTableUniqueName(table) {
2080
2081
  return `${table[Schema] ?? "public"}.${table[TableName]}`;
2081
2082
  }
2082
2083
 
2083
- // ../../node_modules/.pnpm/drizzle-orm@0.36.1_@libsql+client-wasm@0.14.0_@types+react@18.3.12_bun-types@1.1.34_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/tracing-utils.js
2084
+ // ../../node_modules/.pnpm/drizzle-orm@0.36.3_@types+react@18.3.12_bun-types@1.1.35_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/tracing-utils.js
2084
2085
  function iife(fn, ...args) {
2085
2086
  return fn(...args);
2086
2087
  }
2087
2088
 
2088
- // ../../node_modules/.pnpm/drizzle-orm@0.36.1_@libsql+client-wasm@0.14.0_@types+react@18.3.12_bun-types@1.1.34_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/version.js
2089
- var version = "0.36.1";
2089
+ // ../../node_modules/.pnpm/drizzle-orm@0.36.3_@types+react@18.3.12_bun-types@1.1.35_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/version.js
2090
+ var version = "0.36.3";
2090
2091
 
2091
- // ../../node_modules/.pnpm/drizzle-orm@0.36.1_@libsql+client-wasm@0.14.0_@types+react@18.3.12_bun-types@1.1.34_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/tracing.js
2092
+ // ../../node_modules/.pnpm/drizzle-orm@0.36.3_@types+react@18.3.12_bun-types@1.1.35_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/tracing.js
2092
2093
  var otel;
2093
2094
  var rawTracer;
2094
2095
  var tracer = {
@@ -2115,7 +2116,7 @@ var tracer = {
2115
2116
  }
2116
2117
  };
2117
2118
 
2118
- // ../../node_modules/.pnpm/drizzle-orm@0.36.1_@libsql+client-wasm@0.14.0_@types+react@18.3.12_bun-types@1.1.34_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/column.js
2119
+ // ../../node_modules/.pnpm/drizzle-orm@0.36.3_@types+react@18.3.12_bun-types@1.1.35_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/column.js
2119
2120
  class Column {
2120
2121
  constructor(table, config) {
2121
2122
  this.table = table;
@@ -2165,12 +2166,12 @@ class Column {
2165
2166
  }
2166
2167
  }
2167
2168
 
2168
- // ../../node_modules/.pnpm/drizzle-orm@0.36.1_@libsql+client-wasm@0.14.0_@types+react@18.3.12_bun-types@1.1.34_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/pg-core/unique-constraint.js
2169
+ // ../../node_modules/.pnpm/drizzle-orm@0.36.3_@types+react@18.3.12_bun-types@1.1.35_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/pg-core/unique-constraint.js
2169
2170
  function uniqueKeyName(table, columns) {
2170
2171
  return `${table[TableName]}_${columns.join("_")}_unique`;
2171
2172
  }
2172
2173
 
2173
- // ../../node_modules/.pnpm/drizzle-orm@0.36.1_@libsql+client-wasm@0.14.0_@types+react@18.3.12_bun-types@1.1.34_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/pg-core/columns/common.js
2174
+ // ../../node_modules/.pnpm/drizzle-orm@0.36.3_@types+react@18.3.12_bun-types@1.1.35_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/pg-core/columns/common.js
2174
2175
  class PgColumn extends Column {
2175
2176
  constructor(table, config) {
2176
2177
  if (!config.uniqueName) {
@@ -2219,7 +2220,7 @@ class ExtraConfigColumn extends PgColumn {
2219
2220
  }
2220
2221
  }
2221
2222
 
2222
- // ../../node_modules/.pnpm/drizzle-orm@0.36.1_@libsql+client-wasm@0.14.0_@types+react@18.3.12_bun-types@1.1.34_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/pg-core/columns/enum.js
2223
+ // ../../node_modules/.pnpm/drizzle-orm@0.36.3_@types+react@18.3.12_bun-types@1.1.35_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/pg-core/columns/enum.js
2223
2224
  var isPgEnumSym = Symbol.for("drizzle:isPgEnum");
2224
2225
  function isPgEnum(obj) {
2225
2226
  return !!obj && typeof obj === "function" && isPgEnumSym in obj && obj[isPgEnumSym] === true;
@@ -2237,7 +2238,7 @@ class PgEnumColumn extends PgColumn {
2237
2238
  }
2238
2239
  }
2239
2240
 
2240
- // ../../node_modules/.pnpm/drizzle-orm@0.36.1_@libsql+client-wasm@0.14.0_@types+react@18.3.12_bun-types@1.1.34_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/subquery.js
2241
+ // ../../node_modules/.pnpm/drizzle-orm@0.36.3_@types+react@18.3.12_bun-types@1.1.35_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/subquery.js
2241
2242
  class Subquery {
2242
2243
  static [entityKind] = "Subquery";
2243
2244
  constructor(sql, selection, alias, isWith = false) {
@@ -2255,10 +2256,10 @@ class WithSubquery extends Subquery {
2255
2256
  static [entityKind] = "WithSubquery";
2256
2257
  }
2257
2258
 
2258
- // ../../node_modules/.pnpm/drizzle-orm@0.36.1_@libsql+client-wasm@0.14.0_@types+react@18.3.12_bun-types@1.1.34_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/view-common.js
2259
+ // ../../node_modules/.pnpm/drizzle-orm@0.36.3_@types+react@18.3.12_bun-types@1.1.35_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/view-common.js
2259
2260
  var ViewBaseConfig = Symbol.for("drizzle:ViewBaseConfig");
2260
2261
 
2261
- // ../../node_modules/.pnpm/drizzle-orm@0.36.1_@libsql+client-wasm@0.14.0_@types+react@18.3.12_bun-types@1.1.34_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/sql/sql.js
2262
+ // ../../node_modules/.pnpm/drizzle-orm@0.36.3_@types+react@18.3.12_bun-types@1.1.35_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/sql/sql.js
2262
2263
  function isSQLWrapper(value) {
2263
2264
  return value !== null && value !== undefined && typeof value.getSQL === "function";
2264
2265
  }
@@ -2362,7 +2363,11 @@ class SQL {
2362
2363
  if (_config.invokeSource === "indexes") {
2363
2364
  return { sql: escapeName(columnName), params: [] };
2364
2365
  }
2365
- return { sql: escapeName(chunk.table[Table.Symbol.Name]) + "." + escapeName(columnName), params: [] };
2366
+ const schemaName = chunk.table[Table.Symbol.Schema];
2367
+ return {
2368
+ sql: chunk.table[IsAlias] || schemaName === undefined ? escapeName(chunk.table[Table.Symbol.Name]) + "." + escapeName(columnName) : escapeName(schemaName) + "." + escapeName(chunk.table[Table.Symbol.Name]) + "." + escapeName(columnName),
2369
+ params: []
2370
+ };
2366
2371
  }
2367
2372
  if (is(chunk, View)) {
2368
2373
  const schemaName = chunk[ViewBaseConfig].schema;
@@ -2625,7 +2630,7 @@ Subquery.prototype.getSQL = function() {
2625
2630
  return new SQL([this]);
2626
2631
  };
2627
2632
 
2628
- // ../../node_modules/.pnpm/drizzle-orm@0.36.1_@libsql+client-wasm@0.14.0_@types+react@18.3.12_bun-types@1.1.34_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/utils.js
2633
+ // ../../node_modules/.pnpm/drizzle-orm@0.36.3_@types+react@18.3.12_bun-types@1.1.35_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/utils.js
2629
2634
  function mapResultRow(columns, row, joinsNotNullableMap) {
2630
2635
  const nullifyMap = {};
2631
2636
  const result = columns.reduce((result2, { path, field }, columnIndex) => {
@@ -2699,7 +2704,7 @@ function haveSameKeys(left, right) {
2699
2704
  }
2700
2705
  function mapUpdateSet(table, values2) {
2701
2706
  const entries = Object.entries(values2).filter(([, value]) => value !== undefined).map(([key, value]) => {
2702
- if (is(value, SQL)) {
2707
+ if (is(value, SQL) || is(value, Column)) {
2703
2708
  return [key, value];
2704
2709
  } else {
2705
2710
  return [key, new Param(value, table[Table.Symbol.Columns][key])];
@@ -2770,7 +2775,7 @@ function isConfig(data) {
2770
2775
  return false;
2771
2776
  }
2772
2777
 
2773
- // ../../node_modules/.pnpm/drizzle-orm@0.36.1_@libsql+client-wasm@0.14.0_@types+react@18.3.12_bun-types@1.1.34_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/pg-core/query-builders/delete.js
2778
+ // ../../node_modules/.pnpm/drizzle-orm@0.36.3_@types+react@18.3.12_bun-types@1.1.35_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/pg-core/query-builders/delete.js
2774
2779
  class PgDeleteBase extends QueryPromise {
2775
2780
  constructor(table, session, dialect, withList) {
2776
2781
  super();
@@ -2813,96 +2818,7 @@ class PgDeleteBase extends QueryPromise {
2813
2818
  }
2814
2819
  }
2815
2820
 
2816
- // ../../node_modules/.pnpm/drizzle-orm@0.36.1_@libsql+client-wasm@0.14.0_@types+react@18.3.12_bun-types@1.1.34_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/pg-core/query-builders/insert.js
2817
- class PgInsertBuilder {
2818
- constructor(table, session, dialect, withList) {
2819
- this.table = table;
2820
- this.session = session;
2821
- this.dialect = dialect;
2822
- this.withList = withList;
2823
- }
2824
- static [entityKind] = "PgInsertBuilder";
2825
- values(values2) {
2826
- values2 = Array.isArray(values2) ? values2 : [values2];
2827
- if (values2.length === 0) {
2828
- throw new Error("values() must be called with at least one value");
2829
- }
2830
- const mappedValues = values2.map((entry) => {
2831
- const result = {};
2832
- const cols = this.table[Table.Symbol.Columns];
2833
- for (const colKey of Object.keys(entry)) {
2834
- const colValue = entry[colKey];
2835
- result[colKey] = is(colValue, SQL) ? colValue : new Param(colValue, cols[colKey]);
2836
- }
2837
- return result;
2838
- });
2839
- return new PgInsertBase(this.table, mappedValues, this.session, this.dialect, this.withList);
2840
- }
2841
- }
2842
-
2843
- class PgInsertBase extends QueryPromise {
2844
- constructor(table, values2, session, dialect, withList) {
2845
- super();
2846
- this.session = session;
2847
- this.dialect = dialect;
2848
- this.config = { table, values: values2, withList };
2849
- }
2850
- static [entityKind] = "PgInsert";
2851
- config;
2852
- returning(fields = this.config.table[Table.Symbol.Columns]) {
2853
- this.config.returning = orderSelectedFields(fields);
2854
- return this;
2855
- }
2856
- onConflictDoNothing(config = {}) {
2857
- if (config.target === undefined) {
2858
- this.config.onConflict = sql`do nothing`;
2859
- } else {
2860
- let targetColumn = "";
2861
- targetColumn = Array.isArray(config.target) ? config.target.map((it) => this.dialect.escapeName(this.dialect.casing.getColumnCasing(it))).join(",") : this.dialect.escapeName(this.dialect.casing.getColumnCasing(config.target));
2862
- const whereSql = config.where ? sql` where ${config.where}` : undefined;
2863
- this.config.onConflict = sql`(${sql.raw(targetColumn)})${whereSql} do nothing`;
2864
- }
2865
- return this;
2866
- }
2867
- onConflictDoUpdate(config) {
2868
- if (config.where && (config.targetWhere || config.setWhere)) {
2869
- throw new Error('You cannot use both "where" and "targetWhere"/"setWhere" at the same time - "where" is deprecated, use "targetWhere" or "setWhere" instead.');
2870
- }
2871
- const whereSql = config.where ? sql` where ${config.where}` : undefined;
2872
- const targetWhereSql = config.targetWhere ? sql` where ${config.targetWhere}` : undefined;
2873
- const setWhereSql = config.setWhere ? sql` where ${config.setWhere}` : undefined;
2874
- const setSql = this.dialect.buildUpdateSet(this.config.table, mapUpdateSet(this.config.table, config.set));
2875
- let targetColumn = "";
2876
- targetColumn = Array.isArray(config.target) ? config.target.map((it) => this.dialect.escapeName(this.dialect.casing.getColumnCasing(it))).join(",") : this.dialect.escapeName(this.dialect.casing.getColumnCasing(config.target));
2877
- this.config.onConflict = sql`(${sql.raw(targetColumn)})${targetWhereSql} do update set ${setSql}${whereSql}${setWhereSql}`;
2878
- return this;
2879
- }
2880
- getSQL() {
2881
- return this.dialect.buildInsertQuery(this.config);
2882
- }
2883
- toSQL() {
2884
- const { typings: _typings, ...rest } = this.dialect.sqlToQuery(this.getSQL());
2885
- return rest;
2886
- }
2887
- _prepare(name) {
2888
- return tracer.startActiveSpan("drizzle.prepareQuery", () => {
2889
- return this.session.prepareQuery(this.dialect.sqlToQuery(this.getSQL()), this.config.returning, name, true);
2890
- });
2891
- }
2892
- prepare(name) {
2893
- return this._prepare(name);
2894
- }
2895
- execute = (placeholderValues) => {
2896
- return tracer.startActiveSpan("drizzle.operation", () => {
2897
- return this._prepare().execute(placeholderValues);
2898
- });
2899
- };
2900
- $dynamic() {
2901
- return this;
2902
- }
2903
- }
2904
-
2905
- // ../../node_modules/.pnpm/drizzle-orm@0.36.1_@libsql+client-wasm@0.14.0_@types+react@18.3.12_bun-types@1.1.34_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/alias.js
2821
+ // ../../node_modules/.pnpm/drizzle-orm@0.36.3_@types+react@18.3.12_bun-types@1.1.35_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/alias.js
2906
2822
  class ColumnAliasProxyHandler {
2907
2823
  constructor(table) {
2908
2824
  this.table = table;
@@ -2981,7 +2897,7 @@ function mapColumnsInSQLToAlias(query, alias) {
2981
2897
  }));
2982
2898
  }
2983
2899
 
2984
- // ../../node_modules/.pnpm/drizzle-orm@0.36.1_@libsql+client-wasm@0.14.0_@types+react@18.3.12_bun-types@1.1.34_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/casing.js
2900
+ // ../../node_modules/.pnpm/drizzle-orm@0.36.3_@types+react@18.3.12_bun-types@1.1.35_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/casing.js
2985
2901
  function toSnakeCase(input) {
2986
2902
  const words = input.replace(/['\u2019]/g, "").match(/[\da-z]+|[A-Z]+(?![a-z])|[A-Z][\da-z]+/g) ?? [];
2987
2903
  return words.map((word) => word.toLowerCase()).join("_");
@@ -3034,7 +2950,7 @@ class CasingCache {
3034
2950
  }
3035
2951
  }
3036
2952
 
3037
- // ../../node_modules/.pnpm/drizzle-orm@0.36.1_@libsql+client-wasm@0.14.0_@types+react@18.3.12_bun-types@1.1.34_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/errors.js
2953
+ // ../../node_modules/.pnpm/drizzle-orm@0.36.3_@types+react@18.3.12_bun-types@1.1.35_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/errors.js
3038
2954
  class DrizzleError extends Error {
3039
2955
  static [entityKind] = "DrizzleError";
3040
2956
  constructor({ message, cause }) {
@@ -3051,7 +2967,7 @@ class TransactionRollbackError extends DrizzleError {
3051
2967
  }
3052
2968
  }
3053
2969
 
3054
- // ../../node_modules/.pnpm/drizzle-orm@0.36.1_@libsql+client-wasm@0.14.0_@types+react@18.3.12_bun-types@1.1.34_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/pg-core/columns/date.js
2970
+ // ../../node_modules/.pnpm/drizzle-orm@0.36.3_@types+react@18.3.12_bun-types@1.1.35_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/pg-core/columns/date.js
3055
2971
  class PgDate extends PgColumn {
3056
2972
  static [entityKind] = "PgDate";
3057
2973
  getSQLType() {
@@ -3071,7 +2987,7 @@ class PgDateString extends PgColumn {
3071
2987
  }
3072
2988
  }
3073
2989
 
3074
- // ../../node_modules/.pnpm/drizzle-orm@0.36.1_@libsql+client-wasm@0.14.0_@types+react@18.3.12_bun-types@1.1.34_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/pg-core/columns/json.js
2990
+ // ../../node_modules/.pnpm/drizzle-orm@0.36.3_@types+react@18.3.12_bun-types@1.1.35_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/pg-core/columns/json.js
3075
2991
  class PgJson extends PgColumn {
3076
2992
  static [entityKind] = "PgJson";
3077
2993
  constructor(table, config) {
@@ -3095,7 +3011,7 @@ class PgJson extends PgColumn {
3095
3011
  }
3096
3012
  }
3097
3013
 
3098
- // ../../node_modules/.pnpm/drizzle-orm@0.36.1_@libsql+client-wasm@0.14.0_@types+react@18.3.12_bun-types@1.1.34_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/pg-core/columns/jsonb.js
3014
+ // ../../node_modules/.pnpm/drizzle-orm@0.36.3_@types+react@18.3.12_bun-types@1.1.35_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/pg-core/columns/jsonb.js
3099
3015
  class PgJsonb extends PgColumn {
3100
3016
  static [entityKind] = "PgJsonb";
3101
3017
  constructor(table, config) {
@@ -3119,7 +3035,7 @@ class PgJsonb extends PgColumn {
3119
3035
  }
3120
3036
  }
3121
3037
 
3122
- // ../../node_modules/.pnpm/drizzle-orm@0.36.1_@libsql+client-wasm@0.14.0_@types+react@18.3.12_bun-types@1.1.34_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/pg-core/columns/numeric.js
3038
+ // ../../node_modules/.pnpm/drizzle-orm@0.36.3_@types+react@18.3.12_bun-types@1.1.35_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/pg-core/columns/numeric.js
3123
3039
  class PgNumeric extends PgColumn {
3124
3040
  static [entityKind] = "PgNumeric";
3125
3041
  precision;
@@ -3140,7 +3056,7 @@ class PgNumeric extends PgColumn {
3140
3056
  }
3141
3057
  }
3142
3058
 
3143
- // ../../node_modules/.pnpm/drizzle-orm@0.36.1_@libsql+client-wasm@0.14.0_@types+react@18.3.12_bun-types@1.1.34_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/pg-core/columns/time.js
3059
+ // ../../node_modules/.pnpm/drizzle-orm@0.36.3_@types+react@18.3.12_bun-types@1.1.35_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/pg-core/columns/time.js
3144
3060
  class PgTime extends PgColumn {
3145
3061
  static [entityKind] = "PgTime";
3146
3062
  withTimezone;
@@ -3156,7 +3072,7 @@ class PgTime extends PgColumn {
3156
3072
  }
3157
3073
  }
3158
3074
 
3159
- // ../../node_modules/.pnpm/drizzle-orm@0.36.1_@libsql+client-wasm@0.14.0_@types+react@18.3.12_bun-types@1.1.34_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/pg-core/columns/timestamp.js
3075
+ // ../../node_modules/.pnpm/drizzle-orm@0.36.3_@types+react@18.3.12_bun-types@1.1.35_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/pg-core/columns/timestamp.js
3160
3076
  class PgTimestamp extends PgColumn {
3161
3077
  static [entityKind] = "PgTimestamp";
3162
3078
  withTimezone;
@@ -3192,7 +3108,7 @@ class PgTimestampString extends PgColumn {
3192
3108
  }
3193
3109
  }
3194
3110
 
3195
- // ../../node_modules/.pnpm/drizzle-orm@0.36.1_@libsql+client-wasm@0.14.0_@types+react@18.3.12_bun-types@1.1.34_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/pg-core/columns/uuid.js
3111
+ // ../../node_modules/.pnpm/drizzle-orm@0.36.3_@types+react@18.3.12_bun-types@1.1.35_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/pg-core/columns/uuid.js
3196
3112
  class PgUUID extends PgColumn {
3197
3113
  static [entityKind] = "PgUUID";
3198
3114
  getSQLType() {
@@ -3200,7 +3116,7 @@ class PgUUID extends PgColumn {
3200
3116
  }
3201
3117
  }
3202
3118
 
3203
- // ../../node_modules/.pnpm/drizzle-orm@0.36.1_@libsql+client-wasm@0.14.0_@types+react@18.3.12_bun-types@1.1.34_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/pg-core/table.js
3119
+ // ../../node_modules/.pnpm/drizzle-orm@0.36.3_@types+react@18.3.12_bun-types@1.1.35_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/pg-core/table.js
3204
3120
  var InlineForeignKeys = Symbol.for("drizzle:PgInlineForeignKeys");
3205
3121
  var EnableRLS = Symbol.for("drizzle:EnableRLS");
3206
3122
 
@@ -3215,7 +3131,7 @@ class PgTable extends Table {
3215
3131
  [Table.Symbol.ExtraConfigBuilder] = undefined;
3216
3132
  }
3217
3133
 
3218
- // ../../node_modules/.pnpm/drizzle-orm@0.36.1_@libsql+client-wasm@0.14.0_@types+react@18.3.12_bun-types@1.1.34_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/pg-core/primary-keys.js
3134
+ // ../../node_modules/.pnpm/drizzle-orm@0.36.3_@types+react@18.3.12_bun-types@1.1.35_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/pg-core/primary-keys.js
3219
3135
  class PrimaryKeyBuilder {
3220
3136
  static [entityKind] = "PgPrimaryKeyBuilder";
3221
3137
  columns;
@@ -3243,7 +3159,7 @@ class PrimaryKey {
3243
3159
  }
3244
3160
  }
3245
3161
 
3246
- // ../../node_modules/.pnpm/drizzle-orm@0.36.1_@libsql+client-wasm@0.14.0_@types+react@18.3.12_bun-types@1.1.34_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/sql/expressions/conditions.js
3162
+ // ../../node_modules/.pnpm/drizzle-orm@0.36.3_@types+react@18.3.12_bun-types@1.1.35_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/sql/expressions/conditions.js
3247
3163
  function bindIfParam(value, column) {
3248
3164
  if (isDriverValueEncoder(column) && !isSQLWrapper(value) && !is(value, Param) && !is(value, Placeholder) && !is(value, Column) && !is(value, Table) && !is(value, View)) {
3249
3165
  return new Param(value, column);
@@ -3348,7 +3264,7 @@ function notIlike(column, value) {
3348
3264
  return sql`${column} not ilike ${value}`;
3349
3265
  }
3350
3266
 
3351
- // ../../node_modules/.pnpm/drizzle-orm@0.36.1_@libsql+client-wasm@0.14.0_@types+react@18.3.12_bun-types@1.1.34_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/sql/expressions/select.js
3267
+ // ../../node_modules/.pnpm/drizzle-orm@0.36.3_@types+react@18.3.12_bun-types@1.1.35_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/sql/expressions/select.js
3352
3268
  function asc(column) {
3353
3269
  return sql`${column} asc`;
3354
3270
  }
@@ -3356,7 +3272,7 @@ function desc(column) {
3356
3272
  return sql`${column} desc`;
3357
3273
  }
3358
3274
 
3359
- // ../../node_modules/.pnpm/drizzle-orm@0.36.1_@libsql+client-wasm@0.14.0_@types+react@18.3.12_bun-types@1.1.34_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/relations.js
3275
+ // ../../node_modules/.pnpm/drizzle-orm@0.36.3_@types+react@18.3.12_bun-types@1.1.35_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/relations.js
3360
3276
  class Relation {
3361
3277
  constructor(sourceTable, referencedTable, relationName) {
3362
3278
  this.sourceTable = sourceTable;
@@ -3576,12 +3492,12 @@ function mapRelationalRow(tablesConfig, tableConfig, row, buildQueryResultSelect
3576
3492
  return result;
3577
3493
  }
3578
3494
 
3579
- // ../../node_modules/.pnpm/drizzle-orm@0.36.1_@libsql+client-wasm@0.14.0_@types+react@18.3.12_bun-types@1.1.34_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/pg-core/view-base.js
3495
+ // ../../node_modules/.pnpm/drizzle-orm@0.36.3_@types+react@18.3.12_bun-types@1.1.35_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/pg-core/view-base.js
3580
3496
  class PgViewBase extends View {
3581
3497
  static [entityKind] = "PgViewBase";
3582
3498
  }
3583
3499
 
3584
- // ../../node_modules/.pnpm/drizzle-orm@0.36.1_@libsql+client-wasm@0.14.0_@types+react@18.3.12_bun-types@1.1.34_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/pg-core/dialect.js
3500
+ // ../../node_modules/.pnpm/drizzle-orm@0.36.3_@types+react@18.3.12_bun-types@1.1.35_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/pg-core/dialect.js
3585
3501
  class PgDialect {
3586
3502
  static [entityKind] = "PgDialect";
3587
3503
  casing;
@@ -3617,7 +3533,7 @@ class PgDialect {
3617
3533
  return `"${name}"`;
3618
3534
  }
3619
3535
  escapeParam(num) {
3620
- return `\$${num + 1}`;
3536
+ return `$${num + 1}`;
3621
3537
  }
3622
3538
  escapeString(str) {
3623
3539
  return `'${str.replace(/'/g, "''")}'`;
@@ -3655,12 +3571,19 @@ class PgDialect {
3655
3571
  return [res];
3656
3572
  }));
3657
3573
  }
3658
- buildUpdateQuery({ table, set, where, returning, withList }) {
3574
+ buildUpdateQuery({ table, set, where, returning, withList, from, joins }) {
3659
3575
  const withSql = this.buildWithCTE(withList);
3576
+ const tableName = table[PgTable.Symbol.Name];
3577
+ const tableSchema = table[PgTable.Symbol.Schema];
3578
+ const origTableName = table[PgTable.Symbol.OriginalName];
3579
+ const alias = tableName === origTableName ? undefined : tableName;
3580
+ const tableSql = sql`${tableSchema ? sql`${sql.identifier(tableSchema)}.` : undefined}${sql.identifier(origTableName)}${alias && sql` ${sql.identifier(alias)}`}`;
3660
3581
  const setSql = this.buildUpdateSet(table, set);
3661
- const returningSql = returning ? sql` returning ${this.buildSelection(returning, { isSingleTable: true })}` : undefined;
3582
+ const fromSql = from && sql.join([sql.raw(" from "), this.buildFromTable(from)]);
3583
+ const joinsSql = this.buildJoins(joins);
3584
+ const returningSql = returning ? sql` returning ${this.buildSelection(returning, { isSingleTable: !from })}` : undefined;
3662
3585
  const whereSql = where ? sql` where ${where}` : undefined;
3663
- return sql`${withSql}update ${table} set ${setSql}${whereSql}${returningSql}`;
3586
+ return sql`${withSql}update ${tableSql} set ${setSql}${fromSql}${joinsSql}${whereSql}${returningSql}`;
3664
3587
  }
3665
3588
  buildSelection(fields, { isSingleTable = false } = {}) {
3666
3589
  const columnsLen = fields.length;
@@ -3697,6 +3620,48 @@ class PgDialect {
3697
3620
  });
3698
3621
  return sql.join(chunks);
3699
3622
  }
3623
+ buildJoins(joins) {
3624
+ if (!joins || joins.length === 0) {
3625
+ return;
3626
+ }
3627
+ const joinsArray = [];
3628
+ for (const [index, joinMeta] of joins.entries()) {
3629
+ if (index === 0) {
3630
+ joinsArray.push(sql` `);
3631
+ }
3632
+ const table = joinMeta.table;
3633
+ const lateralSql = joinMeta.lateral ? sql` lateral` : undefined;
3634
+ if (is(table, PgTable)) {
3635
+ const tableName = table[PgTable.Symbol.Name];
3636
+ const tableSchema = table[PgTable.Symbol.Schema];
3637
+ const origTableName = table[PgTable.Symbol.OriginalName];
3638
+ const alias = tableName === origTableName ? undefined : joinMeta.alias;
3639
+ joinsArray.push(sql`${sql.raw(joinMeta.joinType)} join${lateralSql} ${tableSchema ? sql`${sql.identifier(tableSchema)}.` : undefined}${sql.identifier(origTableName)}${alias && sql` ${sql.identifier(alias)}`} on ${joinMeta.on}`);
3640
+ } else if (is(table, View)) {
3641
+ const viewName = table[ViewBaseConfig].name;
3642
+ const viewSchema = table[ViewBaseConfig].schema;
3643
+ const origViewName = table[ViewBaseConfig].originalName;
3644
+ const alias = viewName === origViewName ? undefined : joinMeta.alias;
3645
+ joinsArray.push(sql`${sql.raw(joinMeta.joinType)} join${lateralSql} ${viewSchema ? sql`${sql.identifier(viewSchema)}.` : undefined}${sql.identifier(origViewName)}${alias && sql` ${sql.identifier(alias)}`} on ${joinMeta.on}`);
3646
+ } else {
3647
+ joinsArray.push(sql`${sql.raw(joinMeta.joinType)} join${lateralSql} ${table} on ${joinMeta.on}`);
3648
+ }
3649
+ if (index < joins.length - 1) {
3650
+ joinsArray.push(sql` `);
3651
+ }
3652
+ }
3653
+ return sql.join(joinsArray);
3654
+ }
3655
+ buildFromTable(table) {
3656
+ if (is(table, Table) && table[Table.Symbol.OriginalName] !== table[Table.Symbol.Name]) {
3657
+ let fullName = sql`${sql.identifier(table[Table.Symbol.OriginalName])}`;
3658
+ if (table[Table.Symbol.Schema]) {
3659
+ fullName = sql`${sql.identifier(table[Table.Symbol.Schema])}.${fullName}`;
3660
+ }
3661
+ return sql`${fullName} ${sql.identifier(table[Table.Symbol.Name])}`;
3662
+ }
3663
+ return table;
3664
+ }
3700
3665
  buildSelectQuery({
3701
3666
  withList,
3702
3667
  fields,
@@ -3727,45 +3692,8 @@ class PgDialect {
3727
3692
  distinctSql = distinct === true ? sql` distinct` : sql` distinct on (${sql.join(distinct.on, sql`, `)})`;
3728
3693
  }
3729
3694
  const selection = this.buildSelection(fieldsList, { isSingleTable });
3730
- const tableSql = (() => {
3731
- if (is(table, Table) && table[Table.Symbol.OriginalName] !== table[Table.Symbol.Name]) {
3732
- let fullName = sql`${sql.identifier(table[Table.Symbol.OriginalName])}`;
3733
- if (table[Table.Symbol.Schema]) {
3734
- fullName = sql`${sql.identifier(table[Table.Symbol.Schema])}.${fullName}`;
3735
- }
3736
- return sql`${fullName} ${sql.identifier(table[Table.Symbol.Name])}`;
3737
- }
3738
- return table;
3739
- })();
3740
- const joinsArray = [];
3741
- if (joins) {
3742
- for (const [index, joinMeta] of joins.entries()) {
3743
- if (index === 0) {
3744
- joinsArray.push(sql` `);
3745
- }
3746
- const table2 = joinMeta.table;
3747
- const lateralSql = joinMeta.lateral ? sql` lateral` : undefined;
3748
- if (is(table2, PgTable)) {
3749
- const tableName = table2[PgTable.Symbol.Name];
3750
- const tableSchema = table2[PgTable.Symbol.Schema];
3751
- const origTableName = table2[PgTable.Symbol.OriginalName];
3752
- const alias = tableName === origTableName ? undefined : joinMeta.alias;
3753
- joinsArray.push(sql`${sql.raw(joinMeta.joinType)} join${lateralSql} ${tableSchema ? sql`${sql.identifier(tableSchema)}.` : undefined}${sql.identifier(origTableName)}${alias && sql` ${sql.identifier(alias)}`} on ${joinMeta.on}`);
3754
- } else if (is(table2, View)) {
3755
- const viewName = table2[ViewBaseConfig].name;
3756
- const viewSchema = table2[ViewBaseConfig].schema;
3757
- const origViewName = table2[ViewBaseConfig].originalName;
3758
- const alias = viewName === origViewName ? undefined : joinMeta.alias;
3759
- joinsArray.push(sql`${sql.raw(joinMeta.joinType)} join${lateralSql} ${viewSchema ? sql`${sql.identifier(viewSchema)}.` : undefined}${sql.identifier(origViewName)}${alias && sql` ${sql.identifier(alias)}`} on ${joinMeta.on}`);
3760
- } else {
3761
- joinsArray.push(sql`${sql.raw(joinMeta.joinType)} join${lateralSql} ${table2} on ${joinMeta.on}`);
3762
- }
3763
- if (index < joins.length - 1) {
3764
- joinsArray.push(sql` `);
3765
- }
3766
- }
3767
- }
3768
- const joinsSql = sql.join(joinsArray);
3695
+ const tableSql = this.buildFromTable(table);
3696
+ const joinsSql = this.buildJoins(joins);
3769
3697
  const whereSql = where ? sql` where ${where}` : undefined;
3770
3698
  const havingSql = having ? sql` having ${having}` : undefined;
3771
3699
  let orderBySql;
@@ -3838,41 +3766,52 @@ class PgDialect {
3838
3766
  const offsetSql = offset ? sql` offset ${offset}` : undefined;
3839
3767
  return sql`${leftChunk}${operatorChunk}${rightChunk}${orderBySql}${limitSql}${offsetSql}`;
3840
3768
  }
3841
- buildInsertQuery({ table, values: values2, onConflict, returning, withList }) {
3769
+ buildInsertQuery({ table, values: valuesOrSelect, onConflict, returning, withList, select: select2 }) {
3842
3770
  const valuesSqlList = [];
3843
3771
  const columns = table[Table.Symbol.Columns];
3844
3772
  const colEntries = Object.entries(columns).filter(([_, col]) => !col.shouldDisableInsert());
3845
3773
  const insertOrder = colEntries.map(([, column]) => sql.identifier(this.casing.getColumnCasing(column)));
3846
- for (const [valueIndex, value] of values2.entries()) {
3847
- const valueList = [];
3848
- for (const [fieldName, col] of colEntries) {
3849
- const colValue = value[fieldName];
3850
- if (colValue === undefined || is(colValue, Param) && colValue.value === undefined) {
3851
- if (col.defaultFn !== undefined) {
3852
- const defaultFnResult = col.defaultFn();
3853
- const defaultValue = is(defaultFnResult, SQL) ? defaultFnResult : sql.param(defaultFnResult, col);
3854
- valueList.push(defaultValue);
3855
- } else if (!col.default && col.onUpdateFn !== undefined) {
3856
- const onUpdateFnResult = col.onUpdateFn();
3857
- const newValue = is(onUpdateFnResult, SQL) ? onUpdateFnResult : sql.param(onUpdateFnResult, col);
3858
- valueList.push(newValue);
3774
+ if (select2) {
3775
+ const select22 = valuesOrSelect;
3776
+ if (is(select22, SQL)) {
3777
+ valuesSqlList.push(select22);
3778
+ } else {
3779
+ valuesSqlList.push(select22.getSQL());
3780
+ }
3781
+ } else {
3782
+ const values2 = valuesOrSelect;
3783
+ valuesSqlList.push(sql.raw("values "));
3784
+ for (const [valueIndex, value] of values2.entries()) {
3785
+ const valueList = [];
3786
+ for (const [fieldName, col] of colEntries) {
3787
+ const colValue = value[fieldName];
3788
+ if (colValue === undefined || is(colValue, Param) && colValue.value === undefined) {
3789
+ if (col.defaultFn !== undefined) {
3790
+ const defaultFnResult = col.defaultFn();
3791
+ const defaultValue = is(defaultFnResult, SQL) ? defaultFnResult : sql.param(defaultFnResult, col);
3792
+ valueList.push(defaultValue);
3793
+ } else if (!col.default && col.onUpdateFn !== undefined) {
3794
+ const onUpdateFnResult = col.onUpdateFn();
3795
+ const newValue = is(onUpdateFnResult, SQL) ? onUpdateFnResult : sql.param(onUpdateFnResult, col);
3796
+ valueList.push(newValue);
3797
+ } else {
3798
+ valueList.push(sql`default`);
3799
+ }
3859
3800
  } else {
3860
- valueList.push(sql`default`);
3801
+ valueList.push(colValue);
3861
3802
  }
3862
- } else {
3863
- valueList.push(colValue);
3864
3803
  }
3865
- }
3866
- valuesSqlList.push(valueList);
3867
- if (valueIndex < values2.length - 1) {
3868
- valuesSqlList.push(sql`, `);
3804
+ valuesSqlList.push(valueList);
3805
+ if (valueIndex < values2.length - 1) {
3806
+ valuesSqlList.push(sql`, `);
3807
+ }
3869
3808
  }
3870
3809
  }
3871
3810
  const withSql = this.buildWithCTE(withList);
3872
3811
  const valuesSql = sql.join(valuesSqlList);
3873
3812
  const returningSql = returning ? sql` returning ${this.buildSelection(returning, { isSingleTable: true })}` : undefined;
3874
3813
  const onConflictSql = onConflict ? sql` on conflict ${onConflict}` : undefined;
3875
- return sql`${withSql}insert into ${table} ${insertOrder} values ${valuesSql}${onConflictSql}${returningSql}`;
3814
+ return sql`${withSql}insert into ${table} ${insertOrder} ${valuesSql}${onConflictSql}${returningSql}`;
3876
3815
  }
3877
3816
  buildRefreshMaterializedViewQuery({ view, concurrently, withNoData }) {
3878
3817
  const concurrentlySql = concurrently ? sql` concurrently` : undefined;
@@ -4114,7 +4053,7 @@ class PgDialect {
4114
4053
  }
4115
4054
  }
4116
4055
 
4117
- // ../../node_modules/.pnpm/drizzle-orm@0.36.1_@libsql+client-wasm@0.14.0_@types+react@18.3.12_bun-types@1.1.34_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/selection-proxy.js
4056
+ // ../../node_modules/.pnpm/drizzle-orm@0.36.3_@types+react@18.3.12_bun-types@1.1.35_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/selection-proxy.js
4118
4057
  class SelectionProxyHandler {
4119
4058
  static [entityKind] = "SelectionProxyHandler";
4120
4059
  config;
@@ -4166,7 +4105,7 @@ class SelectionProxyHandler {
4166
4105
  }
4167
4106
  }
4168
4107
 
4169
- // ../../node_modules/.pnpm/drizzle-orm@0.36.1_@libsql+client-wasm@0.14.0_@types+react@18.3.12_bun-types@1.1.34_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/query-builders/query-builder.js
4108
+ // ../../node_modules/.pnpm/drizzle-orm@0.36.3_@types+react@18.3.12_bun-types@1.1.35_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/query-builders/query-builder.js
4170
4109
  class TypedQueryBuilder {
4171
4110
  static [entityKind] = "TypedQueryBuilder";
4172
4111
  getSelectedFields() {
@@ -4174,7 +4113,7 @@ class TypedQueryBuilder {
4174
4113
  }
4175
4114
  }
4176
4115
 
4177
- // ../../node_modules/.pnpm/drizzle-orm@0.36.1_@libsql+client-wasm@0.14.0_@types+react@18.3.12_bun-types@1.1.34_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/pg-core/query-builders/select.js
4116
+ // ../../node_modules/.pnpm/drizzle-orm@0.36.3_@types+react@18.3.12_bun-types@1.1.35_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/pg-core/query-builders/select.js
4178
4117
  class PgSelectBuilder {
4179
4118
  static [entityKind] = "PgSelectBuilder";
4180
4119
  fields;
@@ -4452,7 +4391,7 @@ var intersectAll = createSetOperator("intersect", true);
4452
4391
  var except = createSetOperator("except", false);
4453
4392
  var exceptAll = createSetOperator("except", true);
4454
4393
 
4455
- // ../../node_modules/.pnpm/drizzle-orm@0.36.1_@libsql+client-wasm@0.14.0_@types+react@18.3.12_bun-types@1.1.34_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/pg-core/query-builders/query-builder.js
4394
+ // ../../node_modules/.pnpm/drizzle-orm@0.36.3_@types+react@18.3.12_bun-types@1.1.35_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/pg-core/query-builders/query-builder.js
4456
4395
  class QueryBuilder {
4457
4396
  static [entityKind] = "PgQueryBuilder";
4458
4397
  dialect;
@@ -4531,7 +4470,103 @@ class QueryBuilder {
4531
4470
  }
4532
4471
  }
4533
4472
 
4534
- // ../../node_modules/.pnpm/drizzle-orm@0.36.1_@libsql+client-wasm@0.14.0_@types+react@18.3.12_bun-types@1.1.34_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/pg-core/query-builders/refresh-materialized-view.js
4473
+ // ../../node_modules/.pnpm/drizzle-orm@0.36.3_@types+react@18.3.12_bun-types@1.1.35_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/pg-core/query-builders/insert.js
4474
+ class PgInsertBuilder {
4475
+ constructor(table, session, dialect, withList) {
4476
+ this.table = table;
4477
+ this.session = session;
4478
+ this.dialect = dialect;
4479
+ this.withList = withList;
4480
+ }
4481
+ static [entityKind] = "PgInsertBuilder";
4482
+ values(values2) {
4483
+ values2 = Array.isArray(values2) ? values2 : [values2];
4484
+ if (values2.length === 0) {
4485
+ throw new Error("values() must be called with at least one value");
4486
+ }
4487
+ const mappedValues = values2.map((entry) => {
4488
+ const result = {};
4489
+ const cols = this.table[Table.Symbol.Columns];
4490
+ for (const colKey of Object.keys(entry)) {
4491
+ const colValue = entry[colKey];
4492
+ result[colKey] = is(colValue, SQL) ? colValue : new Param(colValue, cols[colKey]);
4493
+ }
4494
+ return result;
4495
+ });
4496
+ return new PgInsertBase(this.table, mappedValues, this.session, this.dialect, this.withList);
4497
+ }
4498
+ select(selectQuery) {
4499
+ const select2 = typeof selectQuery === "function" ? selectQuery(new QueryBuilder) : selectQuery;
4500
+ if (!is(select2, SQL) && !haveSameKeys(this.table[Columns], select2._.selectedFields)) {
4501
+ throw new Error("Insert select error: selected fields are not the same or are in a different order compared to the table definition");
4502
+ }
4503
+ return new PgInsertBase(this.table, select2, this.session, this.dialect, this.withList, true);
4504
+ }
4505
+ }
4506
+
4507
+ class PgInsertBase extends QueryPromise {
4508
+ constructor(table, values2, session, dialect, withList, select2) {
4509
+ super();
4510
+ this.session = session;
4511
+ this.dialect = dialect;
4512
+ this.config = { table, values: values2, withList, select: select2 };
4513
+ }
4514
+ static [entityKind] = "PgInsert";
4515
+ config;
4516
+ returning(fields = this.config.table[Table.Symbol.Columns]) {
4517
+ this.config.returning = orderSelectedFields(fields);
4518
+ return this;
4519
+ }
4520
+ onConflictDoNothing(config = {}) {
4521
+ if (config.target === undefined) {
4522
+ this.config.onConflict = sql`do nothing`;
4523
+ } else {
4524
+ let targetColumn = "";
4525
+ targetColumn = Array.isArray(config.target) ? config.target.map((it) => this.dialect.escapeName(this.dialect.casing.getColumnCasing(it))).join(",") : this.dialect.escapeName(this.dialect.casing.getColumnCasing(config.target));
4526
+ const whereSql = config.where ? sql` where ${config.where}` : undefined;
4527
+ this.config.onConflict = sql`(${sql.raw(targetColumn)})${whereSql} do nothing`;
4528
+ }
4529
+ return this;
4530
+ }
4531
+ onConflictDoUpdate(config) {
4532
+ if (config.where && (config.targetWhere || config.setWhere)) {
4533
+ throw new Error('You cannot use both "where" and "targetWhere"/"setWhere" at the same time - "where" is deprecated, use "targetWhere" or "setWhere" instead.');
4534
+ }
4535
+ const whereSql = config.where ? sql` where ${config.where}` : undefined;
4536
+ const targetWhereSql = config.targetWhere ? sql` where ${config.targetWhere}` : undefined;
4537
+ const setWhereSql = config.setWhere ? sql` where ${config.setWhere}` : undefined;
4538
+ const setSql = this.dialect.buildUpdateSet(this.config.table, mapUpdateSet(this.config.table, config.set));
4539
+ let targetColumn = "";
4540
+ targetColumn = Array.isArray(config.target) ? config.target.map((it) => this.dialect.escapeName(this.dialect.casing.getColumnCasing(it))).join(",") : this.dialect.escapeName(this.dialect.casing.getColumnCasing(config.target));
4541
+ this.config.onConflict = sql`(${sql.raw(targetColumn)})${targetWhereSql} do update set ${setSql}${whereSql}${setWhereSql}`;
4542
+ return this;
4543
+ }
4544
+ getSQL() {
4545
+ return this.dialect.buildInsertQuery(this.config);
4546
+ }
4547
+ toSQL() {
4548
+ const { typings: _typings, ...rest } = this.dialect.sqlToQuery(this.getSQL());
4549
+ return rest;
4550
+ }
4551
+ _prepare(name) {
4552
+ return tracer.startActiveSpan("drizzle.prepareQuery", () => {
4553
+ return this.session.prepareQuery(this.dialect.sqlToQuery(this.getSQL()), this.config.returning, name, true);
4554
+ });
4555
+ }
4556
+ prepare(name) {
4557
+ return this._prepare(name);
4558
+ }
4559
+ execute = (placeholderValues) => {
4560
+ return tracer.startActiveSpan("drizzle.operation", () => {
4561
+ return this._prepare().execute(placeholderValues);
4562
+ });
4563
+ };
4564
+ $dynamic() {
4565
+ return this;
4566
+ }
4567
+ }
4568
+
4569
+ // ../../node_modules/.pnpm/drizzle-orm@0.36.3_@types+react@18.3.12_bun-types@1.1.35_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/pg-core/query-builders/refresh-materialized-view.js
4535
4570
  class PgRefreshMaterializedView extends QueryPromise {
4536
4571
  constructor(view, session, dialect) {
4537
4572
  super();
@@ -4577,7 +4612,7 @@ class PgRefreshMaterializedView extends QueryPromise {
4577
4612
  };
4578
4613
  }
4579
4614
 
4580
- // ../../node_modules/.pnpm/drizzle-orm@0.36.1_@libsql+client-wasm@0.14.0_@types+react@18.3.12_bun-types@1.1.34_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/pg-core/query-builders/update.js
4615
+ // ../../node_modules/.pnpm/drizzle-orm@0.36.3_@types+react@18.3.12_bun-types@1.1.35_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/pg-core/query-builders/update.js
4581
4616
  class PgUpdateBuilder {
4582
4617
  constructor(table, session, dialect, withList) {
4583
4618
  this.table = table;
@@ -4596,15 +4631,92 @@ class PgUpdateBase extends QueryPromise {
4596
4631
  super();
4597
4632
  this.session = session;
4598
4633
  this.dialect = dialect;
4599
- this.config = { set, table, withList };
4634
+ this.config = { set, table, withList, joins: [] };
4635
+ this.tableName = getTableLikeName(table);
4636
+ this.joinsNotNullableMap = typeof this.tableName === "string" ? { [this.tableName]: true } : {};
4600
4637
  }
4601
4638
  static [entityKind] = "PgUpdate";
4602
4639
  config;
4640
+ tableName;
4641
+ joinsNotNullableMap;
4642
+ from(source) {
4643
+ const tableName = getTableLikeName(source);
4644
+ if (typeof tableName === "string") {
4645
+ this.joinsNotNullableMap[tableName] = true;
4646
+ }
4647
+ this.config.from = source;
4648
+ return this;
4649
+ }
4650
+ getTableLikeFields(table) {
4651
+ if (is(table, PgTable)) {
4652
+ return table[Table.Symbol.Columns];
4653
+ } else if (is(table, Subquery)) {
4654
+ return table._.selectedFields;
4655
+ }
4656
+ return table[ViewBaseConfig].selectedFields;
4657
+ }
4658
+ createJoin(joinType) {
4659
+ return (table, on) => {
4660
+ const tableName = getTableLikeName(table);
4661
+ if (typeof tableName === "string" && this.config.joins.some((join) => join.alias === tableName)) {
4662
+ throw new Error(`Alias "${tableName}" is already used in this query`);
4663
+ }
4664
+ if (typeof on === "function") {
4665
+ const from = this.config.from && !is(this.config.from, SQL) ? this.getTableLikeFields(this.config.from) : undefined;
4666
+ on = on(new Proxy(this.config.table[Table.Symbol.Columns], new SelectionProxyHandler({ sqlAliasedBehavior: "sql", sqlBehavior: "sql" })), from && new Proxy(from, new SelectionProxyHandler({ sqlAliasedBehavior: "sql", sqlBehavior: "sql" })));
4667
+ }
4668
+ this.config.joins.push({ on, table, joinType, alias: tableName });
4669
+ if (typeof tableName === "string") {
4670
+ switch (joinType) {
4671
+ case "left": {
4672
+ this.joinsNotNullableMap[tableName] = false;
4673
+ break;
4674
+ }
4675
+ case "right": {
4676
+ this.joinsNotNullableMap = Object.fromEntries(Object.entries(this.joinsNotNullableMap).map(([key]) => [key, false]));
4677
+ this.joinsNotNullableMap[tableName] = true;
4678
+ break;
4679
+ }
4680
+ case "inner": {
4681
+ this.joinsNotNullableMap[tableName] = true;
4682
+ break;
4683
+ }
4684
+ case "full": {
4685
+ this.joinsNotNullableMap = Object.fromEntries(Object.entries(this.joinsNotNullableMap).map(([key]) => [key, false]));
4686
+ this.joinsNotNullableMap[tableName] = false;
4687
+ break;
4688
+ }
4689
+ }
4690
+ }
4691
+ return this;
4692
+ };
4693
+ }
4694
+ leftJoin = this.createJoin("left");
4695
+ rightJoin = this.createJoin("right");
4696
+ innerJoin = this.createJoin("inner");
4697
+ fullJoin = this.createJoin("full");
4603
4698
  where(where) {
4604
4699
  this.config.where = where;
4605
4700
  return this;
4606
4701
  }
4607
- returning(fields = this.config.table[Table.Symbol.Columns]) {
4702
+ returning(fields) {
4703
+ if (!fields) {
4704
+ fields = Object.assign({}, this.config.table[Table.Symbol.Columns]);
4705
+ if (this.config.from) {
4706
+ const tableName = getTableLikeName(this.config.from);
4707
+ if (typeof tableName === "string" && this.config.from && !is(this.config.from, SQL)) {
4708
+ const fromFields = this.getTableLikeFields(this.config.from);
4709
+ fields[tableName] = fromFields;
4710
+ }
4711
+ for (const join of this.config.joins) {
4712
+ const tableName2 = getTableLikeName(join.table);
4713
+ if (typeof tableName2 === "string" && !is(join.table, SQL)) {
4714
+ const fromFields = this.getTableLikeFields(join.table);
4715
+ fields[tableName2] = fromFields;
4716
+ }
4717
+ }
4718
+ }
4719
+ }
4608
4720
  this.config.returning = orderSelectedFields(fields);
4609
4721
  return this;
4610
4722
  }
@@ -4616,7 +4728,9 @@ class PgUpdateBase extends QueryPromise {
4616
4728
  return rest;
4617
4729
  }
4618
4730
  _prepare(name) {
4619
- return this.session.prepareQuery(this.dialect.sqlToQuery(this.getSQL()), this.config.returning, name, true);
4731
+ const query = this.session.prepareQuery(this.dialect.sqlToQuery(this.getSQL()), this.config.returning, name, true);
4732
+ query.joinsNotNullableMap = this.joinsNotNullableMap;
4733
+ return query;
4620
4734
  }
4621
4735
  prepare(name) {
4622
4736
  return this._prepare(name);
@@ -4629,7 +4743,7 @@ class PgUpdateBase extends QueryPromise {
4629
4743
  }
4630
4744
  }
4631
4745
 
4632
- // ../../node_modules/.pnpm/drizzle-orm@0.36.1_@libsql+client-wasm@0.14.0_@types+react@18.3.12_bun-types@1.1.34_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/pg-core/query-builders/count.js
4746
+ // ../../node_modules/.pnpm/drizzle-orm@0.36.3_@types+react@18.3.12_bun-types@1.1.35_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/pg-core/query-builders/count.js
4633
4747
  class PgCountBuilder extends SQL {
4634
4748
  constructor(params) {
4635
4749
  super(PgCountBuilder.buildEmbeddedCount(params.source, params.filters).queryChunks);
@@ -4665,7 +4779,7 @@ class PgCountBuilder extends SQL {
4665
4779
  }
4666
4780
  }
4667
4781
 
4668
- // ../../node_modules/.pnpm/drizzle-orm@0.36.1_@libsql+client-wasm@0.14.0_@types+react@18.3.12_bun-types@1.1.34_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/pg-core/query-builders/query.js
4782
+ // ../../node_modules/.pnpm/drizzle-orm@0.36.3_@types+react@18.3.12_bun-types@1.1.35_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/pg-core/query-builders/query.js
4669
4783
  class RelationalQueryBuilder {
4670
4784
  constructor(fullSchema, schema, tableNamesMap, table, tableConfig, dialect, session) {
4671
4785
  this.fullSchema = fullSchema;
@@ -4743,7 +4857,7 @@ class PgRelationalQuery extends QueryPromise {
4743
4857
  }
4744
4858
  }
4745
4859
 
4746
- // ../../node_modules/.pnpm/drizzle-orm@0.36.1_@libsql+client-wasm@0.14.0_@types+react@18.3.12_bun-types@1.1.34_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/pg-core/query-builders/raw.js
4860
+ // ../../node_modules/.pnpm/drizzle-orm@0.36.3_@types+react@18.3.12_bun-types@1.1.35_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/pg-core/query-builders/raw.js
4747
4861
  class PgRaw extends QueryPromise {
4748
4862
  constructor(execute, sql2, query, mapBatchResult) {
4749
4863
  super();
@@ -4770,7 +4884,7 @@ class PgRaw extends QueryPromise {
4770
4884
  }
4771
4885
  }
4772
4886
 
4773
- // ../../node_modules/.pnpm/drizzle-orm@0.36.1_@libsql+client-wasm@0.14.0_@types+react@18.3.12_bun-types@1.1.34_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/pg-core/db.js
4887
+ // ../../node_modules/.pnpm/drizzle-orm@0.36.3_@types+react@18.3.12_bun-types@1.1.35_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/pg-core/db.js
4774
4888
  class PgDatabase {
4775
4889
  constructor(dialect, session, schema) {
4776
4890
  this.dialect = dialect;
@@ -4894,7 +5008,7 @@ class PgDatabase {
4894
5008
  }
4895
5009
  }
4896
5010
 
4897
- // ../../node_modules/.pnpm/drizzle-orm@0.36.1_@libsql+client-wasm@0.14.0_@types+react@18.3.12_bun-types@1.1.34_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/pg-core/session.js
5011
+ // ../../node_modules/.pnpm/drizzle-orm@0.36.3_@types+react@18.3.12_bun-types@1.1.35_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/pg-core/session.js
4898
5012
  class PgPreparedQuery {
4899
5013
  constructor(query) {
4900
5014
  this.query = query;
@@ -4959,7 +5073,7 @@ class PgTransaction extends PgDatabase {
4959
5073
  }
4960
5074
  }
4961
5075
 
4962
- // ../../node_modules/.pnpm/drizzle-orm@0.36.1_@libsql+client-wasm@0.14.0_@types+react@18.3.12_bun-types@1.1.34_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/postgres-js/session.js
5076
+ // ../../node_modules/.pnpm/drizzle-orm@0.36.3_@types+react@18.3.12_bun-types@1.1.35_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/postgres-js/session.js
4963
5077
  class PostgresJsPreparedQuery extends PgPreparedQuery {
4964
5078
  constructor(client, queryString, params, logger, fields, _isResponseInArrayMode, customResultMapper) {
4965
5079
  super({ sql: queryString, params });
@@ -5067,7 +5181,7 @@ class PostgresJsTransaction extends PgTransaction {
5067
5181
  }
5068
5182
  }
5069
5183
 
5070
- // ../../node_modules/.pnpm/drizzle-orm@0.36.1_@libsql+client-wasm@0.14.0_@types+react@18.3.12_bun-types@1.1.34_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/postgres-js/driver.js
5184
+ // ../../node_modules/.pnpm/drizzle-orm@0.36.3_@types+react@18.3.12_bun-types@1.1.35_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/postgres-js/driver.js
5071
5185
  class PostgresJsDatabase extends PgDatabase {
5072
5186
  static [entityKind] = "PostgresJsDatabase";
5073
5187
  }
@@ -5126,7 +5240,7 @@ function drizzle(...params) {
5126
5240
  drizzle2.mock = mock;
5127
5241
  })(drizzle || (drizzle = {}));
5128
5242
 
5129
- // ../../node_modules/.pnpm/drizzle-orm@0.36.1_@libsql+client-wasm@0.14.0_@types+react@18.3.12_bun-types@1.1.34_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/migrator.js
5243
+ // ../../node_modules/.pnpm/drizzle-orm@0.36.3_@types+react@18.3.12_bun-types@1.1.35_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/migrator.js
5130
5244
  import crypto2 from "crypto";
5131
5245
  import fs2 from "fs";
5132
5246
  function readMigrationFiles(config) {
@@ -5158,13 +5272,13 @@ function readMigrationFiles(config) {
5158
5272
  return migrationQueries;
5159
5273
  }
5160
5274
 
5161
- // /home/runner/work/wayforge/wayforge/apps/tempest.games/node_modules/drizzle-orm/postgres-js/migrator.js
5275
+ // ../../node_modules/.pnpm/drizzle-orm@0.36.3_@types+react@18.3.12_bun-types@1.1.35_postgres@3.4.5_react@18.3.1/node_modules/drizzle-orm/postgres-js/migrator.js
5162
5276
  async function migrate(db, config) {
5163
5277
  const migrations = readMigrationFiles(config);
5164
5278
  await db.dialect.migrate(migrations, db.session, config);
5165
5279
  }
5166
5280
 
5167
- // /home/runner/work/wayforge/wayforge/apps/tempest.games/node_modules/zod/lib/index.mjs
5281
+ // ../../node_modules/.pnpm/zod@3.23.8/node_modules/zod/lib/index.mjs
5168
5282
  var util;
5169
5283
  (function(util2) {
5170
5284
  util2.assertEqual = (val) => val;
@@ -5958,13 +6072,13 @@ var uuidRegex = /^[0-9a-fA-F]{8}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]
5958
6072
  var nanoidRegex = /^[a-z0-9_-]{21}$/i;
5959
6073
  var durationRegex = /^[-+]?P(?!$)(?:(?:[-+]?\d+Y)|(?:[-+]?\d+[.,]\d+Y$))?(?:(?:[-+]?\d+M)|(?:[-+]?\d+[.,]\d+M$))?(?:(?:[-+]?\d+W)|(?:[-+]?\d+[.,]\d+W$))?(?:(?:[-+]?\d+D)|(?:[-+]?\d+[.,]\d+D$))?(?:T(?=[\d+-])(?:(?:[-+]?\d+H)|(?:[-+]?\d+[.,]\d+H$))?(?:(?:[-+]?\d+M)|(?:[-+]?\d+[.,]\d+M$))?(?:[-+]?\d+(?:[.,]\d+)?S)?)??$/;
5960
6074
  var emailRegex = /^(?!\.)(?!.*\.\.)([A-Z0-9_'+\-\.]*)[A-Z0-9_+-]@([A-Z0-9][A-Z0-9\-]*\.)+[A-Z]{2,}$/i;
5961
- var _emojiRegex = `^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+\$`;
6075
+ var _emojiRegex = `^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$`;
5962
6076
  var emojiRegex;
5963
6077
  var ipv4Regex = /^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])$/;
5964
6078
  var ipv6Regex = /^(([a-f0-9]{1,4}:){7}|::([a-f0-9]{1,4}:){0,6}|([a-f0-9]{1,4}:){1}:([a-f0-9]{1,4}:){0,5}|([a-f0-9]{1,4}:){2}:([a-f0-9]{1,4}:){0,4}|([a-f0-9]{1,4}:){3}:([a-f0-9]{1,4}:){0,3}|([a-f0-9]{1,4}:){4}:([a-f0-9]{1,4}:){0,2}|([a-f0-9]{1,4}:){5}:([a-f0-9]{1,4}:){0,1})([a-f0-9]{1,4}|(((25[0-5])|(2[0-4][0-9])|(1[0-9]{2})|([0-9]{1,2}))\.){3}((25[0-5])|(2[0-4][0-9])|(1[0-9]{2})|([0-9]{1,2})))$/;
5965
6079
  var base64Regex = /^([0-9a-zA-Z+/]{4})*(([0-9a-zA-Z+/]{2}==)|([0-9a-zA-Z+/]{3}=))?$/;
5966
6080
  var dateRegexSource = `((\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-((0[13578]|1[02])-(0[1-9]|[12]\\d|3[01])|(0[469]|11)-(0[1-9]|[12]\\d|30)|(02)-(0[1-9]|1\\d|2[0-8])))`;
5967
- var dateRegex = new RegExp(`^${dateRegexSource}\$`);
6081
+ var dateRegex = new RegExp(`^${dateRegexSource}$`);
5968
6082
  function timeRegexSource(args) {
5969
6083
  let regex = `([01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d`;
5970
6084
  if (args.precision) {
@@ -5975,7 +6089,7 @@ function timeRegexSource(args) {
5975
6089
  return regex;
5976
6090
  }
5977
6091
  function timeRegex(args) {
5978
- return new RegExp(`^${timeRegexSource(args)}\$`);
6092
+ return new RegExp(`^${timeRegexSource(args)}$`);
5979
6093
  }
5980
6094
  function datetimeRegex(args) {
5981
6095
  let regex = `${dateRegexSource}T${timeRegexSource(args)}`;
@@ -5984,7 +6098,7 @@ function datetimeRegex(args) {
5984
6098
  if (args.offset)
5985
6099
  opts.push(`([+-]\\d{2}:?\\d{2})`);
5986
6100
  regex = `${regex}(${opts.join("|")})`;
5987
- return new RegExp(`^${regex}\$`);
6101
+ return new RegExp(`^${regex}$`);
5988
6102
  }
5989
6103
  function isValidIP(ip, version2) {
5990
6104
  if ((version2 === "v4" || !version2) && ipv4Regex.test(ip)) {
@@ -9026,7 +9140,7 @@ var z = /* @__PURE__ */ Object.freeze({
9026
9140
  ZodError
9027
9141
  });
9028
9142
 
9029
- // /home/runner/work/wayforge/wayforge/apps/tempest.games/node_modules/@t3-oss/env-core/dist/index.js
9143
+ // ../../node_modules/.pnpm/@t3-oss+env-core@0.11.1_typescript@5.6.3_zod@3.23.8/node_modules/@t3-oss/env-core/dist/index.js
9030
9144
  function createEnv(opts) {
9031
9145
  const runtimeEnv = opts.runtimeEnvStrict ?? opts.runtimeEnv ?? process.env;
9032
9146
  const emptyStringAsUndefined = opts.emptyStringAsUndefined ?? false;