by

Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
    Ben Scherrey
    @scherrey
    @fubuloubu yep understand - was just curious if there was any sense of timeframe based on present progress.
    Bryant Eisenbach
    @fubuloubu
    I hear if you say nice things about Brownie, type checking might ship faster
    Ben Scherrey
    @scherrey
    haha I haven't tried Brownie yet but it looks really promising.
    arjuna sky kok
    @arjunaskykok_gitlab
    @scherrey Don't forget to try Mamba (https://mamba.black) too. I'll try to add a basic smart contract auditor to Mamba in this year.
    1 reply
    Bryant Eisenbach
    @fubuloubu
    you mean static analysis tool?
    @scherrey yeah, Brownie is legitimately awesome
    @iamdefinitelyahuman added a mainnet interaction tool, you can do testing against mainnet with your contracts!
    arjuna sky kok
    @arjunaskykok_gitlab
    @fubuloubu sort of. I would explore approaches like formal verification, and machine learning. I need to add some stuff first to Mamba, like GUI support, box (like Truffle box), EPM support, then I would start studying Vyper in depth. Hopefully I have something to show in Q4 of this year.
    Sylvain Bellemare
    @sbellem
    @iamdefinitelyahuman Hey Ben, just in case that it may be of some use for this black/isort thing: timothycrosley/isort#694
    Ben Hauser
    @iamdefinitelyahuman
    @sbellem thanks! i have a PR waiting to be merged with new linting rules that will make black compatible with isort - vyperlang/vyper#1964
    Sylvain Bellemare
    @sbellem
    :+1:
    Timothy O'Reilly
    @crazykid080

    Hi, I'm currently working on learning Vyper and I pulled the sample Prysmaticlabs Contract on etherscan and started to adapt it to the newest version and I ran into and issue:

    vyper.exceptions.StructureException: line 44:16 Cannot call public functions via 'self'
         43
    ---> 44     log.Deposit(self.get_deposit_root(), deposit_data, self.to_bytes(index))
    ------------------------^
         45
    .......
    vyper.exceptions.StructureException: line 44:16 Not a top-level function: get_deposit_root. Did you mean self.get_deposit_root?
         43
    ---> 44     log.Deposit(get_deposit_root(), deposit_data, self.to_bytes(index))
    ------------------------^

    Can anyone help me out here?

    Bryant Eisenbach
    @fubuloubu
    are you using the correct version of Vyper? It was compiled against a hotfix branch of beta.13 maintained especially for the deposit contract: https://github.com/vyperlang/vyper/tree/1761-HOTFIX-v0.1.0-beta.13
    Timothy O'Reilly
    @crazykid080
    I'm adapting it to 0.1.0b17+commit.0671b7b just to help me understand more about the syntax and nuances
    Bryant Eisenbach
    @fubuloubu
    oh I see, yeah sometime between then and now we disallowed public calls within mutating calls. You should do something like:
    deposit_root: bytes32 = self.get_deposit_root()
    log.Deposit(deposit_root, ...)
    Timothy O'Reilly
    @crazykid080
    Hmmm, still getting the same complaint, odd
    Timothy O'Reilly
    @crazykid080
    After taking a break I decided to simply grab the value it needed directly instead of calling the function. That fixes the issue, though I'm not sure if that should be the correct way of going about it
    Timothy O'Reilly
    @crazykid080
    How would I explicitly initialize branch: bytes32[32]? My first assumption would be to create a large array though I assume that isn't the best way to do it
    Bryant Eisenbach
    @fubuloubu
    @crazykid080 as of Apr 8th, you can use branch: bytes32[32] = empty(bytes32[32])
    Timothy O'Reilly
    @crazykid080
    Oh boy, looks like I'll have to wait until the next release then, thanks for the answer though
    Bryant Eisenbach
    @fubuloubu
    hopefully coming shortly :grimacing: 🤞
    Oli Guei
    @olivrg
    I'm really happy to come across this community. I've been thinking about getting into smart contract development but Solidity's JS-like nature turned me off then I found Vyper. Currently completing the tutorial on the docs. Thank you for the work you do!
    arjuna sky kok
    @arjunaskykok_gitlab
    @olivrg Welcome to the club!
    Bryant Eisenbach
    @fubuloubu
    @olivrg awesome! welcome!
    if you see anything in the docs that are missing or unclear to you, feel free to bring them up here!
    Bryant Eisenbach
    @fubuloubu
    we added a bounty to help create a means of distributing Vyper where it can be used in dev frameworks and client-side apps with more than 1 version at a time. it's a complex feature, so feel free to reach out for further clarification! https://gitcoin.co/funding/details/?url=https://github.com/vyperlang/vyper/issues/1953&sb=1
    draco-thuban
    @draco-thuban
    • Hi, I have been looking into your bounty on Gitcoin. Before I apply for the bounty, I was wondering if I could get some more clarity as to what you (all) are looking for.
      • Can you clarify the two following statements from the post?
        • Allow multiple Vyper binaries to play nicely with each other.
        • Can use multiple versions of Vyper in any host framework that is supported with this proposal.
    Bryant Eisenbach
    @fubuloubu
    Yeah, we weren't two clear with the requirements, but thanks for asking here!
    We want vyper/vyper-json CLI scripts in a standalone format that can use multiple versions of those standalone binaries at least in Python and Javascript, so someone can compile a project that uses different versions of Vyper entirely client-side (without running a server or anything). This would be similar to how Solidity distributes their solc library on NPM: https://www.npmjs.com/package/solc and as a separate binary: https://github.com/ethereum/solidity/releases
    Bryant Eisenbach
    @fubuloubu
    I added a comment with some work that @jacqueswww did a long time ago that could help build something really nice we can use to build and distribute these copies to appropiate places: https://github.com/vyperlang/vyper/issues/1953#issuecomment-631596232
    I'd like to refactor that work so it doesn't use a fork of pyodide
    arjuna sky kok
    @arjunaskykok_gitlab
    Vyper can run in browser (JavaScript) now?
    Bryant Eisenbach
    @fubuloubu
    Not right now, but it's something we'd like to add
    arjuna sky kok
    @arjunaskykok_gitlab
    So I guess the bounty should be split into two tasks: 1. multiple versions of Vyper, 2. Porting Vyper to JavaScript/Wasm.
    Bryant Eisenbach
    @fubuloubu
    wee have most of stuff needed to do those things, if you want to think of them logically that way, it helps
    Anh Dung Le
    @anhdungle93
    Hi, I heard that Vyper will receive more support in Ethereum2.0. Is it true? If yes what does it actually contain?
    conta16
    @conta16
    Hi, I read on the online documentation that it's possible to compute a precise upper bound for the gas consumption of any Vyper function call. Since I am trying to make a research on gas bounds, I would like to know, how do you calculate these bounds? Do you already have some kind of tools that statically estimate these bounds, or do you simulate the smart contract (which is known to terminate) in a local environment and then see how much gas it uses?
    Alexis Anand
    @zenithlight
    why isn't there a signed 256 bit integer type?
    Bryant Eisenbach
    @fubuloubu
    @zenithlight working on adding all integer types
    @conta16 static analysis, since all variable data types have an explicit upper bound, and all operations on variable data types can use that to compute the worst case.
    obviously doesn't work for external calls
    @anhdungle93 ETH 2.0 is likely 2+ years away from having support for smart contracts, it's not something we currently support but will make plans to do so as it gets closer
    conta16
    @conta16
    Thank you for the reply! One more thing: do you have something online that does this static analysis? I would like to get a better understanding on the matter.
    Bryant Eisenbach
    @fubuloubu
    @conta16 The compiler itself does it when it produces the gas cost estimates, it's not a separate tool
    it's not a terribly complicated algorithm, most of the gas costs are pretty well-defined already, we only leverage the maximum sizing on variable-length data operations
    Usually it overshoots a large amount, and it's often better to dynamically estimate costs to reduce the gas limit you'd set in a transaction, but it does lead to more predictable transaction costs and helps reduce a class of vulnerabilities using gas cost exploits
    Benjamin Cordes
    @benjyz
    question: does typing.py over ride standard python typing or how does it work. get an error here
    "ImportError: cannot import name 'Dict' from 'typing'"