Skip to content

Commit 183515e

Browse files
authored
Merge pull request #250 from opentensor/release/1.5.14
Release/1.5.14
2 parents a0b9b55 + 71f134d commit 183515e

File tree

7 files changed

+48
-18
lines changed

7 files changed

+48
-18
lines changed

.github/workflows/check-btcli-tests.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ on:
1313
branches:
1414
- main
1515
- staging
16+
- master
1617
types: [opened, synchronize, reopened, labeled, unlabeled]
1718

1819
env:

.github/workflows/check-sdk-tests.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@ on:
1313
branches:
1414
- main
1515
- staging
16+
- master
1617
types: [opened, synchronize, reopened, labeled, unlabeled]
1718

1819
workflow_dispatch:

CHANGELOG.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,10 @@
11
# Changelog
2+
3+
## 1.5.14 /2025-12-04
4+
* Update: Adds support for custom extrinsic `DecryptionFailed` by @ibraheem-abe in https://github.com/opentensor/async-substrate-interface/pull/247
5+
6+
**Full Changelog**: https://github.com/opentensor/async-substrate-interface/compare/v1.5.13...v1.5.14
7+
28
## 1.5.13 /2025-12-01
39
* Update `Checkout PR branch in async-substrate-interface` step by @basfroman in https://github.com/opentensor/async-substrate-interface/pull/240
410
* No continual reconnection without cause by @thewhaleking in https://github.com/opentensor/async-substrate-interface/pull/241

async_substrate_interface/async_substrate.py

Lines changed: 19 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -297,7 +297,8 @@ async def process_events(self):
297297
and event["event"]["event_id"] == "ExtrinsicFailed"
298298
) or (
299299
event["event"]["module_id"] == "MevShield"
300-
and event["event"]["event_id"] == "DecryptedRejected"
300+
and event["event"]["event_id"]
301+
in ("DecryptedRejected", "DecryptionFailed")
301302
):
302303
possible_success = False
303304
self.__is_success = False
@@ -308,13 +309,23 @@ async def process_events(self):
308309
self.__weight = dispatch_info["weight"]
309310
else:
310311
# MEV shield extrinsics
311-
dispatch_info = event["event"]["attributes"]["reason"][
312-
"post_info"
313-
]
314-
dispatch_error = event["event"]["attributes"]["reason"]["error"]
315-
self.__weight = event["event"]["attributes"]["reason"][
316-
"post_info"
317-
]["actual_weight"]
312+
if event["event"]["event_id"] == "DecryptedRejected":
313+
dispatch_info = event["event"]["attributes"]["reason"][
314+
"post_info"
315+
]
316+
dispatch_error = event["event"]["attributes"]["reason"][
317+
"error"
318+
]
319+
self.__weight = event["event"]["attributes"]["reason"][
320+
"post_info"
321+
]["actual_weight"]
322+
else:
323+
self.__error_message = {
324+
"type": "MevShield",
325+
"name": "DecryptionFailed",
326+
"docs": event["event"]["attributes"]["reason"],
327+
}
328+
continue
318329

319330
if "Module" in dispatch_error:
320331
if isinstance(dispatch_error["Module"], tuple):

async_substrate_interface/sync_substrate.py

Lines changed: 19 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -258,7 +258,8 @@ def process_events(self):
258258
and event["event"]["event_id"] == "ExtrinsicFailed"
259259
) or (
260260
event["event"]["module_id"] == "MevShield"
261-
and event["event"]["event_id"] == "DecryptedRejected"
261+
and event["event"]["event_id"]
262+
in ("DecryptedRejected", "DecryptionFailed")
262263
):
263264
possible_success = False
264265
self.__is_success = False
@@ -269,13 +270,23 @@ def process_events(self):
269270
self.__weight = dispatch_info["weight"]
270271
else:
271272
# MEV shield extrinsics
272-
dispatch_info = event["event"]["attributes"]["reason"][
273-
"post_info"
274-
]
275-
dispatch_error = event["event"]["attributes"]["reason"]["error"]
276-
self.__weight = event["event"]["attributes"]["reason"][
277-
"post_info"
278-
]["actual_weight"]
273+
if event["event"]["event_id"] == "DecryptedRejected":
274+
dispatch_info = event["event"]["attributes"]["reason"][
275+
"post_info"
276+
]
277+
dispatch_error = event["event"]["attributes"]["reason"][
278+
"error"
279+
]
280+
self.__weight = event["event"]["attributes"]["reason"][
281+
"post_info"
282+
]["actual_weight"]
283+
else:
284+
self.__error_message = {
285+
"type": "MevShield",
286+
"name": "DecryptionFailed",
287+
"docs": event["event"]["attributes"]["reason"],
288+
}
289+
continue
279290

280291
if "Module" in dispatch_error:
281292
if isinstance(dispatch_error["Module"], tuple):

async_substrate_interface/types.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1127,7 +1127,7 @@ def _get_metadata_storage_functions(self, runtime: Runtime) -> list[dict[str, An
11271127
self.serialize_storage_item(
11281128
storage_item=storage,
11291129
module=module,
1130-
spec_version_id=self.runtime.runtime_version,
1130+
spec_version_id=runtime.runtime_version,
11311131
runtime=runtime,
11321132
)
11331133
)

pyproject.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[project]
22
name = "async-substrate-interface"
3-
version = "1.5.13"
3+
version = "1.5.14"
44
description = "Asyncio library for interacting with substrate. Mostly API-compatible with py-substrate-interface"
55
readme = "README.md"
66
license = { file = "LICENSE" }

0 commit comments

Comments
 (0)