starknet 10.7.6 → 10.8.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/CHANGELOG.md +10 -0
- package/dist/index.d.ts +111 -103
- package/dist/index.global.js +34 -31
- package/dist/index.global.js.map +1 -1
- package/dist/index.js +34 -19
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +33 -19
- package/dist/index.mjs.map +1 -1
- package/package.json +4 -4
package/dist/index.mjs
CHANGED
|
@@ -70,7 +70,7 @@ var api_exports = {};
|
|
|
70
70
|
__export(api_exports, {
|
|
71
71
|
JRPC: () => jsonrpc_exports,
|
|
72
72
|
PAYMASTER_API: () => PAYMASTER_API,
|
|
73
|
-
|
|
73
|
+
RPCSPEC0104: () => RPCSPEC0104,
|
|
74
74
|
RPCSPEC09: () => RPCSPEC09
|
|
75
75
|
});
|
|
76
76
|
|
|
@@ -79,13 +79,13 @@ var jsonrpc_exports = {};
|
|
|
79
79
|
|
|
80
80
|
// src/types/api/index.ts
|
|
81
81
|
import * as RPCSPEC09 from "@starknet-io/starknet-types-09";
|
|
82
|
-
import * as
|
|
83
|
-
import { PAYMASTER_API } from "@starknet-io/starknet-types-
|
|
82
|
+
import * as RPCSPEC0104 from "@starknet-io/starknet-types-0104";
|
|
83
|
+
import { PAYMASTER_API } from "@starknet-io/starknet-types-0104";
|
|
84
84
|
|
|
85
85
|
// src/types/api/rpc.ts
|
|
86
86
|
var rpc_exports = {};
|
|
87
|
-
__reExport(rpc_exports,
|
|
88
|
-
import * as
|
|
87
|
+
__reExport(rpc_exports, starknet_types_0104_star);
|
|
88
|
+
import * as starknet_types_0104_star from "@starknet-io/starknet-types-0104";
|
|
89
89
|
|
|
90
90
|
// src/types/api/index.ts
|
|
91
91
|
__reExport(api_exports, rpc_exports);
|
|
@@ -94,19 +94,19 @@ __reExport(api_exports, rpc_exports);
|
|
|
94
94
|
var { ETransactionVersion } = RPCSPEC09;
|
|
95
95
|
var { ETransactionVersion2 } = RPCSPEC09;
|
|
96
96
|
var { ETransactionVersion3 } = RPCSPEC09;
|
|
97
|
-
var { EDataAvailabilityMode } =
|
|
98
|
-
var { EDAMode } =
|
|
97
|
+
var { EDataAvailabilityMode } = RPCSPEC0104;
|
|
98
|
+
var { EDAMode } = RPCSPEC0104;
|
|
99
99
|
function isRPC08Plus_ResourceBounds(entry) {
|
|
100
100
|
return "l1_data_gas" in entry;
|
|
101
101
|
}
|
|
102
102
|
function isRPC08Plus_ResourceBoundsBN(entry) {
|
|
103
103
|
return "l1_data_gas" in entry;
|
|
104
104
|
}
|
|
105
|
-
var { ETxnResponseFlag } =
|
|
106
|
-
var { ETraceFlag } =
|
|
107
|
-
var { ESubscriptionTag } =
|
|
108
|
-
var { ETransactionStatus } =
|
|
109
|
-
var { ETransactionExecutionStatus } =
|
|
105
|
+
var { ETxnResponseFlag } = RPCSPEC0104;
|
|
106
|
+
var { ETraceFlag } = RPCSPEC0104;
|
|
107
|
+
var { ESubscriptionTag } = RPCSPEC0104;
|
|
108
|
+
var { ETransactionStatus } = RPCSPEC0104;
|
|
109
|
+
var { ETransactionExecutionStatus } = RPCSPEC0104;
|
|
110
110
|
var { ETransactionType: TransactionType } = RPCSPEC09;
|
|
111
111
|
var { EBlockStatus: BlockStatus } = RPCSPEC09;
|
|
112
112
|
var { ETransactionFinalityStatus: TransactionFinalityStatus } = RPCSPEC09;
|
|
@@ -322,10 +322,12 @@ var _SupportedRpcVersion = {
|
|
|
322
322
|
"0.10.0": "0.10.0",
|
|
323
323
|
"0.10.2": "0.10.2",
|
|
324
324
|
"0.10.3": "0.10.3",
|
|
325
|
+
"0.10.4": "0.10.4",
|
|
325
326
|
v0_9_0: "0.9.0",
|
|
326
327
|
v0_10_0: "0.10.0",
|
|
327
328
|
v0_10_2: "0.10.2",
|
|
328
|
-
v0_10_3: "0.10.3"
|
|
329
|
+
v0_10_3: "0.10.3",
|
|
330
|
+
v0_10_4: "0.10.4"
|
|
329
331
|
};
|
|
330
332
|
var DEFAULT_GLOBAL_CONFIG = {
|
|
331
333
|
rpcVersion: "0.10.0",
|
|
@@ -7238,6 +7240,16 @@ var RpcChannel3 = class extends RpcChannel2 {
|
|
|
7238
7240
|
channelSpecVersion = _SupportedRpcVersion.v0_10_3;
|
|
7239
7241
|
};
|
|
7240
7242
|
|
|
7243
|
+
// src/channel/rpc_0_10_4.ts
|
|
7244
|
+
var rpc_0_10_4_exports = {};
|
|
7245
|
+
__export(rpc_0_10_4_exports, {
|
|
7246
|
+
RpcChannel: () => RpcChannel4
|
|
7247
|
+
});
|
|
7248
|
+
var RpcChannel4 = class extends RpcChannel3 {
|
|
7249
|
+
id = "RPC0.10.4";
|
|
7250
|
+
channelSpecVersion = _SupportedRpcVersion.v0_10_4;
|
|
7251
|
+
};
|
|
7252
|
+
|
|
7241
7253
|
// src/utils/eventEmitter.ts
|
|
7242
7254
|
var EventEmitter = class {
|
|
7243
7255
|
listeners = {};
|
|
@@ -9695,12 +9707,12 @@ var RpcProvider = class {
|
|
|
9695
9707
|
if (isVersion("0.9", options.specVersion)) {
|
|
9696
9708
|
this.channel = new rpc_0_9_0_exports.RpcChannel({ ...options, waitMode: false });
|
|
9697
9709
|
} else if (isVersion("0.10", options.specVersion)) {
|
|
9698
|
-
this.channel = new
|
|
9710
|
+
this.channel = new rpc_0_10_4_exports.RpcChannel({ ...options, waitMode: false });
|
|
9699
9711
|
} else throw new Error(`unsupported channel for spec version: ${options.specVersion}`);
|
|
9700
9712
|
} else if (isVersion("0.9", config.get("rpcVersion"))) {
|
|
9701
9713
|
this.channel = new rpc_0_9_0_exports.RpcChannel({ ...options, waitMode: false });
|
|
9702
9714
|
} else if (isVersion("0.10", config.get("rpcVersion"))) {
|
|
9703
|
-
this.channel = new
|
|
9715
|
+
this.channel = new rpc_0_10_4_exports.RpcChannel({ ...options, waitMode: false });
|
|
9704
9716
|
} else throw new Error("unable to define spec version for channel");
|
|
9705
9717
|
this.responseParser = new RPCResponseParser(options?.resourceBoundsOverhead);
|
|
9706
9718
|
const plugins = options?.plugins === false ? [] : options?.plugins ?? defaultPlugins;
|
|
@@ -9724,13 +9736,14 @@ var RpcProvider = class {
|
|
|
9724
9736
|
if (isVersion("0.9", specVersion)) {
|
|
9725
9737
|
return new this({
|
|
9726
9738
|
...optionsOrProvider,
|
|
9727
|
-
specVersion
|
|
9739
|
+
specVersion
|
|
9728
9740
|
});
|
|
9729
9741
|
}
|
|
9730
9742
|
if (isVersion("0.10", specVersion)) {
|
|
9731
9743
|
return new this({
|
|
9732
9744
|
...optionsOrProvider,
|
|
9733
|
-
|
|
9745
|
+
// forward the version the node reports, not the newest revision the SDK implements
|
|
9746
|
+
specVersion
|
|
9734
9747
|
});
|
|
9735
9748
|
}
|
|
9736
9749
|
throw new LibraryError(
|
|
@@ -11174,7 +11187,7 @@ var LedgerSigner231 = class extends LedgerSigner221 {
|
|
|
11174
11187
|
encodeCall(call) {
|
|
11175
11188
|
const toBuf = this.convertBnToLedger(call.contractAddress);
|
|
11176
11189
|
const selectorBuf = hexToBytes(addAddressPadding(getSelector(call.entrypoint)));
|
|
11177
|
-
let calldataBuf
|
|
11190
|
+
let calldataBuf;
|
|
11178
11191
|
if (call.calldata) {
|
|
11179
11192
|
const compiledCalldata = CallData.compile(call.calldata);
|
|
11180
11193
|
const calldataSizeBuf = this.convertBnToLedger(compiledCalldata.length);
|
|
@@ -13921,11 +13934,12 @@ export {
|
|
|
13921
13934
|
api_exports as RPC,
|
|
13922
13935
|
rpc_0_10_2_exports as RPC0102,
|
|
13923
13936
|
rpc_0_10_3_exports as RPC0103,
|
|
13937
|
+
rpc_0_10_4_exports as RPC0104,
|
|
13924
13938
|
rpc_0_9_0_exports as RPC09,
|
|
13925
13939
|
RPCResponseParser,
|
|
13926
13940
|
ReceiptTx,
|
|
13927
13941
|
ResponseParser,
|
|
13928
|
-
|
|
13942
|
+
RpcChannel4 as RpcChannel,
|
|
13929
13943
|
RpcError,
|
|
13930
13944
|
RpcProvider,
|
|
13931
13945
|
Signer,
|