-
Notifications
You must be signed in to change notification settings - Fork 4
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(rpc): Asset Unlock status by index (#5776)
## Issue being fixed or feature implemented Platform in the scope of credit withdrawals, need a way to get the status of an Asset Unlock by index. ## What was done? A new RPC was created `getassetunlockchainlocks` that accepts Asset Unlock indexes array as parameter and return corresponding status for each index. The possible outcomes per each index are: - `chainlocked`: If the Asset Unlock index is mined on a Chainlocked block. - `mined`: If no Chainlock information is available, and the Asset Unlock index is mined. - `mempooled`: If the Asset Unlock index is in the mempool. - `unknown`: If none of the above are valid. Note: This RPC is whitelisted for the Platform RPC user. ## How Has This Been Tested? Inserted on `feature_asset_locks.py` covering cases where Asset Unlock txs are in mempool, mined and not present. ## Breaking Changes no ## Checklist: - [x] I have performed a self-review of my own code - [x] I have commented my code, particularly in hard-to-understand areas - [x] I have added or updated relevant unit/integration/functional/e2e tests - [x] I have made corresponding changes to the documentation - [x] I have assigned this pull request to a milestone _(for repository code-owners and collaborators only)_ --------- Co-authored-by: thephez <[email protected]> Co-authored-by: Konstantin Akimov <[email protected]> Co-authored-by: PastaPastaPasta <[email protected]> Co-authored-by: pasta <[email protected]>
- Loading branch information
1 parent
b5dc598
commit 563cc34
Showing
8 changed files
with
149 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,11 @@ | ||
Added RPC | ||
-------- | ||
|
||
- `getassetunlockstatuses` RPC allows fetching of Asset Unlock txs by their withdrawal index. The RPC accepts an array of indexes and returns status for each index. | ||
The possible outcomes per each index are: | ||
- "chainlocked": If the Asset Unlock index is mined on a ChainLocked block. | ||
- "mined": If no ChainLock information is available, and the Asset Unlock index is mined. | ||
- "mempooled": If the Asset Unlock index is in the mempool. | ||
- "unknown": If none of the above are valid. | ||
|
||
Note: This RPC is whitelisted for the Platform RPC user. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters