@typeberry/jam 0.1.2-3178190 → 0.1.2-753d258
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/README.md +0 -1
- package/block-generator/index.js +15 -34
- package/block-generator/index.js.map +1 -1
- package/importer/index.js +19 -40
- package/importer/index.js.map +1 -1
- package/index.js +19 -40
- package/index.js.map +1 -1
- package/jam-network/index.js +11 -18
- package/jam-network/index.js.map +1 -1
- package/package.json +1 -1
package/jam-network/index.js
CHANGED
|
@@ -25234,7 +25234,6 @@ var compatibility_GpVersion;
|
|
|
25234
25234
|
GpVersion["V0_6_7"] = "0.6.7";
|
|
25235
25235
|
GpVersion["V0_7_0"] = "0.7.0";
|
|
25236
25236
|
GpVersion["V0_7_1"] = "0.7.1-preview";
|
|
25237
|
-
GpVersion["V0_7_2"] = "0.7.2-preview";
|
|
25238
25237
|
})(compatibility_GpVersion || (compatibility_GpVersion = {}));
|
|
25239
25238
|
var TestSuite;
|
|
25240
25239
|
(function (TestSuite) {
|
|
@@ -25242,7 +25241,7 @@ var TestSuite;
|
|
|
25242
25241
|
TestSuite["JAMDUNA"] = "jamduna";
|
|
25243
25242
|
})(TestSuite || (TestSuite = {}));
|
|
25244
25243
|
const DEFAULT_SUITE = TestSuite.W3F_DAVXY;
|
|
25245
|
-
const ALL_VERSIONS_IN_ORDER = [compatibility_GpVersion.V0_6_7, compatibility_GpVersion.V0_7_0, compatibility_GpVersion.V0_7_1
|
|
25244
|
+
const ALL_VERSIONS_IN_ORDER = [compatibility_GpVersion.V0_6_7, compatibility_GpVersion.V0_7_0, compatibility_GpVersion.V0_7_1];
|
|
25246
25245
|
const env = typeof process === "undefined" ? {} : process.env;
|
|
25247
25246
|
const DEFAULT_VERSION = compatibility_GpVersion.V0_7_0;
|
|
25248
25247
|
let CURRENT_VERSION = parseCurrentVersion(env.GP_VERSION) ?? DEFAULT_VERSION;
|
|
@@ -25251,26 +25250,20 @@ function parseCurrentVersion(env) {
|
|
|
25251
25250
|
if (env === undefined) {
|
|
25252
25251
|
return undefined;
|
|
25253
25252
|
}
|
|
25254
|
-
|
|
25255
|
-
|
|
25256
|
-
|
|
25257
|
-
case compatibility_GpVersion.V0_7_1:
|
|
25258
|
-
case compatibility_GpVersion.V0_7_2:
|
|
25259
|
-
return env;
|
|
25260
|
-
default:
|
|
25261
|
-
throw new Error(`Configured environment variable GP_VERSION is unknown: '${env}'. Use one of: ${ALL_VERSIONS_IN_ORDER}`);
|
|
25253
|
+
const version = env;
|
|
25254
|
+
if (!Object.values(compatibility_GpVersion).includes(version)) {
|
|
25255
|
+
throw new Error(`Configured environment variable GP_VERSION is unknown: '${env}'. Use one of: ${ALL_VERSIONS_IN_ORDER}`);
|
|
25262
25256
|
}
|
|
25257
|
+
return version;
|
|
25263
25258
|
}
|
|
25264
25259
|
function parseCurrentSuite(env) {
|
|
25265
25260
|
if (env === undefined)
|
|
25266
25261
|
return undefined;
|
|
25267
|
-
|
|
25268
|
-
|
|
25269
|
-
|
|
25270
|
-
return env;
|
|
25271
|
-
default:
|
|
25272
|
-
throw new Error(`Configured environment variable TEST_SUITE is unknown: '${env}'. Use one of: ${Object.values(TestSuite)}`);
|
|
25262
|
+
const val = env;
|
|
25263
|
+
if (!Object.values(TestSuite).includes(val)) {
|
|
25264
|
+
throw new Error(`Configured environment variable TEST_SUITE is unknown: '${env}'. Use one of: ${Object.values(TestSuite)}`);
|
|
25273
25265
|
}
|
|
25266
|
+
return val;
|
|
25274
25267
|
}
|
|
25275
25268
|
class compatibility_Compatibility {
|
|
25276
25269
|
static override(version) {
|
|
@@ -32177,8 +32170,8 @@ function print(level, levelAndName, strings, data) {
|
|
|
32177
32170
|
return;
|
|
32178
32171
|
}
|
|
32179
32172
|
const lvlText = Level[level].padEnd(5);
|
|
32180
|
-
const val = strings.map((v, idx) => `${v}${
|
|
32181
|
-
const msg = `${lvlText} [${levelAndName[1]}] ${val
|
|
32173
|
+
const val = strings.map((v, idx) => `${v}${data[idx]}`);
|
|
32174
|
+
const msg = `${lvlText} [${levelAndName[1]}] ${val}`;
|
|
32182
32175
|
if (level === Level.WARN) {
|
|
32183
32176
|
console.warn(msg);
|
|
32184
32177
|
}
|