Skip to content

Commit b4d925a

Browse files
committed
feat: versioning of upgradable contracts implementation
1 parent 3463bb2 commit b4d925a

21 files changed

+40
-8
lines changed

contracts/deploy/upgrade-dispute-kit.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@ const deployUpgradeDisputeKit: DeployFunction = async (hre: HardhatRuntimeEnviro
1414
try {
1515
console.log("upgrading DisputeKitClassicNeo...");
1616
await deployUpgradable(deployments, "DisputeKitClassicNeo", {
17-
newImplementation: "DisputeKitGated",
17+
contract: "DisputeKitClassic",
1818
initializer: "initialize",
1919
from: deployer,
2020
// Warning: do not reinitialize everything, only the new variables

contracts/src/arbitration/DisputeTemplateRegistry.sol

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,8 @@ import "./interfaces/IDisputeTemplateRegistry.sol";
88
/// @title Dispute Template Registry
99
/// @dev A contract to maintain a registry of dispute templates.
1010
contract DisputeTemplateRegistry is IDisputeTemplateRegistry, UUPSProxiable, Initializable {
11+
string public constant override version = "0.8.0";
12+
1113
// ************************************* //
1214
// * Storage * //
1315
// ************************************* //

contracts/src/arbitration/KlerosCore.sol

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,6 +14,8 @@ import {KlerosCoreBase, IDisputeKit, ISortitionModule, IERC20} from "./KlerosCor
1414
/// Core arbitrator contract for Kleros v2.
1515
/// Note that this contract trusts the PNK token, the dispute kit and the sortition module contracts.
1616
contract KlerosCore is KlerosCoreBase {
17+
string public constant override version = "0.8.0";
18+
1719
// ************************************* //
1820
// * Constructor * //
1921
// ************************************* //

contracts/src/arbitration/KlerosCoreNeo.sol

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,8 @@ import "@openzeppelin/contracts/token/ERC721/IERC721.sol";
1515
/// Core arbitrator contract for Kleros v2.
1616
/// Note that this contract trusts the PNK token, the dispute kit and the sortition module contracts.
1717
contract KlerosCoreNeo is KlerosCoreBase {
18+
string public constant override version = "0.8.0";
19+
1820
// ************************************* //
1921
// * Storage * //
2022
// ************************************* //

contracts/src/arbitration/PolicyRegistry.sol

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,8 @@ import "../proxy/Initializable.sol";
77
/// @title PolicyRegistry
88
/// @dev A contract to maintain a policy for each court.
99
contract PolicyRegistry is UUPSProxiable, Initializable {
10+
string public constant override version = "0.8.0";
11+
1012
// ************************************* //
1113
// * Events * //
1214
// ************************************* //

contracts/src/arbitration/SortitionModule.sol

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,8 @@ import {SortitionModuleBase, KlerosCore, RNG} from "./SortitionModuleBase.sol";
1515
/// @title SortitionModule
1616
/// @dev A factory of trees that keeps track of staked values for sortition.
1717
contract SortitionModule is SortitionModuleBase {
18+
string public constant override version = "0.8.0";
19+
1820
// ************************************* //
1921
// * Constructor * //
2022
// ************************************* //

contracts/src/arbitration/SortitionModuleNeo.sol

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,8 @@ import {SortitionModuleBase, KlerosCore, RNG, StakingResult} from "./SortitionMo
1515
/// @title SortitionModuleNeo
1616
/// @dev A factory of trees that keeps track of staked values for sortition.
1717
contract SortitionModuleNeo is SortitionModuleBase {
18+
string public constant override version = "0.8.0";
19+
1820
// ************************************* //
1921
// * Storage * //
2022
// ************************************* //

contracts/src/arbitration/devtools/KlerosCoreRuler.sol

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,8 @@ import "../../libraries/Constants.sol";
1313
contract KlerosCoreRuler is IArbitratorV2, UUPSProxiable, Initializable {
1414
using SafeERC20 for IERC20;
1515

16+
string public constant override version = "0.8.0";
17+
1618
// ************************************* //
1719
// * Enums / Structs * //
1820
// ************************************* //

contracts/src/arbitration/dispute-kits/DisputeKitClassic.sol

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,8 @@ import {DisputeKitClassicBase, KlerosCore} from "./DisputeKitClassicBase.sol";
1717
/// - an incentive system: equal split between coherent votes,
1818
/// - an appeal system: fund 2 choices only, vote on any choice.
1919
contract DisputeKitClassic is DisputeKitClassicBase {
20+
string public constant override version = "0.8.0";
21+
2022
// ************************************* //
2123
// * Constructor * //
2224
// ************************************* //

contracts/src/arbitration/dispute-kits/DisputeKitGated.sol

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,8 @@ interface IERC1155 {
3232
/// - an incentive system: equal split between coherent votes,
3333
/// - an appeal system: fund 2 choices only, vote on any choice.
3434
contract DisputeKitGated is DisputeKitClassicBase {
35+
string public constant override version = "0.8.0";
36+
3537
// ************************************* //
3638
// * Storage * //
3739
// ************************************* //

0 commit comments

Comments
 (0)