-
Notifications
You must be signed in to change notification settings - Fork 37
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
sidechain/deploy: Fix version reading of local contracts
Previously, `readContractLocalVersion` didn't pass extra arguments to deploy method. This was normal for the NNS contract, but some other system contracts would fail without the args. The function accepts optional data from now. Another drawback: if contract already exists (deployed earlier), `deploy` method throws `contract already exists` exception. To avoid this, dummy (zero) signer is used as a sender which almost definitely doesn't collide with the real one. One more disadvantage: function didn't add committee signers to deploy invocation. For some contracts that require committee witness for deployment (e.g. Container) version reader could not execute. To cover this, the function now accepts committee members and, for simplicity, always attach them as deployent transaction's signers. Signed-off-by: Leonard Lyubich <[email protected]>
- Loading branch information
1 parent
1f7becb
commit 73f9189
Showing
2 changed files
with
37 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
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