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

Update EIP-7251: return fee from getter and add usage example #9025

Merged
merged 3 commits into from
Nov 27, 2024

Commits on Nov 25, 2024

  1. EIP-7251: return fee from getter and add usage example

    The get operation is meant to be used by contracts to compute the exact amount of ether
    required to add a request. It does not return the fee directly though, but it
    returns the count of 'excess requests' instead. The caller has to compute the fee
    themselves by applying the fee formula.
    
    I think this is not great. The fee logic, while reasonably straightforward, is an
    implementation detail of the contract. Duplicating it into caller contracts could lead to
    a mismatch in the computed values, and it's not necessary. I propose we change the
    system contract to return the fee directly. This contract change has also been submitted
    in this PR: lightclient/sys-asm#33
    
    The Rationale section of the EIP also had some outdated text about returning fee overage
    to the caller. The contract does not return overage, so I am removing that section here,
    and adding recommendations & example code for calling the contract.
    fjl committed Nov 25, 2024
    Configuration menu
    Copy the full SHA
    bb1c6e9 View commit details
    Browse the repository at this point in the history
  2. EIP-7241: fix typo

    fjl committed Nov 25, 2024
    Configuration menu
    Copy the full SHA
    a0b2f84 View commit details
    Browse the repository at this point in the history
  3. EIP-7241: fix typo

    fjl committed Nov 25, 2024
    Configuration menu
    Copy the full SHA
    7272970 View commit details
    Browse the repository at this point in the history