Skip to content

Commit

Permalink
Change gnosis deposit data amount
Browse files Browse the repository at this point in the history
Signed-off-by: cyc60 <avsysoev60@gmail.com>
  • Loading branch information
cyc60 committed Apr 4, 2024
1 parent aa005ec commit 34581ea
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 3 deletions.
9 changes: 6 additions & 3 deletions src/common/credentials.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
)
from staking_deposit.key_handling.keystore import Keystore, ScryptKeystore
from staking_deposit.settings import DEPOSIT_CLI_VERSION
from sw_utils import get_eth1_withdrawal_credentials
from sw_utils import convert_to_gno, get_eth1_withdrawal_credentials
from sw_utils.signing import (
DepositData,
DepositMessage,
Expand All @@ -30,7 +30,7 @@

from src.common.utils import chunkify
from src.config.networks import NETWORKS
from src.config.settings import DEPOSIT_AMOUNT_GWEI
from src.config.settings import DEPOSIT_AMOUNT_GWEI, GNOSIS_NETWORKS

# Set path as EIP-2334 format
# https://eips.ethereum.org/EIPS/eip-2334
Expand All @@ -55,7 +55,10 @@ def private_key_bytes(self) -> bytes:

@cached_property
def amount(self) -> int:
return DEPOSIT_AMOUNT_GWEI
amount = DEPOSIT_AMOUNT_GWEI
if self.network in GNOSIS_NETWORKS:
amount = convert_to_gno(amount)
return amount

@cached_property
def withdrawal_credentials(self) -> Bytes32:
Expand Down
1 change: 1 addition & 0 deletions src/config/settings.py
Original file line number Diff line number Diff line change
Expand Up @@ -239,6 +239,7 @@ def is_genesis_vault(self) -> bool:

AVAILABLE_NETWORKS = [MAINNET, HOLESKY, GNOSIS, CHIADO]
DEFAULT_NETWORK = MAINNET
GNOSIS_NETWORKS = [GNOSIS, CHIADO]

# oracles
UPDATE_SIGNATURES_URL_PATH = '/signatures'
Expand Down

0 comments on commit 34581ea

Please sign in to comment.