Skip to content
This repository has been archived by the owner on Jun 11, 2024. It is now read-only.

Update terminateChain of BaseInteroperabilityStore #7557

Closed
Tracked by #7211
ishantiw opened this issue Sep 22, 2022 · 0 comments
Closed
Tracked by #7211

Update terminateChain of BaseInteroperabilityStore #7557

ishantiw opened this issue Sep 22, 2022 · 0 comments
Assignees
Labels
framework/module/interoperability Interoperability module
Milestone

Comments

@ishantiw
Copy link
Contributor

ishantiw commented Sep 22, 2022

Description

Update terminateChain function BaseInteroperabilityStore that terminates a chain account.

def terminateChain(chainID: ChainID) -> None:
    # Chain was already terminated, do nothing
    if terminatedStateAccount(chainID) exists:
        return
    send(
        EMPTY_FEE_ADDRESS,
        MODULE_NAME_INTEROPERABILITY,
        CROSS_CHAIN_COMMAND_CHANNEL_TERMINATED,
        chainID,
        0,
        CODE_OK,
        {
            "nonce": chainAccount(chainID).nonce,
            "status": CHAIN_STATUS_TERMINATED
        }
    )
    createTerminatedStateAccount(chainID)

Acceptance Criteria

  • Should pass unit tests corresponding to terminateChain

Additional Information

@ishantiw ishantiw added the framework/module/interoperability Interoperability module label Sep 22, 2022
@shuse2 shuse2 added this to the Sprint 79 milestone Sep 26, 2022
@Phanco Phanco self-assigned this Oct 4, 2022
@shuse2 shuse2 modified the milestones: Sprint 79, Sprint 80 Oct 10, 2022
@shuse2 shuse2 modified the milestones: Sprint 80, Sprint 81 Oct 24, 2022
@shuse2 shuse2 modified the milestones: Sprint 81, Sprint 82 Nov 7, 2022
@shuse2 shuse2 modified the milestones: Sprint 82, Sprint 83 Nov 21, 2022
ishantiw added a commit that referenced this issue Nov 24, 2022
### What was the problem?

This PR resolves #7557

### How was it solved?

Implemented `terminateChain` function

### How was it tested?

Updated unit test
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
framework/module/interoperability Interoperability module
Projects
None yet
Development

No branches or pull requests

3 participants