From 908abfdd95c1bd1e9893454fc79476e8de878216 Mon Sep 17 00:00:00 2001 From: Uladzislau Hubar <71610423+u-hubar@users.noreply.github.com> Date: Mon, 12 Feb 2024 12:20:25 +0100 Subject: [PATCH] =?UTF-8?q?Revert=20"Removed=20indexed=20args=20from=20Com?= =?UTF-8?q?mitManagerV2,=20redeployed=20CommitManagerV2=E2=80=A6"?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- abi/CommitManagerV2.json | 6 +++--- contracts/v2/CommitManagerV1.sol | 6 +++--- deployments/gnosis_chiado_dev_contracts.json | 7 +++---- deployments/gnosis_chiado_test_contracts.json | 7 +++---- package-lock.json | 4 ++-- package.json | 2 +- utils/helpers.ts | 7 ++----- 7 files changed, 17 insertions(+), 22 deletions(-) diff --git a/abi/CommitManagerV2.json b/abi/CommitManagerV2.json index 8cc352ff..4b9788b9 100644 --- a/abi/CommitManagerV2.json +++ b/abi/CommitManagerV2.json @@ -422,13 +422,13 @@ "anonymous": false, "inputs": [ { - "indexed": false, + "indexed": true, "internalType": "address", "name": "assetContract", "type": "address" }, { - "indexed": false, + "indexed": true, "internalType": "uint256", "name": "tokenId", "type": "uint256" @@ -452,7 +452,7 @@ "type": "uint16" }, { - "indexed": false, + "indexed": true, "internalType": "uint72", "name": "identityId", "type": "uint72" diff --git a/contracts/v2/CommitManagerV1.sol b/contracts/v2/CommitManagerV1.sol index 1f2aecb0..8fd19850 100644 --- a/contracts/v2/CommitManagerV1.sol +++ b/contracts/v2/CommitManagerV1.sol @@ -23,12 +23,12 @@ import {ServiceAgreementErrorsV2} from "./errors/ServiceAgreementErrorsV2.sol"; contract CommitManagerV2 is Named, Versioned, ContractStatus, Initializable { event CommitSubmitted( - address assetContract, - uint256 tokenId, + address indexed assetContract, + uint256 indexed tokenId, bytes keyword, uint8 hashFunctionId, uint16 epoch, - uint72 identityId, + uint72 indexed identityId, uint40 score ); diff --git a/deployments/gnosis_chiado_dev_contracts.json b/deployments/gnosis_chiado_dev_contracts.json index 5f895b3b..19b1520c 100644 --- a/deployments/gnosis_chiado_dev_contracts.json +++ b/deployments/gnosis_chiado_dev_contracts.json @@ -17,12 +17,11 @@ "version": "1.0.0" }, "CommitManagerV1": { - "evmAddress": "0x9D2405e3f786E78e3C71A0eaB571b773E44f7A44", + "evmAddress": "0xE58754A57cCDDdbA5e3e1D6FC3B71f1e56E21EE4", "version": "2.0.0", "gitBranch": "main", - "gitCommitHash": "4ae423f802d917c185c9ad846d6cc0f0c1af4513", - "deploymentBlock": 8197782, - "deploymentTimestamp": 1707731610813, + "gitCommitHash": "dab8582c750eb8e189eff201a74eead1ca554fe7", + "deploymentTimestamp": 1707423228358, "deployed": true }, "CommitManagerV1U1": { diff --git a/deployments/gnosis_chiado_test_contracts.json b/deployments/gnosis_chiado_test_contracts.json index d2c426df..404b1e94 100644 --- a/deployments/gnosis_chiado_test_contracts.json +++ b/deployments/gnosis_chiado_test_contracts.json @@ -205,12 +205,11 @@ "deployed": true }, "CommitManagerV1": { - "evmAddress": "0x1869a2155c1F5f7AfE5ac2C27595c04AA250D0B7", + "evmAddress": "0xc936B57e7f45cbC1Dde0802037F51FCDf7E40Dab", "version": "2.0.0", "gitBranch": "main", - "gitCommitHash": "4ae423f802d917c185c9ad846d6cc0f0c1af4513", - "deploymentBlock": 8197803, - "deploymentTimestamp": 1707731717431, + "gitCommitHash": "06afb8b08c1f5afb779d1c89157021bc70f2fe98", + "deploymentTimestamp": 1707489017673, "deployed": true }, "CommitManagerV1U1": { diff --git a/package-lock.json b/package-lock.json index 155cf2e1..f5b37147 100644 --- a/package-lock.json +++ b/package-lock.json @@ -1,12 +1,12 @@ { "name": "dkg-evm-module", - "version": "4.2.4", + "version": "4.2.3", "lockfileVersion": 2, "requires": true, "packages": { "": { "name": "dkg-evm-module", - "version": "4.2.4", + "version": "4.2.3", "license": "Apache-2.0", "dependencies": { "@openzeppelin/contracts": "^4.9.3", diff --git a/package.json b/package.json index 546ba85f..76de4a97 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "dkg-evm-module", - "version": "4.2.4", + "version": "4.2.3", "description": "Smart contracts for OriginTrail V6", "main": "index.ts", "files": [ diff --git a/utils/helpers.ts b/utils/helpers.ts index dcf67fc0..a786ddc7 100644 --- a/utils/helpers.ts +++ b/utils/helpers.ts @@ -27,7 +27,6 @@ type ContractDeployments = { version: string; gitBranch: string; gitCommitHash: string; - deploymentBlock: number; deploymentTimestamp: number; deployed: boolean; }; @@ -212,8 +211,7 @@ export class Helpers { this.contractsForReinitialization.push(newContract.address); } - // eslint-disable-next-line @typescript-eslint/no-non-null-assertion - await this.updateDeploymentsJson(nameInHub, newContract.address, newContract.receipt!.blockNumber); + await this.updateDeploymentsJson(nameInHub, newContract.address); return await this.hre.ethers.getContractAt(this.getAbi(newContractName), newContract.address, deployer); } @@ -318,7 +316,7 @@ export class Helpers { this.contractDeployments = { contracts: {} }; } - public async updateDeploymentsJson(newContractName: string, newContractAddress: string, deploymentBlock: number) { + public async updateDeploymentsJson(newContractName: string, newContractAddress: string) { const contractABI = this.getAbi(newContractName); const isVersionedContract = contractABI.some( (abiEntry) => abiEntry.type === 'function' && abiEntry.name === 'version', @@ -339,7 +337,6 @@ export class Helpers { version: contractVersion, gitBranch: this.getCurrentGitBranch(), gitCommitHash: this.getCurrentGitCommitHash(), - deploymentBlock: deploymentBlock, deploymentTimestamp: Date.now(), deployed: true, };