vyper icon indicating copy to clipboard operation
vyper copied to clipboard

send() function don't pass exception return data

Open AntonD3 opened this issue 2 years ago • 0 comments

Version Information

  • vyper Version (output of vyper --version): 0.3.3
  • OS: macOS
  • Python Version (output of python --version): 2.7.16

What's your issue about?

Source codes:

A.vy:

@external
@payable
def __default__():
    raise "no_receive"

C.vy:

import A as A

a: A

@external
def __init__(_a: address):
    self.a = A(create_forwarder_to(_a))

@external
@payable
def __default__():
    pass

@external
def f():
    send(self.a.address, as_wei_value(1, "wei"))

Problem

If set balance of contract C to 10 wei(for example) and call f(), it will return an exception with empty return data (But fallback in contract A reverts with string).

AntonD3 avatar Aug 08 '22 19:08 AntonD3