Hey all I'm learning solidity and I'm following a guide on how to make a lottery smart contract.

At the beginning of the project I'm trying to compile after making a brownie-config.yaml

I am met with:

INFO: Could not find files for the given pattern(s).
Brownie v1.16.3 - Python development framework for Ethereum

  File "C:\Python39\lib\site-packages\brownie\_cli\__main__.py", line 64, in main
  File "C:\Python39\lib\site-packages\brownie\_cli\compile.py", line 32, in main
    project_path = project.check_for_project(".")
  File "C:\Python39\lib\site-packages\brownie\project\main.py", line 544, in check_for_project
    structure_config = _load_project_structure_config(folder)
  File "C:\Python39\lib\site-packages\brownie\_config.py", line 272, in _load_project_structure_config
    data = _load_config(project_path).get("project_structure", {})
AttributeError: 'NoneType' object has no attribute 'get'

I have no idea why it can't find these files. They clearly exist. I am using the latest version of node.js

The script I am working with:

// SPDX-License-Identifier: MIT
pragma solidity ^0.8.9;

import "@chainlink/contracts/src/v0.8/interfaces/AggregatorV3Interface.sol";

contract Lottery {
    address payable[] public players;
    uint256 public usdEntryFee;
    //AggregatorV3Interface internal ethUsdPriceFeed;

    constructor(address _priceFeedAddress) public {
        usdEntryFee = 50 * (10**18);
        ethUsdPriceFeed = AggregatorV3Interface(_priceFeedAddress);

    function enter() public {
        //$50 min

    function getEntranceFee() public view returns (uint256) {}

    function startLottery() public {}

    function endLottery() public {}

Brownie config:

  - smartcontractkit/[email protected]
      - '@chainlink=smartcontractkit/[email protected]'

Terminal commands:

brownie init
brownie compile

Screenshot of directory

after letting it sit for a day, I get this error in my terminal instead, not sure what made it become this way:

PS C:\Users\black\smartcontract-lottery> brownie compile
INFO: Could not find files for the given pattern(s).
Brownie v1.16.3 - Python development framework for Ethereum

New compatible solc version available: 0.8.9
Compiling contracts...
  Solc version: 0.8.9
  Optimizer: Enabled  Runs: 200
  EVM Version: Istanbul
CompilerError: solc returned the following errors:

ParserError: Source "C:/Users/black/.brownie/packages/smartcontractkit/[email protected]/contracts/src/v0.8/interfaces/AggregatorV3Interface.sol" not found: File not found.
 --> contracts/Lottery.sol:5:1:
5 | import "@chainlink/contracts/src/v0.8/interfaces/AggregatorV3Interface.sol";
  | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^

PS C:\Users\black\smartcontract-lottery> 
  • Could you edit your question with the command you ran to get this? And also the script you're running? Commented Nov 8, 2021 at 23:29
  • 1
    All done! thanks for the reply! I'm actually following your Solidity, Blockchain, and Smart Contract Course!
    – user85123
    Commented Nov 12, 2021 at 0:08
  • Hmm... Looks good! Perhaps could you put a screenshot of you directory and from which folder you're running the command? Commented Nov 12, 2021 at 20:52
  • okay! done, but it looks like I have a different error now.
    – user85123
    Commented Nov 13, 2021 at 20:59
  • WHat's the new error Commented Nov 15, 2021 at 14:08

1 Answer 1


fixing indentation on Brownie config: file solved that problem for me

but now i have this problem: 'dictionary update sequence element #0 has length 1; 2 is required'

  • it was also indentation problem
    – s.a
    Commented Nov 18, 2021 at 3:50
  • Many issues in compiler.py or _config.py reporting NoneType errors IMHO are related primarily to problems in brownie-config.yaml
    – RndmSymbl
    Commented Mar 20, 2022 at 14:36

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.