citydaoproject / contracts

CityDAO's Solidity smart contracts
MIT License
13 stars 9 forks source link

Contract fails to compile #5

Open jjaw opened 2 years ago

jjaw commented 2 years ago

The contract fails to compile when I followed direction from repo readme.

  1. install dependency
    npm ci

    Results in high and critical vulnerabilities

    
    npm WARN deprecated fsevents@2.1.3: "Please update to latest v2.3 or v2.2"
    npm WARN deprecated debug@3.2.6: Debug versions >=3.2.0 <3.2.7 || >=4 <4.3.1 have a low-severity ReDos regression when used in a Node.js environment. It is recommended you upgrade to 3.2.7 or 4.3.1. (https://github.com/visionmedia/debug/issues/797)
    npm WARN deprecated uuid@3.4.0: Please upgrade  to version 7 or higher.  Older versions may use Math.random() in certain circumstances, which is known to be problematic.  See https://v8.dev/blog/math-random for details.

@citydaoproject/contracts@0.1.0 prepare husky install

husky - Git hooks installed

added 544 packages, and audited 545 packages in 7s

95 packages are looking for funding run npm fund for details

11 vulnerabilities (9 moderate, 1 high, 1 critical)

To address issues that do not require attention, run: npm audit fix

To address all issues (including breaking changes), run: npm audit fix --force

Run npm audit for details.

2a. If we fix the vulnerabilities through

npm audit fix --force

Then we will receive the following error

npm run compile

@citydaoproject/contracts@0.1.0 compile hardhat compile

sh: hardhat: command not found

2b. If we do not fix the vulnerabilities

npm run compile

@citydaoproject/contracts@0.1.0 compile hardhat compile

Compiling 14 files with 0.8.4 DeclarationError: Undeclared identifier. --> contracts/ERC721Parcel.sol:27:9: | 27 | _initializeEIP712(_name); | ^^^^^^^^^^^^^^^^^

DeclarationError: Undeclared identifier. --> contracts/ERC721Parcel.sol:56:30: | 56 | uint256 newTokenId = _getNextTokenId(); | ^^^^^^^^^^^^^^^

DeclarationError: Undeclared identifier. --> contracts/ERC721Parcel.sol:66:9: | 66 | parcelOwners[_toAddress] = parcel; | ^^^^^^^^^^^^

DeclarationError: Undeclared identifier. Did you mean "_newBaseMetadataURI" or "setBaseMetadataURI"? --> contracts/ERC721Parcel.sol:79:9: | 79 | _setBaseMetadataURI(_newBaseMetadataURI); | ^^^^^^^^^^^^^^^^^^^

DeclarationError: Identifier not found or not unique. --> contracts/ERC721Parcel.sol:107:9: | 107 | ProxyRegistry proxyRegistry = ProxyRegistry(proxyRegistryAddress); | ^^^^^^^^^^^^^

Error HH600: Compilation failed

For more info go to https://hardhat.org/HH600 or run Hardhat with --show-stack-traces



Is the team still working on this contract?