Skip to content

Commit

Permalink
feat: add project configuration optimization
Browse files Browse the repository at this point in the history
  • Loading branch information
MagicalBridge committed Dec 27, 2024
1 parent 4c50035 commit 0e43437
Show file tree
Hide file tree
Showing 11 changed files with 21 additions and 17 deletions.
8 changes: 7 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -21,10 +21,16 @@ parent:

## 1.Finality Provider Contracts for layer2

l2fp-contracts is a collection of contracts for managing nodes and verifying BLS signatures in an L2 fast finality network. It receives aggregated signature verifications from Finality Providers in the Babylon and Symbiotic networks to ensure the finality of the network.
l2fp-contracts is a suite of contracts designed for managing nodes and verifying BLS signatures within a Layer 2 fast finality network. It aggregates signature verifications from Finality Providers in the Babylon and Symbiotic networks to ensure the network's finality.

## 2.Usage

### Install Dependencies

```shell
$ forge install
```

### Build

```shell
Expand Down
4 changes: 3 additions & 1 deletion foundry.toml
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,7 @@
src = "src"
out = "out"
libs = ["lib"]

solc = "^0.8.20"
# See more config options https://github.com/foundry-rs/foundry/blob/master/crates/config/README.md#all-options


9 changes: 4 additions & 5 deletions script/deployFinalityRelayer.s.sol
Original file line number Diff line number Diff line change
@@ -1,15 +1,14 @@
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.12;

import "forge-std/Script.sol";
import "forge-std/Vm.sol";
import "@openzeppelin/contracts/proxy/transparent/ProxyAdmin.sol";
import "@openzeppelin/contracts/proxy/transparent/TransparentUpgradeableProxy.sol";

import { EmptyContract } from "../src/utils/EmptyContract.sol";
import { BLSApkRegistry } from "../src/bls/BLSApkRegistry.sol";
import { FinalityRelayerManager } from "../src/core/FinalityRelayerManager.sol";

import {EmptyContract} from "../src/utils/EmptyContract.sol";
import {BLSApkRegistry} from "../src/bls/BLSApkRegistry.sol";
import {FinalityRelayerManager} from "../src/core/FinalityRelayerManager.sol";
import {console, Script} from "forge-std/Script.sol";

contract deployFinalityRelayerScript is Script {
EmptyContract public emptyContract;
Expand Down
4 changes: 1 addition & 3 deletions src/bls/BLSApkRegistry.sol
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,9 @@ import "../interfaces/IBLSApkRegistry.sol";

import "./BLSApkRegistryStorage.sol";

import { console } from "forge-std/Script.sol";



contract BLSApkRegistry is Initializable, OwnableUpgradeable, IBLSApkRegistry, BLSApkRegistryStorage, EIP712{
contract BLSApkRegistry is Initializable, OwnableUpgradeable, IBLSApkRegistry, BLSApkRegistryStorage, EIP712 {
using BN254 for BN254.G1Point;

uint256 internal constant PAIRING_EQUALITY_CHECK_GAS = 120000;
Expand Down
2 changes: 1 addition & 1 deletion src/core/FinalityRelayerManager.sol
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// SPDX-License-Identifier: UNLICENSED
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.20;

import "@openzeppelin-upgrades/contracts/access/OwnableUpgradeable.sol";
Expand Down
2 changes: 1 addition & 1 deletion src/core/FinalityRelayerManagerStorage.sol
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// SPDX-License-Identifier: UNLICENSED
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.20;

import "@openzeppelin-upgrades/contracts/proxy/utils/Initializable.sol";
Expand Down
2 changes: 1 addition & 1 deletion src/interfaces/IFinalityRelayerManager.sol
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
// SPDX-License-Identifier: UNLICENSED
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.20;

import "../libraries/BN254.sol";
Expand Down
1 change: 0 additions & 1 deletion src/libraries/SafeCall.sol
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.20;


library SafeCall {
function send(
address _target,
Expand Down
2 changes: 1 addition & 1 deletion src/utils/EmptyContract.sol
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
// SPDX-License-Identifier: UNLICENSED
pragma solidity ^0.8.13;
pragma solidity ^0.8.20;

contract EmptyContract {
function foo() public pure returns (uint256) {
Expand Down
2 changes: 1 addition & 1 deletion test/BLSApkRegistry.t.sol
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
// SPDX-License-Identifier: MIT
pragma solidity ^0.8.12;
pragma solidity ^0.8.20;

import {Test, console} from "forge-std/Test.sol";
import {BLSApkRegistry} from "../src/bls/BLSApkRegistry.sol";
Expand Down
2 changes: 1 addition & 1 deletion test/FinalityRelayerManager.t.sol
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
// SPDX-License-Identifier: UNLICENSED
pragma solidity ^0.8.13;
pragma solidity ^0.8.20;

import {Test, console} from "forge-std/Test.sol";

Expand Down

0 comments on commit 0e43437

Please sign in to comment.