Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Child Gauge Implementation update #11

Merged
merged 20 commits into from
Sep 16, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
20 commits
Select commit Hold shift + click to select a range
1ad7bdd
feat: update contract with arbitrary reward duration
romanagureev Aug 27, 2024
98243f9
chore: forbid CRV as reward
romanagureev Aug 28, 2024
7a212f3
feat: update implementation with remaining time and amount
romanagureev Aug 28, 2024
2b162fd
refactor: naming and file delimiters
romanagureev Aug 28, 2024
4a0153a
fix: rate per lp corner case
romanagureev Aug 29, 2024
bdfc3f9
chore: add claiming for multiple users and nonreentrant check
romanagureev Aug 29, 2024
c9a08fa
chore: gas optimizations
romanagureev Aug 30, 2024
3d0ee3c
chore: rewards per token getter
romanagureev Aug 30, 2024
baf4745
feat: rollback changes, was decided not to change abi
romanagureev Sep 12, 2024
f6ff2fb
fix: not distributed reward bug
romanagureev Sep 12, 2024
39860c8
feat: import arbitrary duration reward distribution
romanagureev Sep 12, 2024
a40a98f
chore: forbid CRV as reward
romanagureev Sep 12, 2024
b41007f
fix: compilation errors
romanagureev Sep 12, 2024
37a731e
refactor: new line
romanagureev Sep 12, 2024
864da35
fix: return unused amount from deposit
romanagureev Sep 12, 2024
f991ddf
feat: bump latest V6 version where possible, so code looks similar an…
romanagureev Sep 12, 2024
1d0d65e
tests: fix tests and test reward_remaining
romanagureev Sep 12, 2024
b6e43c0
chore: forbid CRV as reward, add few comments and refactor
romanagureev Sep 13, 2024
58ef8b9
fix: permit for smart contracts, withdraw parameters order and comments
romanagureev Sep 13, 2024
cf0e22f
feat: remove msg.sender from salt
romanagureev Sep 13, 2024
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion contracts/ChildGaugeFactory.vy
Original file line number Diff line number Diff line change
Expand Up @@ -166,7 +166,7 @@ def deploy_gauge(_lp_token: address, _salt: bytes32, _manager: address = msg.sen

gauge_data: uint256 = 1 # set is_valid_gauge = True
implementation: address = self.get_implementation
salt: bytes32 = keccak256(_abi_encode(chain.id, msg.sender, _salt))
salt: bytes32 = keccak256(_abi_encode(chain.id, _salt))
gauge: address = create_minimal_proxy_to(
implementation, salt=salt
)
Expand Down
2 changes: 1 addition & 1 deletion contracts/RootGaugeFactory.vy
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@ def deploy_gauge(_chain_id: uint256, _salt: bytes32) -> RootGauge:
assert bridger != empty(Bridger) # dev: chain id not supported

implementation: address = self.get_implementation
salt: bytes32 = keccak256(_abi_encode(_chain_id, msg.sender, _salt))
salt: bytes32 = keccak256(_abi_encode(_chain_id, _salt))
gauge: RootGauge = RootGauge(create_minimal_proxy_to(
implementation,
value=msg.value,
Expand Down
Loading
Loading