Skip to content

Feature request: support function selector in aut contract tx command group #198

@cmjc

Description

@cmjc

Context

To generate a transaction the contract ABI, function name, and the parameters are specified. Example using the ASM borrow() function:

aut contract tx --abi Stabilization.abi --address 0x29b2440db4A256B0c1E6d3B4CDcaA68E2440A08f borrow <AMOUNT> | aut tx sign - | aut tx send -

Problem

The problem is a Solidity contract can use function overloading i.e. functions in the same scope can have the same name and be differentiated by function signature. EVM tools handle this by using the function selector - the first 4 bytes from the keccak256 hash of the function signature.

autonity.py supports using the function selector, but Autonity CLI doesn't.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions