Skip to content

Commit

Permalink
fix: issue with 38 39 cli annotated type
Browse files Browse the repository at this point in the history
  • Loading branch information
antazoey committed Dec 21, 2023
1 parent 27aa7ef commit 252208e
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 4 deletions.
4 changes: 2 additions & 2 deletions ape_safe/_cli/pending.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
from ape.exceptions import SignatureError
from ape.types import AddressType, MessageSignature
from click.exceptions import BadOptionUsage
from eth_typing import Hash32
from eth_typing import ChecksumAddress, Hash32
from eth_utils import humanize_hash
from hexbytes import HexBytes

Expand Down Expand Up @@ -130,7 +130,7 @@ def _handle_execute_cli_arg(ctx, param, val) -> Optional[Union[AccountAPI, bool]
@click.option("--data", type=HexBytes, help="Transaction data", default=HexBytes(""))
@click.option("--gas-price", type=int, help="Transaction gas price")
@click.option("--value", type=int, help="Transaction value", default=0)
@click.option("--to", "receiver", type=AddressType, help="Transaction receiver")
@click.option("--to", "receiver", type=ChecksumAddress, help="Transaction receiver")
@click.option("--nonce", type=int, help="Transaction nonce")
@click.option("--execute", callback=_handle_execute_cli_arg)
def propose(cli_ctx, ecosystem, safe, data, gas_price, value, receiver, nonce, execute):
Expand Down
5 changes: 3 additions & 2 deletions ape_safe/_cli/safe_mgmt.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
from ape.cli import ConnectedProviderCommand, network_option, non_existing_alias_argument
from ape.exceptions import ChainError, ProviderNotConnectedError
from ape.types import AddressType
from eth_typing import ChecksumAddress

from ape_safe._cli.click_ext import SafeCliContext, safe_cli_ctx, safe_option
from ape_safe.client import ExecutedTxData
Expand Down Expand Up @@ -52,7 +53,7 @@ def _list(cli_ctx: SafeCliContext, network):

@click.command(cls=ConnectedProviderCommand)
@safe_cli_ctx()
@click.argument("address", type=AddressType)
@click.argument("address", type=ChecksumAddress)
@non_existing_alias_argument()
def add(cli_ctx: SafeCliContext, ecosystem, network, address, alias):
"""
Expand Down Expand Up @@ -99,7 +100,7 @@ def remove(cli_ctx: SafeCliContext, safe):

@click.command(cls=ConnectedProviderCommand)
@safe_cli_ctx()
@click.argument("address", type=AddressType)
@click.argument("address", type=ChecksumAddress)
@click.option("--confirmed", is_flag=True, default=None)
def all_txns(cli_ctx: SafeCliContext, address, confirmed):
"""
Expand Down

0 comments on commit 252208e

Please sign in to comment.