Skip to content
This repository has been archived by the owner on Jan 11, 2024. It is now read-only.

Commit

Permalink
Subnet actor and Gateway Diamonds (#138)
Browse files Browse the repository at this point in the history
* Draft facets

* constructor

* update draft

* drafting

* new getter

* draft

* fix bug

* update tests

* update tests

* fix tests

* format

* fix console

* fix console

* fix test

* update github actions

* update pip

* update pip

* fix linting

* refactor info facet

* fix subnet facet

* fix router facet

* fix router facet

* fix lib

* update reentrancy

* format

* init sa diamond

* fix all

* update tests

* make getters

* Refactor src

* add test util

* fix getters

* fix visibility

* update getters

* fix format

* remove console

* update makefile

* add readme

* remove constructors

* deploy diamond

* comment libs

* fix test flow

* build

* build

* build

* update

* resolve conflicts

* format

* fix slither findings

* fix linting

* fix linting

* Fix foundry

* Update src/interfaces/IDiamond.sol

* minor fix

* comment

* uncomment libs

* Fixing addr

* fix readme

* fix depl scripts

* Add louper

* fix linting

* fix testGatewayDiamond_SubmitTopDownCheckpoint_FuzzNumberOfMessages

* fix format

* Update epoch processing (#155)

* Adopt epoch validation

* Fix epoch in ExecutableQueueHelper

* fix linting

* Add tests for libvoring

* add listSubnets

* Fix tests

* Fix misprint in test

* Diamond registry (#153)

* integrate diamond subnet registry

* make selectors storage

* revert openzeppelin changes

* more comments

* update registry template

* fix error

* fix error

* fix error

* fix errors

* fix errors

* fix errors

* fix tests

* fix tests

* update template

* reduce registry size

* remove unused methods

* clean up code

* update registry

* add clone factory

* more logs

* update deployment script

* remove compile

* format

* update template

* remove clone factory

* remove clone factory

* fix test

* revert deleted functions

* update deployment

* remove extra logs

* fix test setup

* fixing unit tests

* fixing unit tests

* fix latest subnet bug

* update nonce when subnet created

* update comment

* Add storage checker (#157)

* Add storage checker

* Run workflows for feature branches

* Diamond patches (#158)

* add nonce to get top down msgs

* add bottomUpCheckPeriod

* Subnet registry fixes (#159)

* Fix bottom up checkpoint period (#160)

fix bottom up checkpoint period

* update contract storage signatures

* Remove old actors

* Update layout

* add list bottom up checkpoint

* fix typo

* Fix list bottom up (#161)

* fix list bottom up

* fix typo

* make multiple of bottom up period

* fix slither

* make pretty

---------

Co-authored-by: Alfonso de la Rocha <adlrocha@tutamail.com>

* Minor fixes (#163)

* remove deployment script for gateway

---------

Co-authored-by: adlrocha <6717133+adlrocha@users.noreply.github.com>
Co-authored-by: Alfonso de la Rocha <adlrocha@tutamail.com>
Co-authored-by: cryptoAtwill <108330426+cryptoAtwill@users.noreply.github.com>
Co-authored-by: cryptoAtwill <willes.lau@protocol.ai>
  • Loading branch information
5 people authored Jul 28, 2023
1 parent 6f8d1a6 commit 192e7e7
Show file tree
Hide file tree
Showing 55 changed files with 7,135 additions and 2,158 deletions.
3 changes: 1 addition & 2 deletions .github/workflows/sast.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@ on:
push:
branches: [ main ]
pull_request:
branches: [ main ]

jobs:
slither:
Expand All @@ -28,7 +27,7 @@ jobs:
- name: Setup Node 16
uses: actions/setup-node@v3
with:
node-version: '16.x'
node-version: '18.x'
cache: 'npm'
- name: Install Node dependencies
run: npm i --unsafe-perm
Expand Down
31 changes: 31 additions & 0 deletions .github/workflows/storage.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
name: Storage check

on:
push:
branches: [ main ]
pull_request:
env:
RPC_URL: https://filecoin-calibration.chainup.net/rpc/v1
PRIVATE_KEY: 0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef

jobs:
storage:
name: Storage layout check
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
with:
submodules: recursive
- name: Setup Node 16
uses: actions/setup-node@v3
with:
node-version: '18.x'
cache: 'npm'
- name: Install Foundry
uses: foundry-rs/foundry-toolchain@v1
with:
cache: false
- name: Install Node dependencies
run: npm i --unsafe-perm
- name: Storage check
run: npx hardhat storage-layout --check
25 changes: 15 additions & 10 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -1,26 +1,31 @@
name: Tests

on:
push:
branches: [ main ]
pull_request:
on:
push:
branches: [ main ]
pull_request:

jobs:
tests:
runs-on: ubuntu-latest
permissions:
contents: read
actions: read
security-events: write
steps:
- name: Checkout Repository
uses: actions/checkout@v3
with:
submodules: recursive


- name: Install python
uses: actions/setup-python@v4
with:
python-version: '3.10'

- name: Install abi
run: pip install eth_abi

- name: Install Foundry
uses: foundry-rs/foundry-toolchain@v1
with:
cache: false

- name: Run tests
run: forge test -vvv
run: forge test -vvv --ffi
3 changes: 2 additions & 1 deletion .solhint.json
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@
"ignoreConstructors": true
}
],
"no-inline-assembly": ["off"],
"no-global-import": "error",
"no-unused-vars": "error",
"const-name-snakecase": "error",
Expand All @@ -19,7 +20,7 @@
"func-name-mixedcase": "error",
"func-param-name-mixedcase": "error",
"modifier-name-mixedcase": "error",
"private-vars-leading-underscore": "error",
"private-vars-leading-underscore": "off",
"var-name-mixedcase": "error",
"imports-on-top": "error",
"no-empty-blocks": "error",
Expand Down
Loading

0 comments on commit 192e7e7

Please sign in to comment.