Use L2MessageService versioned API (#96)

This commit is contained in:
The Dark Jester
2024-09-25 08:33:35 -07:00
committed by GitHub
parent 346ce2a128
commit 53ea890056
6 changed files with 2620 additions and 1276 deletions

View File

@@ -1,4 +1,9 @@
[
{
"inputs": [],
"stateMutability": "nonpayable",
"type": "constructor"
},
{
"inputs": [],
"name": "ArrayLengthsDoNotMatch",
@@ -106,6 +111,11 @@
"name": "MessageHashesListLengthHigherThanOneHundred",
"type": "error"
},
{
"inputs": [],
"name": "MessageHashesListLengthIsZero",
"type": "error"
},
{
"inputs": [
{
@@ -503,6 +513,19 @@
"stateMutability": "view",
"type": "function"
},
{
"inputs": [],
"name": "CONTRACT_VERSION",
"outputs": [
{
"internalType": "string",
"name": "",
"type": "string"
}
],
"stateMutability": "view",
"type": "function"
},
{
"inputs": [],
"name": "DEFAULT_ADMIN_ROLE",
@@ -1004,7 +1027,7 @@
"type": "bytes32"
}
],
"internalType": "struct IPauseManager.RoleAddress[]",
"internalType": "struct IPermissionsManager.RoleAddress[]",
"name": "_roleAddresses",
"type": "tuple[]"
},
@@ -1198,7 +1221,7 @@
"type": "bytes32"
}
],
"internalType": "struct IPauseManager.RoleAddress[]",
"internalType": "struct IPermissionsManager.RoleAddress[]",
"name": "_roleAddresses",
"type": "tuple[]"
},

File diff suppressed because it is too large Load Diff

File diff suppressed because it is too large Load Diff

View File

@@ -12,6 +12,9 @@ import { PermissionsManager } from "../../lib/PermissionsManager.sol";
* @custom:security-contact security-report@linea.build
*/
contract L2MessageService is AccessControlUpgradeable, L2MessageServiceV1, L2MessageManager, PermissionsManager {
/// @dev This is the ABI version and not the reinitialize version.
string public constant CONTRACT_VERSION = "1.0";
/// @dev Total contract storage is 50 slots with the gap below.
/// @dev Keep 50 free storage slots for future implementation updates to avoid storage collision.
uint256[50] private __gap_L2MessageService;

View File

@@ -9,7 +9,7 @@ const MAX_UNCHANGED_PART_LEN = 100;
const EXPOSED_CONTRACTS = ["L2MessageService", "LineaRollup", "TimeLock"];
const CONTRACT_OUPUT_ABIS: { [contractName: string]: string } = {
L2MessageService: "L2MessageService.abi",
L2MessageService: "L2MessageServiceV1.0.abi",
LineaRollup: "LineaRollupV6.0.abi", // next version
TimeLock: "TimeLock.abi",
};

View File

@@ -17,7 +17,7 @@ dependencies {
web3jContractWrappers {
def contractAbi = layout.buildDirectory.dir("${rootProject.projectDir}/contracts/abi").get()
.file("L2MessageService.abi").asFile.absolutePath
.file("L2MessageServiceV1.0.abi").asFile.absolutePath
contractsPackage = "net.consensys.linea.contract"
contracts = ["$contractAbi": "L2MessageService"]