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

feat: allow configuring accounts to show full calldata when signing #2523

Open
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

antazoey
Copy link
Member

@antazoey antazoey commented Feb 19, 2025

What I did

accounts:
  calldata_repr: full  # defaults to "abridged", I plan on also adding "decoded" and maybe making the default "decoded"

How I did it

How to verify it

Checklist

  • All changes are completed
  • Change is covered in tests
  • Documentation is complete

@antazoey antazoey force-pushed the feat/config-show-full-data branch from 1be0350 to 26e14d1 Compare February 19, 2025 21:20

class CalldataRepr(str, Enum):
full = "full"
abridged = "abridged"
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I plan to add "decoded" here and it will attempt to decode the calldata if possible

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

decoded would be amazing tbh

@BowTiedDevil was saying the same yesterday

return self.to_string()

def to_string(
self, calldata_repr: Optional[Union[Literal["full"], Literal["abridged"]]] = None
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can this use CalldataRepr enum?



@register(Config)
def config_class():
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Wonder if this instead should be a "core config" item, e.g.

display:
  transactions: abridged

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Mostly since behavior isn't just limited to ape-accounts

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants