I was trying to implement this script to be able to wrap ETH into wETH.
So, I installed Brownie by running pip3 install eth-brownie
.
However, I am having trouble importing interface
in the first line of the script: from brownie import accounts, config, network, interface
.
When it's run, I get the following error message:
from brownie import accounts, config, network, interface
ImportError: cannot import name 'interface' from 'brownie' (/home/blackwidow/.local/lib/python3.8/site-packages/brownie/__init__.py)
It appears I am not the only person with this issue as this has been reported in the past with no apparent solution.
interface
folder?pipx
instead ofpip
?interface
folder in.brownie
folder? If so, no, I only haveaccounts
ethpm
andpackages
. I do haveinterfaces
folder along withbuild
contracts
reports
scripts
andtests
folders when i runbrownie init
Also, I have tried bothpipx install eth-brownie
andpip install eth-brownie
. One thing i noticed is, if I usepip
, it does compile the python script withfrom brownie import accounts
but it does not if I had usedpipx
. They both regardless recognizebrownie
if I enterbrownie
in the terminal. Thank you.