@dataform/core 2.4.2 → 2.6.0

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/bundle.d.ts CHANGED
@@ -6221,6 +6221,7 @@ declare enum WarehouseType {
6221
6221
  SNOWFLAKE = "snowflake",
6222
6222
  SQLDATAWAREHOUSE = "sqldatawarehouse"
6223
6223
  }
6224
+ declare function isWarehouseType(input: any): input is WarehouseType;
6224
6225
  declare function supportsCancel(warehouseType: WarehouseType): boolean;
6225
6226
  declare const requiredWarehouseProps: {
6226
6227
  bigquery: ("projectId" | "credentials" | "location")[];
@@ -6243,6 +6244,7 @@ type index_d_IAdapter = IAdapter;
6243
6244
  declare const index_d_AdapterConstructor: typeof AdapterConstructor;
6244
6245
  type index_d_WarehouseType = WarehouseType;
6245
6246
  declare const index_d_WarehouseType: typeof WarehouseType;
6247
+ declare const index_d_isWarehouseType: typeof isWarehouseType;
6246
6248
  declare const index_d_supportsCancel: typeof supportsCancel;
6247
6249
  declare const index_d_requiredWarehouseProps: typeof requiredWarehouseProps;
6248
6250
  declare const index_d_register: typeof register;
@@ -6255,6 +6257,7 @@ declare namespace index_d {
6255
6257
  index_d_IAdapter as IAdapter,
6256
6258
  index_d_AdapterConstructor as AdapterConstructor,
6257
6259
  index_d_WarehouseType as WarehouseType,
6260
+ index_d_isWarehouseType as isWarehouseType,
6258
6261
  index_d_supportsCancel as supportsCancel,
6259
6262
  index_d_requiredWarehouseProps as requiredWarehouseProps,
6260
6263
  index_d_register as register,
package/bundle.js CHANGED
@@ -17160,6 +17160,9 @@ var WarehouseType;
17160
17160
  WarehouseType["SNOWFLAKE"] = "snowflake";
17161
17161
  WarehouseType["SQLDATAWAREHOUSE"] = "sqldatawarehouse";
17162
17162
  })(WarehouseType || (WarehouseType = {}));
17163
+ function isWarehouseType(input) {
17164
+ return Object.values(WarehouseType).includes(input);
17165
+ }
17163
17166
  const CANCELLATION_SUPPORTED = [WarehouseType.BIGQUERY, WarehouseType.SQLDATAWAREHOUSE];
17164
17167
  function supportsCancel(warehouseType) {
17165
17168
  return CANCELLATION_SUPPORTED.some(w => {
@@ -17273,6 +17276,7 @@ function collectEvaluationQueries(queryOrAction, concatenate, queryModifier = (q
17273
17276
  var index = /*#__PURE__*/Object.freeze({
17274
17277
  __proto__: null,
17275
17278
  get WarehouseType () { return WarehouseType; },
17279
+ isWarehouseType: isWarehouseType,
17276
17280
  supportsCancel: supportsCancel,
17277
17281
  requiredWarehouseProps: requiredWarehouseProps,
17278
17282
  register: register,
@@ -18544,7 +18548,7 @@ function compileStandaloneSqlxQuery(code) {
18544
18548
  }
18545
18549
  function compileSqlx(rootNode, path) {
18546
18550
  const { config, js, sql, incremental, preOperations, postOperations, inputs } = extractSqlxParts(rootNode);
18547
- const contextFunctions = ["self", "ref", "resolve", "name", "when", "incremental"]
18551
+ const contextFunctions = ["self", "ref", "resolve", "name", "when", "incremental", "schema", "database"]
18548
18552
  .map(name => `const ${name} = ctx.${name} ? ctx.${name}.bind(ctx) : undefined;`)
18549
18553
  .join("\n");
18550
18554
  return `dataform.sqlxAction({
@@ -19152,7 +19156,7 @@ class RefReplacingContext {
19152
19156
  }
19153
19157
  }
19154
19158
 
19155
- const version = "2.4.2";
19159
+ const version = "2.6.0";
19156
19160
 
19157
19161
  const SQL_DATA_WAREHOUSE_DIST_HASH_REGEXP = new RegExp("HASH\\s*\\(\\s*\\w*\\s*\\)\\s*");
19158
19162
  const DEFAULT_CONFIG = {
package/package.json CHANGED
@@ -10,7 +10,6 @@
10
10
  "**/object-path": "^0.11.5",
11
11
  "**/http-proxy": "^1.18.1",
12
12
  "**/serialize-javascript": "^3.1.0",
13
- "webpack/**/acorn": "^5.7.4",
14
13
  "**/lodash": "^4.17.21",
15
14
  "**/ssri": "^7.1.1",
16
15
  "**/postcss": "^8.2.10",
@@ -50,7 +49,7 @@
50
49
  "publishConfig": {
51
50
  "access": "public"
52
51
  },
53
- "version": "2.4.2",
52
+ "version": "2.6.0",
54
53
  "name": "@dataform/core",
55
54
  "description": "Dataform core API.",
56
55
  "main": "bundle.js",