WIP: Comparision#116
Conversation
* Remove restake vaults * Remove CumulativeMerkleDrop * Remove redundant error
* Add claim on behalf in RewardSplitter * Review fixes * Split to Eth and Gno versions * Add simple test * Review fixes 2 * Make enterExitQueueOnBehalf external in interface * fixup * Add tests 2 * Fix missing syncRewards calls * Add tests 4 * Add tests 5 * Fix ReentrancyGuard * Modify enterExitQueueOnBehalf returns positionTicket * Add tests for new features * Add tests for gnosis * Review fixes 3 * Optimize syncRewards * Del GnoRewardSplitterEnterExitQueueOnBehalfTest * Add test for claim for multiple users * Cleanup * Review fixes * Del test/RewardSplitter.spec.ts --------- Co-authored-by: Dmitri Tsumak <tsumak.dmitri@gmail.com>
* forge install: openzeppelin-foundry-upgrades v0.4.0 * forge install: openzeppelin-contracts-upgradeable v5.2.0 * Implement changes for pectra support * Add max effective balance check * Fix deposit amount for validators * Add consolidations checker, GnoDaiDistributor * forge install: murky v0.1.0 * WIP * Remove murky * Revert DepositDataRegistry removal, keep backward comp * Fix validator register event emit * WIP * Fix stack too deep * Fix system contract calls * Add snapshots for VaultGnoStaking * Add upgrade and deploy tests * Add upgrade, deploy tests * Add GnoBlocklistVault and GnoErc20Vault tests * Add more tests to GnoErc20Vault * Add upgrade tests to gno vaults * Remove GnoErc20Vault js tests * Remove GnoVault register * Migrate gno genesis vault tests to foundry * Migrate gno priv, priv erc20 vault tests to foundry * Add GNoVault tests * Migrate GnoOsTokenVaultEscrow to foundry * Add EthHelpers * Add DepositDataRegistry.t.sol * Implement test_registerValidator_succeedsWith0x01Validator * Implement DepositDataRegistry tests for single validator * Implement test_registerValidators_successWith0x01Validators * Implement test_registerValidators_successWith0x02Validators * Fix USE_FORK_VAULTS env * Add deposit data registry migrate tests * Add test/EthBlocklistErc20Vault.t.sol * Add EthBlocklistVault.t.sol * add EthErc20Vault tests * Add EthFoxVault tests * Add EthGenesisVault tests * Add EthPrivVault tests * Add EthPrivErc20Vault tests * Add EthVault tests * Add VaultAdmin tests * Add VaultEnterExit tests * Add more VaultEnterExit tests * Add VaultFee tests * Add VaultEthStaking tests * Add VaultOsToken mint tests * Add VaultOsToken burn tests * Add VaultOsToken redeem tests * Add osToken mint event checks * Add event checks * Add liquidation tests * Add event checks to osToken liquidation tests * Add tests for transferOsTokenPositionToEscrow * Add tests for migrating gno vault from v2 to v3 * Add VaultState tests * Extent VaultState tests * Add VaultToken tests * Add VaultVersion tests * Add VaultValidators tests for registering validator * Add fund validators tests * Add withdraw validator tests * Add consolidation tests * Improve consolidations * Add VaultsRegistry tests * Add tests for Consolidations checker, keeper, mev escrows * Add KeeperValidators tests * Add PriceFeed and KeeperValidators tests * Add EthOsTokenVaultEscrow tests * Add EthOsTokenVaultEscrow tests * Add register function tests in EthOsTokenVaultEscrow * Add processExitedAssets tests for EthOsTokenVaultEscrow * Add claimExitedAssets tests for EthOsTokenVaultEscrow * Add test_liquidateOsToken_success * Add redeem and liquidation tests for OsTokenVaultEscrow * Add authenticator and updateLiqConfig tests * Add flashloans tests * Add OsTokenConfig tests * Add OsTokenFlashLoans tests * Add OsToken tests * Add tests for EthValidatorsChecker * Add tests for EthValidatorsChecker * Add Multicall and RewardSplitter tests * Remove unused mocks
* Fix VaultValidators module * Fix VaultValidators module
* Fix VaultValidators module * Fix VaultValidators module * Remove ABI * Refactor .github * Remove implementation files * Remove deployments * Remove hardhat tests, snapshots, modify GnoRewardSplitter tests * Add snapshot checks to RewardSplitter tests
* Fix validators manager signature * Fix github action * Update foundry file * Remove helpers * Remove tsconfig * Remove tasks * Remove snapshots * Add remappings.txt * Update ignore files * Add .env.example * Add UpgradeEthNetwork script * remove libs * forge install: forge-std v1.9.5 * forge install: openzeppelin-contracts-upgradeable v5.2.0 * Add exit queue state function to ValidatorsChecker * Fix tests * Extend EthValidatorsChecker tests * Extend GnoValidatorsChecker tests * Fix GnoValidatorsCheckerTest test * fix .gitignore * Split getExitQueueState into two functions * Fix ValidatorsChecker tests
* Format solidity codes according to foundry * Remove prettier * Fix github workflows * Remove redundant builds in actions * Fix slither * Fix test action * Add snapshot files and check * Add config for slither * Fix snapshot * Add skip snapshots env var * Fix coverage env var in actions * Fix coverage * Update readme * Update snapshots * Update snapshots * Update snapshots
* Update env variables names * add deployments, update end example, foundry.toml * Update deployment files * Update deploy scripts, readme, .env.example * Update execute governor txs script * Add contracts to deployments * Add deploy script for gnosis * Fix test profile in foundry
* Implement Meta vaults * Implement Meta vaults for gnosis * Update MetaVault, add tests * Add test functions interfaces for add subvaults * Add tests for adding new sub vault * Remove vault impl check * Add reject vault tests, fix BalancedCurator * Add deposit to vaults tests for SubVaults * Total assets delta with ejecting vault * Add tests for VaultSubVaults update state * Add claim exited assets tests to VaultSubVaults module * Add EthMetaVaultTest tests * Add MetaVault to GnoHelpers * Update BalancedCurator * Implement meta vault factories * Add zero address admin test * Update snapshots * Fix snapshots * Remove zero check for _checkHarvested in VaultSubVaults module * Fix snapshots * Add donateAssets function * Add donateAssets tests * Remove redundant submodule * Remove oz upgradeable dep * Add oz upgradeable dep * Update snapshots * Remove version check for the sub vault
* Replace xdai tokens distributor with converter for Gnosis * Update snapshots * Fix fork tests * Fix snapshots
* Fix upgrade scripts * Implement OsToken redemptions contract * Add OsTokenRedeemer test definitions * Implement OsTokenRedeemer tests for root updates * Add redeemOsTokenPositions test definitions * Add redeemOsTokenPositions tests * Add OsTokenRedeemer deployment to upgrade scripts * Fix execute governor txs script, update snapshot * Remove tokens from coverage skip
| submodules: recursive | ||
|
|
||
| - name: Install foundry | ||
| uses: foundry-rs/foundry-toolchain@v1 |
Check warning
Code scanning / CodeQL
Unpinned tag for a non-immutable Action in workflow Medium
| name: Run linters | ||
| runs-on: ubuntu-latest | ||
|
|
||
| steps: | ||
| - name: Check out Git repository | ||
| uses: actions/checkout@v3 | ||
|
|
||
| - name: Install Foundry | ||
| uses: foundry-rs/foundry-toolchain@v1 | ||
| with: | ||
| version: stable | ||
|
|
||
| - name: Lint | ||
| run: forge fmt --check |
Check warning
Code scanning / CodeQL
Workflow does not contain permissions Medium
Show autofix suggestion
Hide autofix suggestion
Copilot Autofix
AI about 1 year ago
To fix the issue, we will add a permissions block at the workflow level (root level) to restrict the permissions of the GITHUB_TOKEN. Since the workflow only performs linting tasks, it only needs contents: read permissions. This change ensures that the workflow adheres to the principle of least privilege and avoids granting unnecessary permissions.
| @@ -2,2 +2,5 @@ | ||
|
|
||
| permissions: | ||
| contents: read | ||
|
|
||
| on: |
| uses: actions/checkout@v3 | ||
|
|
||
| - name: Install Foundry | ||
| uses: foundry-rs/foundry-toolchain@v1 |
Check warning
Code scanning / CodeQL
Unpinned tag for a non-immutable Action in workflow Medium
| name: Slither analysis | ||
| runs-on: ubuntu-latest | ||
|
|
||
| steps: | ||
| - uses: actions/checkout@v3 | ||
| with: | ||
| submodules: recursive | ||
|
|
||
| - name: Install Foundry | ||
| uses: foundry-rs/foundry-toolchain@v1 | ||
| with: | ||
| version: stable | ||
|
|
||
| - name: Setup Python | ||
| uses: actions/setup-python@v4 | ||
| with: | ||
| python-version: '3.10' | ||
|
|
||
| - name: Install pip3 | ||
| run: | | ||
| python -m pip install --upgrade pip | ||
|
|
||
| - name: Install Slither | ||
| run: | | ||
| pip3 install slither-analyzer | ||
|
|
||
| - name: Build | ||
| run: forge compile --skip test | ||
|
|
||
| - name: Run Slither | ||
| run: | | ||
| slither --fail-high --skip-clean . |
Check warning
Code scanning / CodeQL
Workflow does not contain permissions Medium
Show autofix suggestion
Hide autofix suggestion
Copilot Autofix
AI about 1 year ago
To fix the issue, we will add a permissions block at the root of the workflow file. This block will specify the minimal permissions required for the workflow to function. Since the workflow only reads repository contents and does not perform any write operations, we will set contents: read as the permission. This ensures that the workflow has the least privileges necessary to complete its tasks.
| @@ -2,2 +2,5 @@ | ||
|
|
||
| permissions: | ||
| contents: read | ||
|
|
||
| on: |
| submodules: recursive | ||
|
|
||
| - name: Install Foundry | ||
| uses: foundry-rs/foundry-toolchain@v1 |
Check warning
Code scanning / CodeQL
Unpinned tag for a non-immutable Action in workflow Medium
| name: Forge Fork Tests | ||
| runs-on: ubuntu-latest | ||
|
|
||
| steps: | ||
| - uses: actions/checkout@v3 | ||
| with: | ||
| submodules: recursive | ||
|
|
||
| - name: Install Foundry | ||
| uses: foundry-rs/foundry-toolchain@v1 | ||
| with: | ||
| version: stable | ||
|
|
||
| - name: Run tests | ||
| run: forge test --isolate -vvv | ||
| env: | ||
| FORGE_SNAPSHOT_CHECK: false | ||
| TEST_USE_FORK_VAULTS: true | ||
| TEST_SKIP_SNAPSHOTS: true | ||
| MAINNET_RPC_URL: ${{ secrets.MAINNET_RPC_URL }} | ||
| GNOSIS_RPC_URL: ${{ secrets.GNOSIS_RPC_URL }} | ||
| FOUNDRY_PROFILE: test |
Check warning
Code scanning / CodeQL
Workflow does not contain permissions Medium test
Show autofix suggestion
Hide autofix suggestion
Copilot Autofix
AI about 1 year ago
To fix the issue, we will add a permissions block at the root level of the workflow. This block will specify contents: read, which is sufficient for the operations performed in this workflow (e.g., checking out the repository and reading secrets). This change ensures that the workflow does not have unnecessary write permissions.
| @@ -2,2 +2,5 @@ | ||
|
|
||
| permissions: | ||
| contents: read | ||
|
|
||
| on: |
| submodules: recursive | ||
|
|
||
| - name: Install Foundry | ||
| uses: foundry-rs/foundry-toolchain@v1 |
Check warning
Code scanning / CodeQL
Unpinned tag for a non-immutable Action in workflow Medium test
| name: Forge Tests | ||
| runs-on: ubuntu-latest | ||
|
|
||
| steps: | ||
| - uses: actions/checkout@v3 | ||
| with: | ||
| submodules: recursive | ||
|
|
||
| - name: Install Foundry | ||
| uses: foundry-rs/foundry-toolchain@v1 | ||
| with: | ||
| version: stable | ||
|
|
||
| - name: Run tests | ||
| run: forge test --isolate --gas-snapshot-check=true -vvv | ||
| env: | ||
| TEST_USE_FORK_VAULTS: false | ||
| TEST_SKIP_SNAPSHOTS: false | ||
| MAINNET_RPC_URL: ${{ secrets.MAINNET_RPC_URL }} | ||
| GNOSIS_RPC_URL: ${{ secrets.GNOSIS_RPC_URL }} | ||
| FOUNDRY_PROFILE: test |
Check warning
Code scanning / CodeQL
Workflow does not contain permissions Medium test
Show autofix suggestion
Hide autofix suggestion
Copilot Autofix
AI about 1 year ago
To fix the issue, we will add a permissions block at the root of the workflow file. This block will specify the minimal permissions required for the workflow to function. Based on the workflow's operations, it only needs to read the repository contents. Therefore, we will set contents: read as the permission. This change ensures that the GITHUB_TOKEN is restricted to the least privilege necessary.
| @@ -8,2 +8,5 @@ | ||
|
|
||
| permissions: | ||
| contents: read | ||
|
|
||
| jobs: |
| submodules: recursive | ||
|
|
||
| - name: Install Foundry | ||
| uses: foundry-rs/foundry-toolchain@v1 |
Check warning
Code scanning / CodeQL
Unpinned tag for a non-immutable Action in workflow Medium test
No description provided.