@dataform/core 2.6.4 → 2.6.6
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.js +5 -2
- package/package.json +1 -1
package/bundle.js
CHANGED
|
@@ -19321,7 +19321,7 @@ class RefReplacingContext {
|
|
|
19321
19321
|
}
|
|
19322
19322
|
}
|
|
19323
19323
|
|
|
19324
|
-
const version = "2.6.
|
|
19324
|
+
const version = "2.6.6";
|
|
19325
19325
|
|
|
19326
19326
|
const SQL_DATA_WAREHOUSE_DIST_HASH_REGEXP = new RegExp("HASH\\s*\\(\\s*\\w*\\s*\\)\\s*");
|
|
19327
19327
|
const DEFAULT_CONFIG = {
|
|
@@ -19911,17 +19911,20 @@ function main(encodedCoreExecutionRequest) {
|
|
|
19911
19911
|
const session = require("@dataform/core").session;
|
|
19912
19912
|
session.init(compileRequest.compileConfig.projectDir, projectConfig, originalProjectConfig);
|
|
19913
19913
|
globalAny.dataform = session;
|
|
19914
|
+
const topLevelIncludes = {};
|
|
19914
19915
|
compileRequest.compileConfig.filePaths
|
|
19915
19916
|
.filter(path => path.startsWith(`includes${pathSeperator}`))
|
|
19917
|
+
.filter(path => path.split(pathSeperator).length === 2)
|
|
19916
19918
|
.filter(path => path.endsWith(".js"))
|
|
19917
19919
|
.forEach(includePath => {
|
|
19918
19920
|
try {
|
|
19919
|
-
|
|
19921
|
+
topLevelIncludes[baseFilename(includePath)] = require(includePath);
|
|
19920
19922
|
}
|
|
19921
19923
|
catch (e) {
|
|
19922
19924
|
session.compileError(e, includePath);
|
|
19923
19925
|
}
|
|
19924
19926
|
});
|
|
19927
|
+
Object.assign(globalAny, topLevelIncludes);
|
|
19925
19928
|
globalAny.publish = session.publish.bind(session);
|
|
19926
19929
|
globalAny.operate = session.operate.bind(session);
|
|
19927
19930
|
globalAny.assert = session.assert.bind(session);
|