Coder Social home page Coder Social logo

Comments (11)

xJonathanLEI avatar xJonathanLEI commented on August 15, 2024 1

v0.7.1 is now released to alpha-goerli. I'm starting to work on support for this version.

from starknet-rs.

milancermak avatar milancermak commented on August 15, 2024 1

The way I understood is it's us that should add a new fee field when creating a transaction. It's not something that's coming in the API response.

from starknet-rs.

xJonathanLEI avatar xJonathanLEI commented on August 15, 2024 1

Hmmmm sounds.... reasonable. I mean I appreciate StarkWare providing the docs for preparation for the upcoming version, but it would be much nicer if it can be more detailed...

from starknet-rs.

xJonathanLEI avatar xJonathanLEI commented on August 15, 2024 1

Looks like OpenZeppelin updated their Account contract. I'll start working on task 1.

from starknet-rs.

milancermak avatar milancermak commented on August 15, 2024 1

100% with you that __execute__ looks ugly :)

Since the lib doesn't yet have a public release, I'd go with execute. I think it's more future-proof (as you say, the now deprecated execute will be eventually dropped) and more Rusty, a better abstraction.

from starknet-rs.

xJonathanLEI avatar xJonathanLEI commented on August 15, 2024

For task 1 I still haven't figured out where the field has been added to LOL. @milancermak any idea?

from starknet-rs.

milancermak avatar milancermak commented on August 15, 2024

So probably a new field to InvokeFunctionTransaction, with a hardcoded value of 0 for now.

from starknet-rs.

xJonathanLEI avatar xJonathanLEI commented on August 15, 2024

I just tried adding a fee field to InvokeFunctionTransactionRequest and setting it to 0 or "0" or "0x0", and got:

{
  "code": "StarkErrorCode.SCHEMA_VALIDATION_ERROR",
  "message": "Schema validation failed",
  "problems": {
    "fee": [
      "Unknown field."
    ]
  }
}

Looks like it's not how it works...

from starknet-rs.

xJonathanLEI avatar xJonathanLEI commented on August 15, 2024

Got clarification from StarkWare that this is rather a change on the account contract. We will probably need to wait for OpenZeppelin to update their account contract first, otherwise we'll just be sending invalid signatures.

from starknet-rs.

xJonathanLEI avatar xJonathanLEI commented on August 15, 2024

One thing up for discussion though. In the latest version of IAccount, the execute function is renamed from execute to __execute__ to deliberately break old clients (thanks to selectors not taking parameters into account :)))). Should we also name the function __execute__?

For __execute__:

  1. Using this makes it clear to developers that it's the new version of execute being called.

Against __execute__:

  1. It looks very ugly, well, at least to me...
  2. I expect the old execute to be dropped eventually, so the point for __execute__ above will be irrelevant anyways. (I mean, it's already dropped by the account contract, and I'm talking about ecosystem support like wallets and previously deployed accounts.)

If we go against __execute__, we can always document that it's __execute__ being called. It's obviously gonna be way less... obvious though.

@milancermak WDYT?

from starknet-rs.

xJonathanLEI avatar xJonathanLEI commented on August 15, 2024

There you go. Full v0.7.1 support is here!

from starknet-rs.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.