@514labs/moose-lib 0.6.250 → 0.6.251
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.
- package/dist/browserCompatible.js +6 -2
- package/dist/browserCompatible.js.map +1 -1
- package/dist/browserCompatible.mjs +6 -2
- package/dist/browserCompatible.mjs.map +1 -1
- package/dist/dmv2/index.js +6 -2
- package/dist/dmv2/index.js.map +1 -1
- package/dist/dmv2/index.mjs +6 -2
- package/dist/dmv2/index.mjs.map +1 -1
- package/dist/index.js +3 -2
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +3 -2
- package/dist/index.mjs.map +1 -1
- package/dist/moose-runner.js.map +1 -1
- package/dist/moose-runner.mjs.map +1 -1
- package/package.json +1 -1
package/dist/dmv2/index.js
CHANGED
|
@@ -565,6 +565,9 @@ function createMaterializedView(options) {
|
|
|
565
565
|
AS ${options.select}`.trim();
|
|
566
566
|
}
|
|
567
567
|
|
|
568
|
+
// src/dmv2/internal.ts
|
|
569
|
+
var import_process = __toESM(require("process"));
|
|
570
|
+
|
|
568
571
|
// src/index.ts
|
|
569
572
|
init_commons();
|
|
570
573
|
|
|
@@ -604,6 +607,7 @@ var DEFAULT_CSV_CONFIG = {
|
|
|
604
607
|
|
|
605
608
|
// src/dmv2/internal.ts
|
|
606
609
|
init_commons();
|
|
610
|
+
var isClientOnlyMode = () => import_process.default.env.MOOSE_CLIENT_ONLY === "true";
|
|
607
611
|
var moose_internal = {
|
|
608
612
|
tables: /* @__PURE__ */ new Map(),
|
|
609
613
|
streams: /* @__PURE__ */ new Map(),
|
|
@@ -772,7 +776,7 @@ var OlapTable = class extends TypedBase {
|
|
|
772
776
|
this.name = name;
|
|
773
777
|
const tables = getMooseInternal().tables;
|
|
774
778
|
const registryKey = this.config.version ? `${name}_${this.config.version}` : name;
|
|
775
|
-
if (tables.has(registryKey)) {
|
|
779
|
+
if (!isClientOnlyMode() && tables.has(registryKey)) {
|
|
776
780
|
throw new Error(
|
|
777
781
|
`OlapTable with name ${name} and version ${config?.version ?? "unversioned"} already exists`
|
|
778
782
|
);
|
|
@@ -2254,7 +2258,7 @@ var SqlResource = class {
|
|
|
2254
2258
|
*/
|
|
2255
2259
|
constructor(name, setup, teardown, options) {
|
|
2256
2260
|
const sqlResources = getMooseInternal().sqlResources;
|
|
2257
|
-
if (sqlResources.has(name)) {
|
|
2261
|
+
if (!isClientOnlyMode() && sqlResources.has(name)) {
|
|
2258
2262
|
throw new Error(`SqlResource with name ${name} already exists`);
|
|
2259
2263
|
}
|
|
2260
2264
|
sqlResources.set(name, this);
|