Back to glossary

Debug with Print (Vyper Code Example)

Table of Contents

Use the built-in function print to debug smart contracts.

# pragma version ^0.4.0

@external
def test_print():
    x: uint256 = 123
    # Set hardhat_compat = True when testing with Hardhat
    print("print something here", x, hardhat_compat=True)

Related Terms

No items found.