@lucid-evolution/provider 0.1.74 → 0.1.76
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/index.cjs +16 -15
- package/dist/index.js +24 -16
- package/package.json +3 -3
package/dist/index.cjs
CHANGED
|
@@ -52,7 +52,7 @@ var import_utils = require("@lucid-evolution/utils");
|
|
|
52
52
|
// package.json
|
|
53
53
|
var package_default = {
|
|
54
54
|
name: "@lucid-evolution/provider",
|
|
55
|
-
version: "0.1.
|
|
55
|
+
version: "0.1.76",
|
|
56
56
|
description: "",
|
|
57
57
|
main: "./dist/index.js",
|
|
58
58
|
types: "./dist/index.d.ts",
|
|
@@ -369,17 +369,17 @@ var Blockfrost = class {
|
|
|
369
369
|
case "plutusV1":
|
|
370
370
|
return {
|
|
371
371
|
type: "PlutusV1",
|
|
372
|
-
script
|
|
372
|
+
script: (0, import_utils.applyDoubleCborEncoding)(script)
|
|
373
373
|
};
|
|
374
374
|
case "plutusV2":
|
|
375
375
|
return {
|
|
376
376
|
type: "PlutusV2",
|
|
377
|
-
script
|
|
377
|
+
script: (0, import_utils.applyDoubleCborEncoding)(script)
|
|
378
378
|
};
|
|
379
379
|
case "plutusV3":
|
|
380
380
|
return {
|
|
381
381
|
type: "PlutusV3",
|
|
382
|
-
script
|
|
382
|
+
script: (0, import_utils.applyDoubleCborEncoding)(script)
|
|
383
383
|
};
|
|
384
384
|
}
|
|
385
385
|
})() : void 0
|
|
@@ -896,17 +896,17 @@ var getScriptEffect = (kupoUrl, script_hash) => import_effect2.Effect.gen(functi
|
|
|
896
896
|
case "plutus:v1":
|
|
897
897
|
return {
|
|
898
898
|
type: "PlutusV1",
|
|
899
|
-
script
|
|
899
|
+
script: (0, import_utils3.applyDoubleCborEncoding)(script)
|
|
900
900
|
};
|
|
901
901
|
case "plutus:v2":
|
|
902
902
|
return {
|
|
903
903
|
type: "PlutusV2",
|
|
904
|
-
script
|
|
904
|
+
script: (0, import_utils3.applyDoubleCborEncoding)(script)
|
|
905
905
|
};
|
|
906
906
|
case "plutus:v3":
|
|
907
907
|
return {
|
|
908
908
|
type: "PlutusV3",
|
|
909
|
-
script
|
|
909
|
+
script: (0, import_utils3.applyDoubleCborEncoding)(script)
|
|
910
910
|
};
|
|
911
911
|
}
|
|
912
912
|
})
|
|
@@ -2066,17 +2066,17 @@ var toScriptRef = (reference_script) => {
|
|
|
2066
2066
|
case "plutusv1":
|
|
2067
2067
|
return {
|
|
2068
2068
|
type: "PlutusV1",
|
|
2069
|
-
script: reference_script.bytes
|
|
2069
|
+
script: (0, import_utils6.applyDoubleCborEncoding)(reference_script.bytes)
|
|
2070
2070
|
};
|
|
2071
2071
|
case "plutusv2":
|
|
2072
2072
|
return {
|
|
2073
2073
|
type: "PlutusV2",
|
|
2074
|
-
script: reference_script.bytes
|
|
2074
|
+
script: (0, import_utils6.applyDoubleCborEncoding)(reference_script.bytes)
|
|
2075
2075
|
};
|
|
2076
2076
|
case "plutusv3":
|
|
2077
2077
|
return {
|
|
2078
2078
|
type: "PlutusV3",
|
|
2079
|
-
script: reference_script.bytes
|
|
2079
|
+
script: (0, import_utils6.applyDoubleCborEncoding)(reference_script.bytes)
|
|
2080
2080
|
};
|
|
2081
2081
|
default:
|
|
2082
2082
|
return void 0;
|
|
@@ -2088,12 +2088,13 @@ var lucid2 = package_default.version;
|
|
|
2088
2088
|
// src/koios.ts
|
|
2089
2089
|
var S5 = __toESM(require("@effect/schema/Schema"), 1);
|
|
2090
2090
|
var import_core_utils4 = require("@lucid-evolution/core-utils");
|
|
2091
|
-
var
|
|
2091
|
+
var import_utils8 = require("@lucid-evolution/utils");
|
|
2092
2092
|
|
|
2093
2093
|
// src/internal/koios.ts
|
|
2094
2094
|
var import_platform2 = require("@effect/platform");
|
|
2095
2095
|
var S4 = __toESM(require("@effect/schema/Schema"), 1);
|
|
2096
2096
|
var import_effect3 = require("effect");
|
|
2097
|
+
var import_utils7 = require("@lucid-evolution/utils");
|
|
2097
2098
|
var ProtocolParametersSchema2 = S4.Struct({
|
|
2098
2099
|
pvt_motion_no_confidence: S4.Number,
|
|
2099
2100
|
pvt_committee_normal: S4.Number,
|
|
@@ -2355,17 +2356,17 @@ var toScriptRef2 = (reference_script) => {
|
|
|
2355
2356
|
case "plutusV1":
|
|
2356
2357
|
return {
|
|
2357
2358
|
type: "PlutusV1",
|
|
2358
|
-
script: reference_script.bytes
|
|
2359
|
+
script: (0, import_utils7.applyDoubleCborEncoding)(reference_script.bytes)
|
|
2359
2360
|
};
|
|
2360
2361
|
case "plutusV2":
|
|
2361
2362
|
return {
|
|
2362
2363
|
type: "PlutusV2",
|
|
2363
|
-
script: reference_script.bytes
|
|
2364
|
+
script: (0, import_utils7.applyDoubleCborEncoding)(reference_script.bytes)
|
|
2364
2365
|
};
|
|
2365
2366
|
case "plutusV3":
|
|
2366
2367
|
return {
|
|
2367
2368
|
type: "PlutusV3",
|
|
2368
|
-
script: reference_script.bytes
|
|
2369
|
+
script: (0, import_utils7.applyDoubleCborEncoding)(reference_script.bytes)
|
|
2369
2370
|
};
|
|
2370
2371
|
default:
|
|
2371
2372
|
return void 0;
|
|
@@ -2475,7 +2476,7 @@ var Koios = class {
|
|
|
2475
2476
|
return result;
|
|
2476
2477
|
}
|
|
2477
2478
|
async getUtxoByUnit(unit) {
|
|
2478
|
-
let { policyId, assetName } = (0,
|
|
2479
|
+
let { policyId, assetName } = (0, import_utils8.fromUnit)(unit);
|
|
2479
2480
|
const url = `${this.baseUrl}/asset_addresses?_asset_policy=${policyId}&_asset_name=${assetName}`;
|
|
2480
2481
|
const result = await (0, import_effect4.pipe)(
|
|
2481
2482
|
getWithSchemaValidation(url, S5.Array(AssetAddressSchema)),
|
package/dist/index.js
CHANGED
|
@@ -3,12 +3,15 @@ import * as CML from "@anastasia-labs/cardano-multiplatform-lib-nodejs";
|
|
|
3
3
|
|
|
4
4
|
// src/blockfrost.ts
|
|
5
5
|
import { fromHex, sleep } from "@lucid-evolution/core-utils";
|
|
6
|
-
import {
|
|
6
|
+
import {
|
|
7
|
+
applyDoubleCborEncoding,
|
|
8
|
+
scriptFromNative
|
|
9
|
+
} from "@lucid-evolution/utils";
|
|
7
10
|
|
|
8
11
|
// package.json
|
|
9
12
|
var package_default = {
|
|
10
13
|
name: "@lucid-evolution/provider",
|
|
11
|
-
version: "0.1.
|
|
14
|
+
version: "0.1.76",
|
|
12
15
|
description: "",
|
|
13
16
|
main: "./dist/index.js",
|
|
14
17
|
types: "./dist/index.d.ts",
|
|
@@ -325,17 +328,17 @@ var Blockfrost = class {
|
|
|
325
328
|
case "plutusV1":
|
|
326
329
|
return {
|
|
327
330
|
type: "PlutusV1",
|
|
328
|
-
script
|
|
331
|
+
script: applyDoubleCborEncoding(script)
|
|
329
332
|
};
|
|
330
333
|
case "plutusV2":
|
|
331
334
|
return {
|
|
332
335
|
type: "PlutusV2",
|
|
333
|
-
script
|
|
336
|
+
script: applyDoubleCborEncoding(script)
|
|
334
337
|
};
|
|
335
338
|
case "plutusV3":
|
|
336
339
|
return {
|
|
337
340
|
type: "PlutusV3",
|
|
338
|
-
script
|
|
341
|
+
script: applyDoubleCborEncoding(script)
|
|
339
342
|
};
|
|
340
343
|
}
|
|
341
344
|
})() : void 0
|
|
@@ -394,7 +397,7 @@ var handleRateLimit = async (count) => {
|
|
|
394
397
|
var lucid = package_default.version;
|
|
395
398
|
|
|
396
399
|
// src/kupmios.ts
|
|
397
|
-
import { fromUnit as fromUnit2 } from "@lucid-evolution/utils";
|
|
400
|
+
import { applyDoubleCborEncoding as applyDoubleCborEncoding2, fromUnit as fromUnit2 } from "@lucid-evolution/utils";
|
|
398
401
|
import * as S3 from "@effect/schema/Schema";
|
|
399
402
|
import { Effect, pipe as pipe2, Array as _Array, Schedule, Data } from "effect";
|
|
400
403
|
import {
|
|
@@ -856,17 +859,17 @@ var getScriptEffect = (kupoUrl, script_hash) => Effect.gen(function* () {
|
|
|
856
859
|
case "plutus:v1":
|
|
857
860
|
return {
|
|
858
861
|
type: "PlutusV1",
|
|
859
|
-
script
|
|
862
|
+
script: applyDoubleCborEncoding2(script)
|
|
860
863
|
};
|
|
861
864
|
case "plutus:v2":
|
|
862
865
|
return {
|
|
863
866
|
type: "PlutusV2",
|
|
864
|
-
script
|
|
867
|
+
script: applyDoubleCborEncoding2(script)
|
|
865
868
|
};
|
|
866
869
|
case "plutus:v3":
|
|
867
870
|
return {
|
|
868
871
|
type: "PlutusV3",
|
|
869
|
-
script
|
|
872
|
+
script: applyDoubleCborEncoding2(script)
|
|
870
873
|
};
|
|
871
874
|
}
|
|
872
875
|
})
|
|
@@ -1731,7 +1734,11 @@ ${"\u2581".repeat(60)}
|
|
|
1731
1734
|
};
|
|
1732
1735
|
|
|
1733
1736
|
// src/maestro.ts
|
|
1734
|
-
import {
|
|
1737
|
+
import {
|
|
1738
|
+
applyDoubleCborEncoding as applyDoubleCborEncoding3,
|
|
1739
|
+
scriptFromNative as scriptFromNative2,
|
|
1740
|
+
utxoToCore
|
|
1741
|
+
} from "@lucid-evolution/utils";
|
|
1735
1742
|
import { fromHex as fromHex3 } from "@lucid-evolution/core-utils";
|
|
1736
1743
|
var Maestro = class {
|
|
1737
1744
|
url;
|
|
@@ -2030,17 +2037,17 @@ var toScriptRef = (reference_script) => {
|
|
|
2030
2037
|
case "plutusv1":
|
|
2031
2038
|
return {
|
|
2032
2039
|
type: "PlutusV1",
|
|
2033
|
-
script: reference_script.bytes
|
|
2040
|
+
script: applyDoubleCborEncoding3(reference_script.bytes)
|
|
2034
2041
|
};
|
|
2035
2042
|
case "plutusv2":
|
|
2036
2043
|
return {
|
|
2037
2044
|
type: "PlutusV2",
|
|
2038
|
-
script: reference_script.bytes
|
|
2045
|
+
script: applyDoubleCborEncoding3(reference_script.bytes)
|
|
2039
2046
|
};
|
|
2040
2047
|
case "plutusv3":
|
|
2041
2048
|
return {
|
|
2042
2049
|
type: "PlutusV3",
|
|
2043
|
-
script: reference_script.bytes
|
|
2050
|
+
script: applyDoubleCborEncoding3(reference_script.bytes)
|
|
2044
2051
|
};
|
|
2045
2052
|
default:
|
|
2046
2053
|
return void 0;
|
|
@@ -2062,6 +2069,7 @@ import {
|
|
|
2062
2069
|
} from "@effect/platform";
|
|
2063
2070
|
import * as S4 from "@effect/schema/Schema";
|
|
2064
2071
|
import { Effect as Effect2, pipe as pipe3 } from "effect";
|
|
2072
|
+
import { applyDoubleCborEncoding as applyDoubleCborEncoding4 } from "@lucid-evolution/utils";
|
|
2065
2073
|
var ProtocolParametersSchema2 = S4.Struct({
|
|
2066
2074
|
pvt_motion_no_confidence: S4.Number,
|
|
2067
2075
|
pvt_committee_normal: S4.Number,
|
|
@@ -2323,17 +2331,17 @@ var toScriptRef2 = (reference_script) => {
|
|
|
2323
2331
|
case "plutusV1":
|
|
2324
2332
|
return {
|
|
2325
2333
|
type: "PlutusV1",
|
|
2326
|
-
script: reference_script.bytes
|
|
2334
|
+
script: applyDoubleCborEncoding4(reference_script.bytes)
|
|
2327
2335
|
};
|
|
2328
2336
|
case "plutusV2":
|
|
2329
2337
|
return {
|
|
2330
2338
|
type: "PlutusV2",
|
|
2331
|
-
script: reference_script.bytes
|
|
2339
|
+
script: applyDoubleCborEncoding4(reference_script.bytes)
|
|
2332
2340
|
};
|
|
2333
2341
|
case "plutusV3":
|
|
2334
2342
|
return {
|
|
2335
2343
|
type: "PlutusV3",
|
|
2336
|
-
script: reference_script.bytes
|
|
2344
|
+
script: applyDoubleCborEncoding4(reference_script.bytes)
|
|
2337
2345
|
};
|
|
2338
2346
|
default:
|
|
2339
2347
|
return void 0;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@lucid-evolution/provider",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.76",
|
|
4
4
|
"description": "",
|
|
5
5
|
"main": "./dist/index.js",
|
|
6
6
|
"types": "./dist/index.d.ts",
|
|
@@ -32,8 +32,8 @@
|
|
|
32
32
|
"effect": "^3.10.4",
|
|
33
33
|
"@lucid-evolution/core-types": "0.1.21",
|
|
34
34
|
"@lucid-evolution/core-utils": "0.1.16",
|
|
35
|
-
"@lucid-evolution/utils": "0.1.
|
|
36
|
-
"@lucid-evolution/wallet": "0.1.
|
|
35
|
+
"@lucid-evolution/utils": "0.1.58",
|
|
36
|
+
"@lucid-evolution/wallet": "0.1.64"
|
|
37
37
|
},
|
|
38
38
|
"devDependencies": {
|
|
39
39
|
"@types/node": "^20.12.8",
|