0

我正在尝试运行此代码:

from brownie import accounts, config, network
from brownie import AdvancedCollectible
from scripts.helpful_scripts import fund_advanced_collectible


def main():
    dev = accounts.add(config['wallets']['from_key'])
    print(network.show_active())
    publish_source = False
    advancedCollectible = AdvancedCollectible.deploy(
        config['networks'][network.show_active()]['vrf_coordinator'], 
        config['networks'][network.show_active()]['link_token'], 
        config['networks'][network.show_active()]['keyhash'], 
        {"from": dev},
        publish_source=publish_source 
    )
    fund_advanced_collectible(advancedCollectible)
    return advancedCollectible

用命令

brownie run scripts/advanced_collectible/deploy_advanced.py

我试过 pip freeze 并且我有 brownie 和 eh-brownie Python 版本 >= 3.7

4

1 回答 1

0

看来我们正在做同样的课程。我遇到了完全相同的错误,因为在合同声明期间,我在 Solidity 文件 AdvancedCollectible.sol 中拼错了 AdvancedCollectible。

于 2021-12-06T21:16:30.097 回答