From 8925a5d49d21c9ad7ac279e7320439f21c4a4dad Mon Sep 17 00:00:00 2001 From: Jongwon Park Date: Wed, 7 Feb 2024 18:53:27 -0800 Subject: [PATCH] Enforcing Lints to Enhance Code Standard (#86) * fix: makefile fork url * fix: test utils import * fix: pkg dep and bumps * config: lint, pkg, husky changes * lint: prettier lint run * nit: config fix * lint: solhint/prettier linting fixes * fix: pkg installs --- .editorconfig | 21 + .husky/pre-push | 6 + .prettierrc | 7 + .solcover.js | 13 + .solhint.json | 8 +- Makefile | 4 +- contracts/AccessController.sol | 2 +- .../interfaces/governance/IGovernable.sol | 3 +- contracts/interfaces/modules/base/IModule.sol | 1 - .../modules/dispute/IDisputeModule.sol | 8 +- .../dispute/policies/IArbitrationPolicy.sol | 4 +- .../modules/licensing/ILicensingModule.sol | 6 +- .../licensing/IPolicyFrameworkManager.sol | 3 - .../licensing/IUMLPolicyFrameworkManager.sol | 7 +- .../modules/royalty/IRoyaltyModule.sol | 9 +- .../modules/royalty/policies/ILSClaimer.sol | 2 +- .../royalty/policies/ILiquidSplitClone.sol | 12 +- .../royalty/policies/ILiquidSplitFactory.sol | 6 +- .../royalty/policies/ILiquidSplitMain.sol | 10 +- .../royalty/policies/IRoyaltyPolicy.sol | 4 +- .../royalty/policies/IRoyaltyPolicyLS.sol | 4 +- .../registries/IIPAccountRegistry.sol | 15 +- .../registries/IIPAssetRegistry.sol | 8 +- .../registries/ILicenseRegistry.sol | 2 +- .../metadata/IMetadataProviderMigratable.sol | 2 +- .../metadata/IMetadataProviderV1.sol | 1 - .../resolvers/IKeyValueResolver.sol | 12 +- contracts/interfaces/resolvers/IResolver.sol | 4 +- contracts/lib/AccessPermission.sol | 2 +- contracts/lib/Errors.sol | 2 +- contracts/lib/Licensing.sol | 3 +- contracts/lib/MetaTx.sol | 9 +- contracts/lib/registries/IPAccountChecker.sol | 2 +- .../modules/dispute-module/DisputeModule.sol | 28 +- .../policies/ArbitrationPolicySP.sol | 9 +- .../licensing/BasePolicyFrameworkManager.sol | 10 +- .../modules/licensing/LicensingModule.sol | 29 +- .../licensing/UMLPolicyFrameworkManager.sol | 15 +- .../LicensorApprovalChecker.sol | 5 +- .../modules/royalty-module/RoyaltyModule.sol | 16 +- .../royalty-module/policies/LSClaimer.sol | 36 +- .../policies/RoyaltyPolicyLS.sol | 33 +- contracts/modules/tagging/TaggingModule.sol | 5 +- contracts/registries/IPAssetRegistry.sol | 2 +- contracts/registries/ModuleRegistry.sol | 2 +- .../registries/metadata/IPAssetRenderer.sol | 30 +- .../metadata/IPMetadataProvider.sol | 3 - .../metadata/MetadataProviderBase.sol | 6 +- .../metadata/MetadataProviderV1.sol | 17 +- contracts/utils/ShortStringOps.sol | 2 +- hardhat.config.ts | 49 +- package.json | 46 +- test/foundry/AccessController.t.sol | 61 +- test/foundry/IPAccount.t.sol | 84 +- test/foundry/IPAccountMetaTx.t.sol | 34 +- test/foundry/IPAssetRegistry.t.sol | 102 +- test/foundry/ModuleRegistry.t.sol | 3 - test/foundry/access/AccessControlled.t.sol | 18 +- test/foundry/governance/Governance.t.sol | 11 +- test/foundry/integration/BaseIntegration.sol | 13 +- .../big-bang/NftLicenseRoyalty.t.sol | 21 +- .../big-bang/SingleNftCollection.t.sol | 3 +- .../EmergenceUniverse.t.sol | 12 +- .../integration/shared/LicenseHelper.sol | 5 +- .../mocks/MockAccessControlledModule.sol | 11 +- test/foundry/mocks/MockAccessController.sol | 17 +- test/foundry/mocks/MockERC20.sol | 14 +- test/foundry/mocks/MockERC721.sol | 8 +- .../MockIncompatibleMetadataProviderV2.sol | 7 +- test/foundry/mocks/MockMetaTxModule.sol | 16 +- test/foundry/mocks/MockMetadataProviderV2.sol | 30 +- test/foundry/mocks/MockModule.sol | 11 +- test/foundry/mocks/MockModuleRegistry.sol | 2 - test/foundry/mocks/MockOrchestratorModule.sol | 10 +- test/foundry/mocks/MockRoyaltyPolicyLS.sol | 6 +- .../MintPaymentPolicyFrameworkManager.sol | 18 +- .../licensing/MockPolicyFrameworkManager.sol | 10 +- test/foundry/modules/ModuleBase.t.sol | 24 +- test/foundry/modules/TaggingModule.t.sol | 7 +- .../modules/dispute/ArbitrationPolicySP.t.sol | 20 +- .../modules/dispute/DisputeModule.t.sol | 37 +- .../modules/licensing/LicensingModule.t.sol | 16 +- .../UMLPolicyFramework.derivation.t.sol | 4 +- .../UMLPolicyFramework.multi-parent.sol | 228 ++- .../licensing/UMLPolicyFramework.t.sol | 32 +- test/foundry/modules/royalty/LSClaimer.t.sol | 20 +- .../modules/royalty/RoyaltyModule.t.sol | 21 +- .../modules/royalty/RoyaltyPolicyLS.t.sol | 65 +- .../registries/metadata/IPAssetRenderer.t.sol | 80 +- .../metadata/MetadataProvider.t.sol | 47 +- test/foundry/resolvers/IPResolver.t.sol | 37 +- test/foundry/resolvers/ResolverBase.t.sol | 5 - test/foundry/utils/BaseTest.sol | 5 +- test/{ => foundry}/utils/DeployHelper.sol | 25 +- test/{ => foundry}/utils/TestHelper.sol | 13 +- tsconfig.json | 4 +- yarn.lock | 1411 ++++------------- 97 files changed, 1162 insertions(+), 2011 deletions(-) create mode 100644 .editorconfig create mode 100755 .husky/pre-push create mode 100644 .solcover.js rename test/{ => foundry}/utils/DeployHelper.sol (87%) rename test/{ => foundry}/utils/TestHelper.sol (94%) diff --git a/.editorconfig b/.editorconfig new file mode 100644 index 00000000..2d2b1621 --- /dev/null +++ b/.editorconfig @@ -0,0 +1,21 @@ +# EditorConfig is awesome: https://EditorConfig.org + +# top-most EditorConfig file +root = true + +[*] +charset = utf-8 +end_of_line = lf +indent_style = space +insert_final_newline = true +trim_trailing_whitespace = false +max_line_length = 120 + +[*.sol] +indent_size = 4 + +[*.{js,ts}] +indent_size = 2 + +[*.{adoc,md}] +max_line_length = 0 \ No newline at end of file diff --git a/.husky/pre-push b/.husky/pre-push new file mode 100755 index 00000000..f44b56b1 --- /dev/null +++ b/.husky/pre-push @@ -0,0 +1,6 @@ +#!/usr/bin/env sh +. "$(dirname -- "$0")/_/husky.sh" + +yarn lint:sol:fix +# recheck +yarn lint:sol \ No newline at end of file diff --git a/.prettierrc b/.prettierrc index ce2b8af1..fe162790 100644 --- a/.prettierrc +++ b/.prettierrc @@ -1,4 +1,5 @@ { + "plugins": ["prettier-plugin-solidity"], "useTabs": false, "printWidth": 120, "trailingComma": "es5", @@ -12,6 +13,12 @@ "options": { "tabWidth": 2 } + }, + { + "files": "*.sol", + "options": { + "singleQuote": false + } } ] } diff --git a/.solcover.js b/.solcover.js new file mode 100644 index 00000000..e0dea5e2 --- /dev/null +++ b/.solcover.js @@ -0,0 +1,13 @@ +module.exports = { + norpc: true, + testCommand: 'npm test', + compileCommand: 'npm run compile', + skipFiles: ['mocks'], + providerOptions: { + default_balance_ether: '10000000000000000000000000', + }, + mocha: { + fgrep: '[skip-on-coverage]', + invert: true, + }, +}; diff --git a/.solhint.json b/.solhint.json index 908ac955..711dd1cc 100644 --- a/.solhint.json +++ b/.solhint.json @@ -3,12 +3,11 @@ "plugins": ["prettier"], "rules": { "code-complexity": ["error", 8], - "compiler-version": ["error", ">=0.8.19"], + "compiler-version": ["error", ">=0.8.23"], "const-name-snakecase": "off", "no-empty-blocks": "off", "constructor-syntax": "error", "func-visibility": ["error", { "ignoreConstructors": true }], - "modifier-name-mixedcase": "error", "max-line-length": ["error", 120], "not-rely-on-time": "off", "reason-string": ["warn", { "maxLength": 64 }], @@ -18,6 +17,9 @@ "avoid-low-level-calls": "off", "no-global-import": "error", "prettier/prettier": "error", - "private-vars-leading-underscore": "off" + "private-vars-leading-underscore": "off", + "func-name-mixedcase": "off", + "var-name-mixedcase": "off", + "modifier-name-mixedcase": "off" } } diff --git a/Makefile b/Makefile index 9e0de95b..1fd53155 100644 --- a/Makefile +++ b/Makefile @@ -43,8 +43,8 @@ format: # generate html report from lcov.info (ignore "line ... has branchcov but no linecov data" error) coverage: mkdir -p coverage - forge coverage --report lcov --fork-url https://rpc.ankr.com/eth --fork-block-number 19042069 - lcov --remove lcov.info -o coverage/lcov.info 'test/*' 'script/*' 'contracts/mocks/*' --rc branch_coverage=1 + forge coverage --report lcov --fork-url https://rpc.ankr.com/eth_sepolia --fork-block-number 5196000 + lcov --remove lcov.info -o coverage/lcov.info 'test/*' 'script/*' --rc branch_coverage=1 genhtml coverage/lcov.info -o coverage --rc branch_coverage=1 --ignore-errors category abi: diff --git a/contracts/AccessController.sol b/contracts/AccessController.sol index 396ba9ec..3267c00d 100644 --- a/contracts/AccessController.sol +++ b/contracts/AccessController.sol @@ -1,6 +1,6 @@ // SPDX-License-Identifier: UNLICENSED // See https://github.com/storyprotocol/protocol-contracts/blob/main/StoryProtocol-AlphaTestingAgreement-17942166.3.pdf -pragma solidity ^0.8.21; +pragma solidity ^0.8.23; import { IModuleRegistry } from "./interfaces/registries/IModuleRegistry.sol"; import { IAccessController } from "./interfaces/IAccessController.sol"; diff --git a/contracts/interfaces/governance/IGovernable.sol b/contracts/interfaces/governance/IGovernable.sol index 73046bae..f9b2b239 100644 --- a/contracts/interfaces/governance/IGovernable.sol +++ b/contracts/interfaces/governance/IGovernable.sol @@ -2,7 +2,6 @@ // See https://github.com/storyprotocol/protocol-contracts/blob/main/StoryProtocol-AlphaTestingAgreement-17942166.3.pdf pragma solidity ^0.8.23; - /// @title IGovernable /// @notice This is the interface for the Lens Protocol main governance functions. interface IGovernable { @@ -13,6 +12,6 @@ interface IGovernable { /// @param newGovernance The address of the new governance function setGovernance(address newGovernance) external; /// @notice Returns the current governance address - /// @return The address of the current governance + /// @return The address of the current governance function getGovernance() external view returns (address); } diff --git a/contracts/interfaces/modules/base/IModule.sol b/contracts/interfaces/modules/base/IModule.sol index b14c9dd2..2ea5b1db 100644 --- a/contracts/interfaces/modules/base/IModule.sol +++ b/contracts/interfaces/modules/base/IModule.sol @@ -4,7 +4,6 @@ pragma solidity ^0.8.23; /// @notice Module Interface interface IModule { - /// @notice Returns the string identifier associated with the module. function name() external returns (string memory); } diff --git a/contracts/interfaces/modules/dispute/IDisputeModule.sol b/contracts/interfaces/modules/dispute/IDisputeModule.sol index 1983c05d..b25ddab6 100644 --- a/contracts/interfaces/modules/dispute/IDisputeModule.sol +++ b/contracts/interfaces/modules/dispute/IDisputeModule.sol @@ -22,7 +22,7 @@ interface IDisputeModule { /// @notice Event emitted when the base arbitration policy is set /// @param arbitrationPolicy The address of the arbitration policy event DefaultArbitrationPolicyUpdated(address arbitrationPolicy); - + /// @notice Event emitted when an arbitration policy is set for an ipId /// @param ipId The ipId address /// @param arbitrationPolicy The address of the arbitration policy @@ -107,7 +107,9 @@ interface IDisputeModule { /// @notice Gets the dispute struct characteristics /// @param disputeId The dispute id - function disputes(uint256 disputeId) + function disputes( + uint256 disputeId + ) external view returns ( @@ -118,4 +120,4 @@ interface IDisputeModule { bytes32 targetTag, // The target tag of the dispute bytes32 currentTag // The current tag of the dispute ); -} \ No newline at end of file +} diff --git a/contracts/interfaces/modules/dispute/policies/IArbitrationPolicy.sol b/contracts/interfaces/modules/dispute/policies/IArbitrationPolicy.sol index ff88ea42..29b6360c 100644 --- a/contracts/interfaces/modules/dispute/policies/IArbitrationPolicy.sol +++ b/contracts/interfaces/modules/dispute/policies/IArbitrationPolicy.sol @@ -8,8 +8,8 @@ interface IArbitrationPolicy { event GovernanceWithdrew(uint256 amount); /// @notice Executes custom logic on raise dispute - /// @param caller Address of the caller - /// @param data The data to raise the dispute + /// @param caller Address of the caller + /// @param data The data to raise the dispute function onRaiseDispute(address caller, bytes calldata data) external; /// @notice Executes custom logic on dispute judgement diff --git a/contracts/interfaces/modules/licensing/ILicensingModule.sol b/contracts/interfaces/modules/licensing/ILicensingModule.sol index d2d7fe49..302c1598 100644 --- a/contracts/interfaces/modules/licensing/ILicensingModule.sol +++ b/contracts/interfaces/modules/licensing/ILicensingModule.sol @@ -83,11 +83,7 @@ interface ILicensingModule is IModule { /// @param childIpId The id of the child IP to be linked /// @param minRoyalty The minimum derivative rev share that the child wants from its descendants. The value is /// overriden by the `derivativesRevShare` value of the linking licenses. - function linkIpToParents( - uint256[] calldata licenseIds, - address childIpId, - uint32 minRoyalty - ) external; + function linkIpToParents(uint256[] calldata licenseIds, address childIpId, uint32 minRoyalty) external; /// /// Getters diff --git a/contracts/interfaces/modules/licensing/IPolicyFrameworkManager.sol b/contracts/interfaces/modules/licensing/IPolicyFrameworkManager.sol index 2309e2d9..66e233e2 100644 --- a/contracts/interfaces/modules/licensing/IPolicyFrameworkManager.sol +++ b/contracts/interfaces/modules/licensing/IPolicyFrameworkManager.sol @@ -1,11 +1,8 @@ // SPDX-License-Identifier: UNLICENSED - pragma solidity ^0.8.23; import { IERC165 } from "@openzeppelin/contracts/interfaces/IERC165.sol"; -import { Licensing } from "../../../lib/Licensing.sol"; - /// @title IPolicyFrameworkManager /// @notice Interface to define a policy framework contract, that will /// register itself into the LicenseRegistry to format policy into the LicenseRegistry diff --git a/contracts/interfaces/modules/licensing/IUMLPolicyFrameworkManager.sol b/contracts/interfaces/modules/licensing/IUMLPolicyFrameworkManager.sol index a441c3e6..e7dfd9cb 100644 --- a/contracts/interfaces/modules/licensing/IUMLPolicyFrameworkManager.sol +++ b/contracts/interfaces/modules/licensing/IUMLPolicyFrameworkManager.sol @@ -1,8 +1,6 @@ // SPDX-License-Identifier: UNLICENSED - pragma solidity ^0.8.23; -import { Licensing } from "../../../lib/Licensing.sol"; import { IPolicyFrameworkManager } from "../../../interfaces/modules/licensing/IPolicyFrameworkManager.sol"; /// @notice Licensing parameters for the UML standard @@ -44,7 +42,8 @@ struct UMLPolicy { /// so we can verify compatibility when inheriting new policies /// @param commercial Whether or not there is a policy that allows commercial use /// @param derivatives Whether or not there is a policy that allows derivatives -/// @param derivativesReciprocal Whether or not there is a policy that requires derivatives to be licensed under the same terms +/// @param derivativesReciprocal Whether or not there is a policy that requires derivatives +/// to be licensed under the same terms /// @param lastPolicyId The last policy ID that was added to the IP /// @param territoriesAcc The last hash of the territories array /// @param distributionChannelsAcc The last hash of the distributionChannels array @@ -70,7 +69,7 @@ interface IUMLPolicyFrameworkManager is IPolicyFrameworkManager { /// @param policyId The ID of the policy to fetch /// @return policy The UMLPolicy struct function getPolicy(uint256 policyId) external view returns (UMLPolicy memory policy); - + /// @notice gets the aggregation data for inherited policies. function getAggregator(address ipId) external view returns (UMLAggregator memory rights); } diff --git a/contracts/interfaces/modules/royalty/IRoyaltyModule.sol b/contracts/interfaces/modules/royalty/IRoyaltyModule.sol index 0c4c9b4d..42dd2d8c 100644 --- a/contracts/interfaces/modules/royalty/IRoyaltyModule.sol +++ b/contracts/interfaces/modules/royalty/IRoyaltyModule.sol @@ -48,7 +48,12 @@ interface IRoyaltyModule is IModule { /// @param royaltyPolicy The address of the royalty policy /// @param parentIpIds The parent ipIds /// @param data The data to initialize the policy - function setRoyaltyPolicy(address ipId, address royaltyPolicy, address[] calldata parentIpIds, bytes calldata data) external; + function setRoyaltyPolicy( + address ipId, + address royaltyPolicy, + address[] calldata parentIpIds, + bytes calldata data + ) external; /// @notice Allows a sender to to pay royalties on behalf of an ipId /// @param receiverIpId The ipId that receives the royalties @@ -56,4 +61,4 @@ interface IRoyaltyModule is IModule { /// @param token The token to use to pay the royalties /// @param amount The amount to pay function payRoyaltyOnBehalf(address receiverIpId, address payerIpId, address token, uint256 amount) external; -} \ No newline at end of file +} diff --git a/contracts/interfaces/modules/royalty/policies/ILSClaimer.sol b/contracts/interfaces/modules/royalty/policies/ILSClaimer.sol index 47946100..a95ca293 100644 --- a/contracts/interfaces/modules/royalty/policies/ILSClaimer.sol +++ b/contracts/interfaces/modules/royalty/policies/ILSClaimer.sol @@ -18,4 +18,4 @@ interface ILSClaimer { /// @param withdrawETH Indicates if the claimer wants to withdraw ETH /// @param tokens The ERC20 tokens to withdraw function claim(address[] calldata path, address claimerIpId, bool withdrawETH, ERC20[] calldata tokens) external; -} \ No newline at end of file +} diff --git a/contracts/interfaces/modules/royalty/policies/ILiquidSplitClone.sol b/contracts/interfaces/modules/royalty/policies/ILiquidSplitClone.sol index 61cff364..21cd532d 100644 --- a/contracts/interfaces/modules/royalty/policies/ILiquidSplitClone.sol +++ b/contracts/interfaces/modules/royalty/policies/ILiquidSplitClone.sol @@ -6,7 +6,7 @@ interface ILiquidSplitClone { /// @notice Distributes funds to the accounts in the LiquidSplitClone contract /// @param token The token to distribute /// @param accounts The accounts to distribute to - /// @param distributorAddress The distributor address + /// @param distributorAddress The distributor address function distributeFunds(address token, address[] calldata accounts, address distributorAddress) external; /// @notice Transfers rnft tokens @@ -15,13 +15,7 @@ interface ILiquidSplitClone { /// @param id The token id /// @param amount The amount to transfer /// @param data Custom data - function safeTransferFrom( - address from, - address to, - uint256 id, - uint256 amount, - bytes calldata data - ) external; + function safeTransferFrom(address from, address to, uint256 id, uint256 amount, bytes calldata data) external; function balanceOf(address account, uint256 id) external view returns (uint256); -} \ No newline at end of file +} diff --git a/contracts/interfaces/modules/royalty/policies/ILiquidSplitFactory.sol b/contracts/interfaces/modules/royalty/policies/ILiquidSplitFactory.sol index da9a630b..d9647e64 100644 --- a/contracts/interfaces/modules/royalty/policies/ILiquidSplitFactory.sol +++ b/contracts/interfaces/modules/royalty/policies/ILiquidSplitFactory.sol @@ -5,13 +5,13 @@ pragma solidity ^0.8.23; interface ILiquidSplitFactory { /// @notice Creates a new LiquidSplitClone contract /// @param accounts The accounts to initialize the LiquidSplitClone contract with - /// @param initAllocations The initial allocations + /// @param initAllocations The initial allocations /// @param _distributorFee The distributor fee - /// @param owner The owner of the LiquidSplitClone contract + /// @param owner The owner of the LiquidSplitClone contract function createLiquidSplitClone( address[] calldata accounts, uint32[] calldata initAllocations, uint32 _distributorFee, address owner ) external returns (address); -} \ No newline at end of file +} diff --git a/contracts/interfaces/modules/royalty/policies/ILiquidSplitMain.sol b/contracts/interfaces/modules/royalty/policies/ILiquidSplitMain.sol index 5e89b83c..7723e1f0 100644 --- a/contracts/interfaces/modules/royalty/policies/ILiquidSplitMain.sol +++ b/contracts/interfaces/modules/royalty/policies/ILiquidSplitMain.sol @@ -1,7 +1,7 @@ // SPDX-License-Identifier: UNLICENSED pragma solidity ^0.8.23; -import {ERC20} from "@openzeppelin/contracts/token/ERC20/ERC20.sol"; +import { ERC20 } from "@openzeppelin/contracts/token/ERC20/ERC20.sol"; /// @title LiquidSplitMain interface interface ILiquidSplitMain { @@ -9,11 +9,7 @@ interface ILiquidSplitMain { /// @param account The account to withdraw from /// @param withdrawETH The amount of ETH to withdraw /// @param tokens The tokens to withdraw - function withdraw( - address account, - uint256 withdrawETH, - ERC20[] calldata tokens - ) external; + function withdraw(address account, uint256 withdrawETH, ERC20[] calldata tokens) external; /// @notice Gets the ETH balance of an account /// @param account The account to get the ETH balance of @@ -23,4 +19,4 @@ interface ILiquidSplitMain { /// @param account The account to get the ERC20 balance of /// @param token The token to get the balance of function getERC20Balance(address account, ERC20 token) external view returns (uint256); -} \ No newline at end of file +} diff --git a/contracts/interfaces/modules/royalty/policies/IRoyaltyPolicy.sol b/contracts/interfaces/modules/royalty/policies/IRoyaltyPolicy.sol index ed259764..8da9a1e8 100644 --- a/contracts/interfaces/modules/royalty/policies/IRoyaltyPolicy.sol +++ b/contracts/interfaces/modules/royalty/policies/IRoyaltyPolicy.sol @@ -2,7 +2,7 @@ pragma solidity ^0.8.23; /// @title RoyaltyPolicy interface -interface IRoyaltyPolicy { +interface IRoyaltyPolicy { /// @notice Initializes the royalty policy /// @param ipId The ipId /// @param parentsIpIds The parent ipIds @@ -19,4 +19,4 @@ interface IRoyaltyPolicy { /// @notice Returns the minimum royalty the IPAccount expects from descendants /// @param ipId The ipId function minRoyaltyFromDescendants(address ipId) external view returns (uint32); -} \ No newline at end of file +} diff --git a/contracts/interfaces/modules/royalty/policies/IRoyaltyPolicyLS.sol b/contracts/interfaces/modules/royalty/policies/IRoyaltyPolicyLS.sol index 4a7fa7e2..fc2c76a3 100644 --- a/contracts/interfaces/modules/royalty/policies/IRoyaltyPolicyLS.sol +++ b/contracts/interfaces/modules/royalty/policies/IRoyaltyPolicyLS.sol @@ -13,7 +13,9 @@ interface IRoyaltyPolicyLS is IRoyaltyPolicy { /// claimer The claimer address /// royaltyStack The royalty stack /// minRoyalty The min royalty - function royaltyData(address ipId) external view returns (address splitClone, address claimer, uint32 royaltyStack, uint32 minRoyalty); + function royaltyData( + address ipId + ) external view returns (address splitClone, address claimer, uint32 royaltyStack, uint32 minRoyalty); /// @notice Distributes funds to the accounts in the LiquidSplitClone contract /// @param ipId The ipId diff --git a/contracts/interfaces/registries/IIPAccountRegistry.sol b/contracts/interfaces/registries/IIPAccountRegistry.sol index bad40079..d6bc8d0d 100644 --- a/contracts/interfaces/registries/IIPAccountRegistry.sol +++ b/contracts/interfaces/registries/IIPAccountRegistry.sol @@ -24,24 +24,15 @@ interface IIPAccountRegistry { /// @param chainId_ The chain ID where the token contract deployed /// @param tokenContract_ The address of the token contract to be associated with the IP Account /// @param tokenId_ The ID of the token to be associated with the IP Account - /// @return The address of the newly created IP Account - function registerIpAccount( - uint256 chainId_, - address tokenContract_, - uint256 tokenId_ - ) external returns (address); + /// @return The address of the newly created IP Account + function registerIpAccount(uint256 chainId_, address tokenContract_, uint256 tokenId_) external returns (address); /// @notice Returns the IPAccount address for the given NFT token /// @param chainId_ The chain ID where the token contract deployed /// @param tokenContract_ The address of the token contract associated with the IP Account /// @param tokenId_ The ID of the token associated with the IP Account /// @return The address of the IP Account associated with the given NFT token - function ipAccount( - uint256 chainId_, - address tokenContract_, - uint256 tokenId_ - ) external view returns (address); - + function ipAccount(uint256 chainId_, address tokenContract_, uint256 tokenId_) external view returns (address); /// @notice Returns the IPAccount implementation address /// @return The address of the IPAccount implementation diff --git a/contracts/interfaces/registries/IIPAssetRegistry.sol b/contracts/interfaces/registries/IIPAssetRegistry.sol index 3092937c..5d377202 100644 --- a/contracts/interfaces/registries/IIPAssetRegistry.sol +++ b/contracts/interfaces/registries/IIPAssetRegistry.sol @@ -3,7 +3,6 @@ pragma solidity ^0.8.23; import { IIPAccountRegistry } from "./IIPAccountRegistry.sol"; -import { IMetadataProvider } from "./metadata/IMetadataProvider.sol"; /// @title Interface for IP Account Registry /// @notice This interface manages the registration and tracking of IP Accounts @@ -35,11 +34,7 @@ interface IIPAssetRegistry is IIPAccountRegistry { /// @param ipId The canonical identifier of the specified IP. /// @param metadataProvider Address of the metadata provider associated with the IP. /// @param metadata The canonical metadata in bytes associated with the IP. - event MetadataSet( - address indexed ipId, - address indexed metadataProvider, - bytes metadata - ); + event MetadataSet(address indexed ipId, address indexed metadataProvider, bytes metadata); /// @notice Upgrades the metadata for an IP asset, migrating to a new provider. /// @param id The canonical ID of the IP. @@ -103,5 +98,4 @@ interface IIPAssetRegistry is IIPAccountRegistry { /// @param id The canonical identifier for the IP. /// @return The metadata that was bound to this IP at creation time. function metadata(address id) external view returns (bytes memory); - } diff --git a/contracts/interfaces/registries/ILicenseRegistry.sol b/contracts/interfaces/registries/ILicenseRegistry.sol index 82273a3b..1c8ae788 100644 --- a/contracts/interfaces/registries/ILicenseRegistry.sol +++ b/contracts/interfaces/registries/ILicenseRegistry.sol @@ -55,7 +55,7 @@ interface ILicenseRegistry { /// @notice True if holder is the licensee for the license (owner of the license NFT), or derivative IP owner if /// the license was added to the IP by linking (burning a license) function isLicensee(uint256 licenseId, address holder) external view returns (bool); - + /// @notice IP ID of the licensor for the license (parent IP) function licensorIpId(uint256 licenseId) external view returns (address); diff --git a/contracts/interfaces/registries/metadata/IMetadataProviderMigratable.sol b/contracts/interfaces/registries/metadata/IMetadataProviderMigratable.sol index 76fc7bc5..c283d92e 100644 --- a/contracts/interfaces/registries/metadata/IMetadataProviderMigratable.sol +++ b/contracts/interfaces/registries/metadata/IMetadataProviderMigratable.sol @@ -8,7 +8,7 @@ import { IMetadataProvider } from "./IMetadataProvider.sol"; interface IMetadataProviderMigratable is IMetadataProvider { /// @notice Returns the new metadata provider IP assets may migrate to. /// @return Address of the new metadata provider if set, else the zero address. - function upgradeProvider() external returns(IMetadataProvider); + function upgradeProvider() external returns (IMetadataProvider); /// @notice Sets a new metadata provider that IP assets may migrate to. /// @param provider The address of the new metadata provider. diff --git a/contracts/interfaces/registries/metadata/IMetadataProviderV1.sol b/contracts/interfaces/registries/metadata/IMetadataProviderV1.sol index 1ac8f4ee..0b826c0b 100644 --- a/contracts/interfaces/registries/metadata/IMetadataProviderV1.sol +++ b/contracts/interfaces/registries/metadata/IMetadataProviderV1.sol @@ -7,7 +7,6 @@ import { IMetadataProvider } from "./IMetadataProvider.sol"; /// @title Metadata Provider v1 Interface interface IMetadataProviderV1 is IMetadataProvider { - /// @notice Fetches the metadata linked to an IP asset. /// @param ipId The address identifier of the IP asset. function metadata(address ipId) external view returns (IP.MetadataV1 memory); diff --git a/contracts/interfaces/resolvers/IKeyValueResolver.sol b/contracts/interfaces/resolvers/IKeyValueResolver.sol index eeb80c84..637dd327 100644 --- a/contracts/interfaces/resolvers/IKeyValueResolver.sol +++ b/contracts/interfaces/resolvers/IKeyValueResolver.sol @@ -4,17 +4,9 @@ pragma solidity ^0.8.23; /// @title Key Value Resolver Interface interface IKeyValueResolver { - /// @notice Emits when a new key-value pair is set for the resolver. - event KeyValueSet( - address indexed ipId, - string indexed key, - string value - ); + event KeyValueSet(address indexed ipId, string indexed key, string value); /// @notice Retrieves the string value associated with a key for an IP asset. - function value( - address ipId, - string calldata key - ) external view returns (string memory); + function value(address ipId, string calldata key) external view returns (string memory); } diff --git a/contracts/interfaces/resolvers/IResolver.sol b/contracts/interfaces/resolvers/IResolver.sol index fcf880be..dbb760da 100644 --- a/contracts/interfaces/resolvers/IResolver.sol +++ b/contracts/interfaces/resolvers/IResolver.sol @@ -6,8 +6,6 @@ import { IModule } from "contracts/interfaces/modules/base/IModule.sol"; /// @notice Resolver Interface interface IResolver is IModule { - /// @notice Checks whether the resolver IP interface is supported. - function supportsInterface(bytes4 id) view external returns (bool); - + function supportsInterface(bytes4 id) external view returns (bool); } diff --git a/contracts/lib/AccessPermission.sol b/contracts/lib/AccessPermission.sol index cbb5766f..ca18d344 100644 --- a/contracts/lib/AccessPermission.sol +++ b/contracts/lib/AccessPermission.sol @@ -1,6 +1,6 @@ // SPDX-License-Identifier: UNLICENSED // See https://github.com/storyprotocol/protocol-contracts/blob/main/StoryProtocol-AlphaTestingAgreement-17942166.3.pdf -pragma solidity ^0.8.21; +pragma solidity ^0.8.23; /// @title Access Permission Library /// @notice Library for IPAccount access control permissions. diff --git a/contracts/lib/Errors.sol b/contracts/lib/Errors.sol index f6b7626b..0f93daf1 100644 --- a/contracts/lib/Errors.sol +++ b/contracts/lib/Errors.sol @@ -1,6 +1,6 @@ // SPDX-License-Identifier: UNLICENSED // See https://github.com/storyprotocol/protocol-contracts/blob/main/StoryProtocol-AlphaTestingAgreement-17942166.3.pdf -pragma solidity ^0.8.19; +pragma solidity ^0.8.23; /// @title Errors Library /// @notice Library for all Story Protocol contract errors. diff --git a/contracts/lib/Licensing.sol b/contracts/lib/Licensing.sol index 67476ec1..30bcdca8 100644 --- a/contracts/lib/Licensing.sol +++ b/contracts/lib/Licensing.sol @@ -1,6 +1,5 @@ // SPDX-License-Identifier: UNLICENSED - -pragma solidity ^0.8.20; +pragma solidity ^0.8.23; /// @title Licensing /// @notice Types and constants used by the licensing related contracts diff --git a/contracts/lib/MetaTx.sol b/contracts/lib/MetaTx.sol index 8c8d9504..92a4a724 100644 --- a/contracts/lib/MetaTx.sol +++ b/contracts/lib/MetaTx.sol @@ -6,14 +6,15 @@ pragma solidity ^0.8.23; /// @dev This library provides functions for handling meta transactions in the Story Protocol. library MetaTx { /// @dev Version of the EIP712 domain. - string constant EIP712_DOMAIN_VERSION = "1"; + string public constant EIP712_DOMAIN_VERSION = "1"; /// @dev Hash of the EIP712 domain version. - bytes32 constant EIP712_DOMAIN_VERSION_HASH = keccak256(bytes(EIP712_DOMAIN_VERSION)); + bytes32 public constant EIP712_DOMAIN_VERSION_HASH = keccak256(bytes(EIP712_DOMAIN_VERSION)); /// @dev EIP712 domain type hash. - bytes32 constant EIP712_DOMAIN = + bytes32 public constant EIP712_DOMAIN = keccak256("EIP712Domain(string name,string version,uint256 chainId,address verifyingContract)"); /// @dev Execute type hash. - bytes32 constant EXECUTE = keccak256("Execute(address to,uint256 value,bytes data,uint256 nonce,uint256 deadline)"); + bytes32 public constant EXECUTE = + keccak256("Execute(address to,uint256 value,bytes data,uint256 nonce,uint256 deadline)"); /// @dev Structure for the Execute type. struct Execute { diff --git a/contracts/lib/registries/IPAccountChecker.sol b/contracts/lib/registries/IPAccountChecker.sol index 42cc8705..d7639c25 100644 --- a/contracts/lib/registries/IPAccountChecker.sol +++ b/contracts/lib/registries/IPAccountChecker.sol @@ -1,6 +1,6 @@ // SPDX-License-Identifier: UNLICENSED // See https://github.com/storyprotocol/protocol-contracts/blob/main/StoryProtocol-AlphaTestingAgreement-17942166.3.pdf -pragma solidity ^0.8.21; +pragma solidity ^0.8.23; import { ERC165Checker } from "@openzeppelin/contracts/utils/introspection/ERC165Checker.sol"; import { IERC6551Account } from "@erc6551/interfaces/IERC6551Account.sol"; diff --git a/contracts/modules/dispute-module/DisputeModule.sol b/contracts/modules/dispute-module/DisputeModule.sol index 62ba4e2f..495a1d5f 100644 --- a/contracts/modules/dispute-module/DisputeModule.sol +++ b/contracts/modules/dispute-module/DisputeModule.sol @@ -15,7 +15,6 @@ import { ShortStringOps } from "../../utils/ShortStringOps.sol"; /// @notice The Story Protocol dispute module acts as an enforcement layer for /// that allows to raise disputes and resolve them through arbitration. contract DisputeModule is IDisputeModule, BaseModule, Governable, ReentrancyGuard { - /// @notice tag to represent the dispute is in dispute state waiting for judgement bytes32 public constant IN_DISPUTE = bytes32("IN_DISPUTE"); @@ -45,8 +44,8 @@ contract DisputeModule is IDisputeModule, BaseModule, Governable, ReentrancyGuar mapping(address arbitrationPolicy => bool allowed) public isWhitelistedArbitrationPolicy; /// @notice Indicates if an arbitration relayer is whitelisted for a given arbitration policy - mapping(address arbitrationPolicy => mapping(address arbitrationRelayer => bool allowed)) public - isWhitelistedArbitrationRelayer; + mapping(address arbitrationPolicy => mapping(address arbitrationRelayer => bool allowed)) + public isWhitelistedArbitrationRelayer; /// @notice Arbitration policy for a given ipId mapping(address ipId => address arbitrationPolicy) public arbitrationPolicies; @@ -87,10 +86,11 @@ contract DisputeModule is IDisputeModule, BaseModule, Governable, ReentrancyGuar /// @param _arbitrationPolicy The address of the arbitration policy /// @param _arbPolicyRelayer The address of the arbitration relayer /// @param _allowed Indicates if the arbitration relayer is whitelisted or not - function whitelistArbitrationRelayer(address _arbitrationPolicy, address _arbPolicyRelayer, bool _allowed) - external - onlyProtocolAdmin - { + function whitelistArbitrationRelayer( + address _arbitrationPolicy, + address _arbPolicyRelayer, + bool _allowed + ) external onlyProtocolAdmin { if (_arbitrationPolicy == address(0)) revert Errors.DisputeModule__ZeroArbitrationPolicy(); if (_arbPolicyRelayer == address(0)) revert Errors.DisputeModule__ZeroArbitrationRelayer(); @@ -102,7 +102,8 @@ contract DisputeModule is IDisputeModule, BaseModule, Governable, ReentrancyGuar /// @notice Sets the base arbitration policy /// @param _arbitrationPolicy The address of the arbitration policy function setBaseArbitrationPolicy(address _arbitrationPolicy) external onlyProtocolAdmin { - if (!isWhitelistedArbitrationPolicy[_arbitrationPolicy]) revert Errors.DisputeModule__NotWhitelistedArbitrationPolicy(); + if (!isWhitelistedArbitrationPolicy[_arbitrationPolicy]) + revert Errors.DisputeModule__NotWhitelistedArbitrationPolicy(); baseArbitrationPolicy = _arbitrationPolicy; @@ -113,7 +114,8 @@ contract DisputeModule is IDisputeModule, BaseModule, Governable, ReentrancyGuar /// @param _ipId The ipId /// @param _arbitrationPolicy The address of the arbitration policy function setArbitrationPolicy(address _ipId, address _arbitrationPolicy) external verifyPermission(_ipId) { - if (!isWhitelistedArbitrationPolicy[_arbitrationPolicy]) revert Errors.DisputeModule__NotWhitelistedArbitrationPolicy(); + if (!isWhitelistedArbitrationPolicy[_arbitrationPolicy]) + revert Errors.DisputeModule__NotWhitelistedArbitrationPolicy(); arbitrationPolicies[_ipId] = _arbitrationPolicy; @@ -155,7 +157,13 @@ contract DisputeModule is IDisputeModule, BaseModule, Governable, ReentrancyGuar IArbitrationPolicy(arbitrationPolicy).onRaiseDispute(msg.sender, _data); emit DisputeRaised( - disputeId_, _targetIpId, msg.sender, arbitrationPolicy, linkToDisputeEvidence, _targetTag, _data + disputeId_, + _targetIpId, + msg.sender, + arbitrationPolicy, + linkToDisputeEvidence, + _targetTag, + _data ); return disputeId_; diff --git a/contracts/modules/dispute-module/policies/ArbitrationPolicySP.sol b/contracts/modules/dispute-module/policies/ArbitrationPolicySP.sol index b070e4b2..afbfe0e9 100644 --- a/contracts/modules/dispute-module/policies/ArbitrationPolicySP.sol +++ b/contracts/modules/dispute-module/policies/ArbitrationPolicySP.sol @@ -37,7 +37,12 @@ contract ArbitrationPolicySP is IArbitrationPolicy, Governable { /// @param _paymentToken Address of the payment token /// @param _arbitrationPrice Arbitration price /// @param _governable Address of the governable contract - constructor(address _disputeModule, address _paymentToken, uint256 _arbitrationPrice, address _governable) Governable(_governable) { + constructor( + address _disputeModule, + address _paymentToken, + uint256 _arbitrationPrice, + address _governable + ) Governable(_governable) { if (_disputeModule == address(0)) revert Errors.ArbitrationPolicySP__ZeroDisputeModule(); if (_paymentToken == address(0)) revert Errors.ArbitrationPolicySP__ZeroPaymentToken(); @@ -58,7 +63,7 @@ contract ArbitrationPolicySP is IArbitrationPolicy, Governable { /// @param _decision The decision of the dispute function onDisputeJudgement(uint256 _disputeId, bool _decision, bytes calldata) external onlyDisputeModule { if (_decision) { - (, address disputeInitiator,,,,) = IDisputeModule(DISPUTE_MODULE).disputes(_disputeId); + (, address disputeInitiator, , , , ) = IDisputeModule(DISPUTE_MODULE).disputes(_disputeId); IERC20(PAYMENT_TOKEN).safeTransfer(disputeInitiator, ARBITRATION_PRICE); } } diff --git a/contracts/modules/licensing/BasePolicyFrameworkManager.sol b/contracts/modules/licensing/BasePolicyFrameworkManager.sol index e20de229..8d9afe64 100644 --- a/contracts/modules/licensing/BasePolicyFrameworkManager.sol +++ b/contracts/modules/licensing/BasePolicyFrameworkManager.sol @@ -2,20 +2,16 @@ // See https://github.com/storyprotocol/protocol-contracts/blob/main/StoryProtocol-AlphaTestingAgreement-17942166.3.pdf pragma solidity ^0.8.23; -// contracts -import { IPolicyFrameworkManager } from "../../interfaces/modules/licensing/IPolicyFrameworkManager.sol"; -import { Licensing } from "../../lib/Licensing.sol"; -import { Errors } from "../../lib/Errors.sol"; -import { LicensingModuleAware } from "../../modules/licensing/LicensingModuleAware.sol"; - // external import { ERC165 } from "@openzeppelin/contracts/utils/introspection/ERC165.sol"; import { IERC165 } from "@openzeppelin/contracts/utils/introspection/IERC165.sol"; +// contracts +import { IPolicyFrameworkManager } from "../../interfaces/modules/licensing/IPolicyFrameworkManager.sol"; +import { LicensingModuleAware } from "../../modules/licensing/LicensingModuleAware.sol"; /// @title BasePolicyFrameworkManager /// @notice Base contract for policy framework managers. abstract contract BasePolicyFrameworkManager is IPolicyFrameworkManager, ERC165, LicensingModuleAware { - string public override name; string public override licenseTextUrl; diff --git a/contracts/modules/licensing/LicensingModule.sol b/contracts/modules/licensing/LicensingModule.sol index 01864c1c..c30c3bbd 100644 --- a/contracts/modules/licensing/LicensingModule.sol +++ b/contracts/modules/licensing/LicensingModule.sol @@ -103,7 +103,7 @@ contract LicensingModule is AccessControlled, ILicensingModule { IPolicyFrameworkManager pfm = IPolicyFrameworkManager(policy(polId).policyFramework); bool isPolicyCommercial = pfm.isPolicyCommercial(polId); - // If the IPAccount has mutable royalty policy setting and the added policy is commercial, the IPAccount + // If the IPAccount has mutable royalty policy setting and the added policy is commercial, the IPAccount // can change its royalty policy. This mutability will be set to false in two cases: // 1. `mintLicense`: when a child mints a license on a policy, it will lock in the value defined in that policy. // 2. `linkIpToParents`: when a child links to parents, it will lock in the value defined in the policies. @@ -160,6 +160,7 @@ contract LicensingModule is AccessControlled, ILicensingModule { /// @param amount of licenses to be minted. License NFT is fungible for same policy and same licensors /// @param receiver of the License NFT(s). /// @return licenseId of the NFT(s). + // solhint-disable-next-line code-complexity function mintLicense( uint256 policyId, address licensorIp, @@ -202,7 +203,7 @@ contract LicensingModule is AccessControlled, ILicensingModule { abi.encode(commercialRevenueShare) // new minRoyaty ); } else { - // If the royalty policy is immutable, we allow minting license on a private policy if and only + // If the royalty policy is immutable, we allow minting license on a private policy if and only // if this policyId's royalty policy and min royalty is the same as the current setting. uint256 minRoyalty = ROYALTY_MODULE.minRoyaltyFromDescendants(licensorIp); if (commercialRevenueShare != minRoyalty) { @@ -291,12 +292,7 @@ contract LicensingModule is AccessControlled, ILicensingModule { // If the parent licenses specify the `derivativeRevShare` value to non-zero, use the value. // Otherwise, the child IPAccount has the freedom to set the value. uint256 dRevShare = royaltyDerivativeRevShare > 0 ? royaltyDerivativeRevShare : minRoyalty; - ROYALTY_MODULE.setRoyaltyPolicy( - childIpId, - royaltyPolicyAddress, - licensors, - abi.encode(dRevShare) - ); + ROYALTY_MODULE.setRoyaltyPolicy(childIpId, royaltyPolicyAddress, licensors, abi.encode(dRevShare)); } // Burn licenses @@ -312,11 +308,14 @@ contract LicensingModule is AccessControlled, ILicensingModule { address royaltyPolicyAddress, uint32 royaltyDerivativeRevShare, uint32 derivativeRevShareSum - ) private returns ( - address nextRoyaltyPolicyAddress, - uint32 nextRoyaltyDerivativeRevShare, - uint32 nextDerivativeRevShareSum - ) { + ) + private + returns ( + address nextRoyaltyPolicyAddress, + uint32 nextRoyaltyDerivativeRevShare, + uint32 nextDerivativeRevShareSum + ) + { // TODO: check licensor not part of a branch tagged by disputer if (licensor == childIpId) { revert Errors.LicensingModule__ParentIdEqualThanChild(); @@ -338,8 +337,8 @@ contract LicensingModule is AccessControlled, ILicensingModule { // If link says royalty is required for license (licenseIds[i]) and no royalty policy is set, set it. // But if the index is NOT 0, this is previous licenses didn't set the royalty policy because they don't - // require royalty payment. So, revert in this case. Similarly, if the new royaltyPolicyAddress is different - // from the previous one (in iteration > 0), revert. We currently restrict all licenses (parents) to have + // require royalty payment. So, revert in this case. Similarly, if the new royaltyPolicyAddress is different + // from the previous one (in iteration > 0), revert. We currently restrict all licenses (parents) to have // the same royalty policy, so the child can inherit it. if (response.isRoyaltyRequired) { if (iteration > 0 && royaltyPolicyAddress != response.royaltyPolicy) { diff --git a/contracts/modules/licensing/UMLPolicyFrameworkManager.sol b/contracts/modules/licensing/UMLPolicyFrameworkManager.sol index 4518edee..8f9c0306 100644 --- a/contracts/modules/licensing/UMLPolicyFrameworkManager.sol +++ b/contracts/modules/licensing/UMLPolicyFrameworkManager.sol @@ -5,14 +5,13 @@ pragma solidity ^0.8.23; // external import { Base64 } from "@openzeppelin/contracts/utils/Base64.sol"; import { Strings } from "@openzeppelin/contracts/utils/Strings.sol"; -import { IERC165 } from "@openzeppelin/contracts/utils/introspection/ERC165.sol"; // contracts -import { ShortStringOps } from "../../utils/ShortStringOps.sol"; import { ILicensingModule } from "../../interfaces/modules/licensing/ILicensingModule.sol"; import { Licensing } from "../../lib/Licensing.sol"; import { Errors } from "../../lib/Errors.sol"; import { UMLFrameworkErrors } from "../../lib/UMLFrameworkErrors.sol"; +// solhint-disable-next-line max-line-length import { IUMLPolicyFrameworkManager, UMLPolicy, UMLAggregator } from "../../interfaces/modules/licensing/IUMLPolicyFrameworkManager.sol"; import { IPolicyFrameworkManager } from "../../interfaces/modules/licensing/IPolicyFrameworkManager.sol"; import { BasePolicyFrameworkManager } from "../../modules/licensing/BasePolicyFrameworkManager.sol"; @@ -22,11 +21,7 @@ import { LicensorApprovalChecker } from "../../modules/licensing/parameter-helpe /// @notice This is the UML Policy Framework Manager, which implements the UML Policy Framework /// logic for encoding and decoding UML policies into the LicenseRegistry and verifying /// the licensing parameters for linking, minting, and transferring. -contract UMLPolicyFrameworkManager is - IUMLPolicyFrameworkManager, - BasePolicyFrameworkManager, - LicensorApprovalChecker -{ +contract UMLPolicyFrameworkManager is IUMLPolicyFrameworkManager, BasePolicyFrameworkManager, LicensorApprovalChecker { bytes32 private constant _EMPTY_STRING_ARRAY_HASH = 0x569e75fc77c1a856f6daaf9e69d8a9566ca34aa47f9133711ce065a571af0cfd; @@ -39,9 +34,7 @@ contract UMLPolicyFrameworkManager is ) BasePolicyFrameworkManager(licensing, name_, licenseUrl_) LicensorApprovalChecker(accessController, ipAccountRegistry, ILicensingModule(licensing).licenseRegistry()) - { - } - + {} /// @notice Re a new policy to the registry /// @dev Must encode the policy into bytes to be stored in the LicensingModule @@ -109,7 +102,6 @@ contract UMLPolicyFrameworkManager is return true; } - /// @notice Fetchs a policy from the registry, decoding the raw bytes into a UMLPolicy struct /// @param policyId The ID of the policy to fetch /// @return policy The UMLPolicy struct @@ -150,6 +142,7 @@ contract UMLPolicyFrameworkManager is /// @param policy the policy to inherit /// @return changedAgg true if the aggregator was changed /// @return newAggregator the new aggregator + // solhint-disable-next-line code-complexity function processInheritedPolicies( bytes memory aggregator, uint256 policyId, diff --git a/contracts/modules/licensing/parameter-helpers/LicensorApprovalChecker.sol b/contracts/modules/licensing/parameter-helpers/LicensorApprovalChecker.sol index 09e93eb3..11da528d 100644 --- a/contracts/modules/licensing/parameter-helpers/LicensorApprovalChecker.sol +++ b/contracts/modules/licensing/parameter-helpers/LicensorApprovalChecker.sol @@ -1,9 +1,6 @@ -// // SPDX-License-Identifier: UNLICENSED - +// SPDX-License-Identifier: UNLICENSED pragma solidity ^0.8.23; -import { Errors } from "../../../lib/Errors.sol"; -import { IAccessController } from "../../../interfaces/IAccessController.sol"; import { AccessControlled } from "../../../access/AccessControlled.sol"; import { ILicenseRegistry } from "../../../interfaces/registries/ILicenseRegistry.sol"; diff --git a/contracts/modules/royalty-module/RoyaltyModule.sol b/contracts/modules/royalty-module/RoyaltyModule.sol index f21c9713..97d38607 100644 --- a/contracts/modules/royalty-module/RoyaltyModule.sol +++ b/contracts/modules/royalty-module/RoyaltyModule.sol @@ -13,7 +13,6 @@ import { ROYALTY_MODULE_KEY } from "../../lib/modules/Module.sol"; /// @notice The Story Protocol royalty module allows to set royalty policies an ipId /// and pay royalties as a derivative ip. contract RoyaltyModule is IRoyaltyModule, Governable, ReentrancyGuard { - string public constant override name = ROYALTY_MODULE_KEY; /// @notice Licensing module address @@ -29,7 +28,7 @@ contract RoyaltyModule is IRoyaltyModule, Governable, ReentrancyGuard { mapping(address ipId => address royaltyPolicy) public royaltyPolicies; /// @notice Indicates if a royalty policy is immutable - mapping(address ipId => bool) public isRoyaltyPolicyImmutable; + mapping(address ipId => bool) public isRoyaltyPolicyImmutable; /// @notice Constructor /// @param _governance The address of the governance contract @@ -70,7 +69,8 @@ contract RoyaltyModule is IRoyaltyModule, Governable, ReentrancyGuard { emit RoyaltyTokenWhitelistUpdated(_token, _allowed); } - // TODO: Ensure that the ipId that is passed in from license cannot be manipulated - given ipId addresses are deterministic + // TODO: Ensure that the ipId that is passed in from license cannot be manipulated + // - given ipId addresses are deterministic /// @notice Sets the royalty policy for an ipId /// @param _ipId The ipId /// @param _royaltyPolicy The address of the royalty policy @@ -89,7 +89,8 @@ contract RoyaltyModule is IRoyaltyModule, Governable, ReentrancyGuard { // the loop below is limited to 100 iterations for (uint32 i = 0; i < _parentIpIds.length; i++) { - if (royaltyPolicies[_parentIpIds[i]] != _royaltyPolicy) revert Errors.RoyaltyModule__IncompatibleRoyaltyPolicy(); + if (royaltyPolicies[_parentIpIds[i]] != _royaltyPolicy) + revert Errors.RoyaltyModule__IncompatibleRoyaltyPolicy(); isRoyaltyPolicyImmutable[_parentIpIds[i]] = true; } @@ -116,7 +117,12 @@ contract RoyaltyModule is IRoyaltyModule, Governable, ReentrancyGuard { /// @param _payerIpId The ipId that pays the royalties /// @param _token The token to use to pay the royalties /// @param _amount The amount to pay - function payRoyaltyOnBehalf(address _receiverIpId, address _payerIpId, address _token, uint256 _amount) external nonReentrant { + function payRoyaltyOnBehalf( + address _receiverIpId, + address _payerIpId, + address _token, + uint256 _amount + ) external nonReentrant { address royaltyPolicy = royaltyPolicies[_receiverIpId]; if (royaltyPolicy == address(0)) revert Errors.RoyaltyModule__NoRoyaltyPolicySet(); if (!isWhitelistedRoyaltyToken[_token]) revert Errors.RoyaltyModule__NotWhitelistedRoyaltyToken(); diff --git a/contracts/modules/royalty-module/policies/LSClaimer.sol b/contracts/modules/royalty-module/policies/LSClaimer.sol index 735fe860..58132f2f 100644 --- a/contracts/modules/royalty-module/policies/LSClaimer.sol +++ b/contracts/modules/royalty-module/policies/LSClaimer.sol @@ -51,7 +51,12 @@ contract LSClaimer is ILSClaimer, ERC1155Holder, ReentrancyGuard { /// @param _claimerIpId The ipId of the claimer /// @param _withdrawETH Indicates if the claimer wants to withdraw ETH /// @param _tokens The ERC20 tokens to withdraw - function claim(address[] calldata _path, address _claimerIpId, bool _withdrawETH, ERC20[] calldata _tokens) external nonReentrant { + function claim( + address[] calldata _path, + address _claimerIpId, + bool _withdrawETH, + ERC20[] calldata _tokens + ) external nonReentrant { bytes32 pathHash = keccak256(abi.encodePacked(_path)); if (claimedPaths[pathHash]) revert Errors.LSClaimer__AlreadyClaimed(); @@ -61,11 +66,11 @@ contract LSClaimer is ILSClaimer, ERC1155Holder, ReentrancyGuard { _checkIfPathIsValid(_path); // claim rnfts - (address rnftAddr,,,) = IROYALTY_POLICY_LS.royaltyData(IP_ID); + (address rnftAddr, , , ) = IROYALTY_POLICY_LS.royaltyData(IP_ID); ILiquidSplitClone rnft = ILiquidSplitClone(rnftAddr); uint256 totalUnclaimedRnfts = rnft.balanceOf(address(this), 0); - (address claimerSplitClone,,,uint32 rnftClaimAmount) = IROYALTY_POLICY_LS.royaltyData(_claimerIpId); - rnft.safeTransferFrom(address(this), claimerSplitClone, 0, rnftClaimAmount, ""); + (address claimerSplitClone, , , uint32 rnftClaimAmount) = IROYALTY_POLICY_LS.royaltyData(_claimerIpId); + rnft.safeTransferFrom(address(this), claimerSplitClone, 0, rnftClaimAmount, ""); // claim accrued tokens (if any) _claimAccruedTokens(rnftClaimAmount, totalUnclaimedRnfts, claimerSplitClone, _withdrawETH, _tokens); @@ -78,10 +83,10 @@ contract LSClaimer is ILSClaimer, ERC1155Holder, ReentrancyGuard { /// @notice Checks if a claiming path is valid /// @param _path The path between the IP_ID and the parent or grandparent ipId function _checkIfPathIsValid(address[] calldata _path) internal view { - // the loop below is limited to no more than 100 parents + // the loop below is limited to no more than 100 parents // given the minimum royalty step of 1% and there is a cap of 100% for (uint256 i = 0; i < _path.length - 1; i++) { - if(!LICENSING_MODULE.isParent(_path[i], _path[i+1])) revert Errors.LSClaimer__InvalidPath(); + if (!LICENSING_MODULE.isParent(_path[i], _path[i + 1])) revert Errors.LSClaimer__InvalidPath(); } } @@ -91,26 +96,33 @@ contract LSClaimer is ILSClaimer, ERC1155Holder, ReentrancyGuard { /// @param _claimerSplitClone The claimer's split clone /// @param _withdrawETH Indicates if the claimer wants to withdraw ETH /// @param _tokens The ERC20 tokens to withdraw - function _claimAccruedTokens(uint256 _rnftClaimAmount, uint256 _totalUnclaimedRnfts, address _claimerSplitClone, bool _withdrawETH, ERC20[] calldata _tokens) internal { - ILiquidSplitMain splitMain = ILiquidSplitMain(IROYALTY_POLICY_LS.LIQUID_SPLIT_MAIN()); + function _claimAccruedTokens( + uint256 _rnftClaimAmount, + uint256 _totalUnclaimedRnfts, + address _claimerSplitClone, + bool _withdrawETH, + ERC20[] calldata _tokens + ) internal { + ILiquidSplitMain splitMain = ILiquidSplitMain(IROYALTY_POLICY_LS.LIQUID_SPLIT_MAIN()); if (_withdrawETH) { if (splitMain.getETHBalance(address(this)) != 0) revert Errors.LSClaimer__ETHBalanceNotZero(); uint256 ethBalance = address(this).balance; - uint256 ethClaimAmount = ethBalance * _rnftClaimAmount / _totalUnclaimedRnfts; + uint256 ethClaimAmount = (ethBalance * _rnftClaimAmount) / _totalUnclaimedRnfts; _safeTransferETH(_claimerSplitClone, ethClaimAmount); } for (uint256 i = 0; i < _tokens.length; ++i) { - // When withdrawing ERC20, 0xSplits sets the value to 1 to have warm storage access. + // When withdrawing ERC20, 0xSplits sets the value to 1 to have warm storage access. // But this still means 0 amount left. So, in the check below, we use `> 1`. - if (splitMain.getERC20Balance(address(this), _tokens[i]) > 1) revert Errors.LSClaimer__ERC20BalanceNotZero(); + if (splitMain.getERC20Balance(address(this), _tokens[i]) > 1) + revert Errors.LSClaimer__ERC20BalanceNotZero(); IERC20 IToken = IERC20(_tokens[i]); uint256 tokenBalance = IToken.balanceOf(address(this)); - uint256 tokenClaimAmount = tokenBalance * _rnftClaimAmount / _totalUnclaimedRnfts; + uint256 tokenClaimAmount = (tokenBalance * _rnftClaimAmount) / _totalUnclaimedRnfts; IToken.safeTransfer(_claimerSplitClone, tokenClaimAmount); } diff --git a/contracts/modules/royalty-module/policies/RoyaltyPolicyLS.sol b/contracts/modules/royalty-module/policies/RoyaltyPolicyLS.sol index 8d3c3a8b..256b78b7 100644 --- a/contracts/modules/royalty-module/policies/RoyaltyPolicyLS.sol +++ b/contracts/modules/royalty-module/policies/RoyaltyPolicyLS.sol @@ -18,12 +18,14 @@ import { Errors } from "../../../lib/Errors.sol"; /// the percentage of royalty NFTs owned by each account. contract RoyaltyPolicyLS is IRoyaltyPolicyLS, ERC1155Holder { using SafeERC20 for IERC20; - + struct LSRoyaltyData { address splitClone; // address of the liquid split clone contract for a given ipId address claimer; // address of the claimer contract for a given ipId - uint32 royaltyStack; // royalty stack for a given ipId is the sum of the minRoyalty of all its parents (number between 0 and 1000) - uint32 minRoyalty; // minimum royalty the ipId will receive from its children and grandchildren (number between 0 and 1000) + uint32 royaltyStack; // royalty stack for a given ipId is the sum of the minRoyalty of all its parents + // (number between 0 and 1000) + uint32 minRoyalty; // minimum royalty the ipId will receive from its children and grandchildren + // (number between 0 and 1000) } /// @notice Percentage scale - 1000 rnfts represents 100% @@ -55,7 +57,12 @@ contract RoyaltyPolicyLS is IRoyaltyPolicyLS, ERC1155Holder { /// @param _licensingModule Address of the LicensingModule contract /// @param _liquidSplitFactory Address of the LiquidSplitFactory contract /// @param _liquidSplitMain Address of the LiquidSplitMain contract - constructor(address _royaltyModule, address _licensingModule, address _liquidSplitFactory, address _liquidSplitMain) { + constructor( + address _royaltyModule, + address _licensingModule, + address _liquidSplitFactory, + address _liquidSplitMain + ) { if (_royaltyModule == address(0)) revert Errors.RoyaltyPolicyLS__ZeroRoyaltyModule(); if (_licensingModule == address(0)) revert Errors.RoyaltyPolicyLS__ZeroLicensingModule(); if (_liquidSplitFactory == address(0)) revert Errors.RoyaltyPolicyLS__ZeroLiquidSplitFactory(); @@ -71,8 +78,12 @@ contract RoyaltyPolicyLS is IRoyaltyPolicyLS, ERC1155Holder { /// @param _ipId The ipId /// @param _parentIpIds The parent ipIds /// @param _data The data to initialize the policy - function initPolicy(address _ipId, address[] calldata _parentIpIds, bytes calldata _data) external onlyRoyaltyModule { - (uint32 minRoyalty) = abi.decode(_data, (uint32)); + function initPolicy( + address _ipId, + address[] calldata _parentIpIds, + bytes calldata _data + ) external onlyRoyaltyModule { + uint32 minRoyalty = abi.decode(_data, (uint32)); // root you can choose 0% but children have to choose at least 1% if (minRoyalty == 0 && _parentIpIds.length > 0) revert Errors.RoyaltyPolicyLS__ZeroMinRoyalty(); // minRoyalty has to be a multiple of 1% and given that there are 1000 royalty nfts @@ -83,7 +94,8 @@ contract RoyaltyPolicyLS is IRoyaltyPolicyLS, ERC1155Holder { (uint32 royaltyStack, uint32 newRoyaltyStack) = _checkRoyaltyStackIsValid(_parentIpIds, minRoyalty); // deploy claimer if not root ip - address claimer = address(this); // 0xSplit requires two addresses to allow a split so for root ip address(this) is used as the second address + address claimer = address(this); // 0xSplit requires two addresses to allow a split so + // for root ip address(this) is used as the second address if (_parentIpIds.length > 0) claimer = address(new LSClaimer(_ipId, LICENSING_MODULE, address(this))); // deploy split clone @@ -145,7 +157,10 @@ contract RoyaltyPolicyLS is IRoyaltyPolicyLS, ERC1155Holder { /// @param _minRoyalty The minimum royalty /// @return royaltyStack The royalty stack /// newRoyaltyStack The new royalty stack - function _checkRoyaltyStackIsValid(address[] calldata _parentIpIds, uint32 _minRoyalty) internal view returns (uint32, uint32) { + function _checkRoyaltyStackIsValid( + address[] calldata _parentIpIds, + uint32 _minRoyalty + ) internal view returns (uint32, uint32) { // the loop below is limited to a length of 100 parents // given the minimum royalty step of 1% and a cap of 100% uint32 royaltyStack; @@ -168,7 +183,7 @@ contract RoyaltyPolicyLS is IRoyaltyPolicyLS, ERC1155Holder { address[] memory accounts = new address[](2); accounts[0] = _ipId; accounts[1] = _claimer; - + uint32[] memory initAllocations = new uint32[](2); initAllocations[0] = TOTAL_RNFT_SUPPLY - royaltyStack; initAllocations[1] = royaltyStack; diff --git a/contracts/modules/tagging/TaggingModule.sol b/contracts/modules/tagging/TaggingModule.sol index e3d0c46d..e27f3dca 100644 --- a/contracts/modules/tagging/TaggingModule.sol +++ b/contracts/modules/tagging/TaggingModule.sol @@ -7,8 +7,6 @@ import { ShortString, ShortStrings } from "@openzeppelin/contracts/utils/ShortSt import { EnumerableSet } from "@openzeppelin/contracts/utils/structs/EnumerableSet.sol"; import { ShortStringOps } from "../../utils/ShortStringOps.sol"; -import { Errors } from "../../lib/Errors.sol"; -import { IModule } from "../../interfaces/modules/base/IModule.sol"; import { ITaggingModule } from "../../interfaces/modules/ITaggingModule.sol"; import { TAGGING_MODULE_KEY } from "../../lib/modules/Module.sol"; @@ -17,7 +15,7 @@ contract TaggingModule is ITaggingModule { using EnumerableSet for EnumerableSet.Bytes32Set; using EnumerableSet for EnumerableSet.AddressSet; - uint256 constant MAX_TAG_PERMISSIONS_AT_ONCE = 300; + uint256 public constant MAX_TAG_PERMISSIONS_AT_ONCE = 300; string public constant override name = TAGGING_MODULE_KEY; @@ -52,5 +50,4 @@ contract TaggingModule is ITaggingModule { // WARNING: tag ordering not guaranteed (since they can be removed) return ShortString.wrap(_tagsForIpIds[ipId].at(index)).toString(); } - } diff --git a/contracts/registries/IPAssetRegistry.sol b/contracts/registries/IPAssetRegistry.sol index 247bd7e6..08022292 100644 --- a/contracts/registries/IPAssetRegistry.sol +++ b/contracts/registries/IPAssetRegistry.sol @@ -33,7 +33,7 @@ contract IPAssetRegistry is IIPAssetRegistry, IPAccountRegistry { uint256 public totalSupply = 0; /// @notice Protocol governance administrator of the IP record registry. - address owner; + address public owner; /// @dev Maps an IP, identified by its IP ID, to an IP record. mapping(address => Record) internal _records; diff --git a/contracts/registries/ModuleRegistry.sol b/contracts/registries/ModuleRegistry.sol index dc845bce..d42366b7 100644 --- a/contracts/registries/ModuleRegistry.sol +++ b/contracts/registries/ModuleRegistry.sol @@ -1,6 +1,6 @@ // SPDX-License-Identifier: UNLICENSED // See https://github.com/storyprotocol/protocol-contracts/blob/main/StoryProtocol-AlphaTestingAgreement-17942166.3.pdf -pragma solidity ^0.8.21; +pragma solidity ^0.8.23; import { Strings } from "@openzeppelin/contracts/utils/Strings.sol"; diff --git a/contracts/registries/metadata/IPAssetRenderer.sol b/contracts/registries/metadata/IPAssetRenderer.sol index 2a77f0ea..a7ea6771 100644 --- a/contracts/registries/metadata/IPAssetRenderer.sol +++ b/contracts/registries/metadata/IPAssetRenderer.sol @@ -31,12 +31,7 @@ contract IPAssetRenderer { /// @notice Initializes the IP asset renderer. /// TODO: Add different customization options - e.g. font, colorways, etc. /// TODO: Add an external URL for generating SP-branded links for each IP. - constructor( - address assetRegistry, - address licenseRegistry, - address taggingModule, - address royaltyModule - ) { + constructor(address assetRegistry, address licenseRegistry, address taggingModule, address royaltyModule) { IP_ASSET_REGISTRY = IPAssetRegistry(assetRegistry); LICENSE_REGISTRY = LicenseRegistry(licenseRegistry); TAGGING_MODULE = TaggingModule(taggingModule); @@ -44,13 +39,13 @@ contract IPAssetRenderer { } // TODO: Add contract URI support for metadata about the entire IP registry. - + // TODO: Add rendering functions around licensing information. // TODO: Add rendering functions around royalties information. // TODO: Add rendering functions around tagging information. - + /// @notice Fetches the canonical name associated with the specified IP. /// @param ipId The canonical ID of the specified IP. function name(address ipId) external view returns (string memory) { @@ -65,15 +60,16 @@ contract IPAssetRenderer { /// TODO: Update the description to an SP base URL if external URL not set. function description(address ipId) public view returns (string memory) { IP.MetadataV1 memory metadata = _metadata(ipId); - return string.concat( - metadata.name, - ", IP #", - Strings.toHexString(ipId), - ", is currently owned by", - Strings.toHexString(owner(ipId)), - ". To learn more about this IP, visit ", - metadata.uri - ); + return + string.concat( + metadata.name, + ", IP #", + Strings.toHexString(ipId), + ", is currently owned by", + Strings.toHexString(owner(ipId)), + ". To learn more about this IP, visit ", + metadata.uri + ); } /// @notice Fetches the keccak-256 content hash associated with the specified IP. diff --git a/contracts/registries/metadata/IPMetadataProvider.sol b/contracts/registries/metadata/IPMetadataProvider.sol index 65c5be22..7079f36a 100644 --- a/contracts/registries/metadata/IPMetadataProvider.sol +++ b/contracts/registries/metadata/IPMetadataProvider.sol @@ -2,15 +2,12 @@ // See https://github.com/storyprotocol/protocol-contracts/blob/main/StoryProtocol-AlphaTestingAgreement-17942166.3.pdf pragma solidity ^0.8.23; -import { REGISTRATION_MODULE_KEY } from "../../lib/modules/Module.sol"; import { IMetadataProvider } from "../../interfaces/registries/metadata/IMetadataProvider.sol"; import { IModuleRegistry } from "../../interfaces/registries/IModuleRegistry.sol"; -import { Errors } from "../../lib/Errors.sol"; /// @title IP Metadata Provider Contract /// @notice Base contract used for customization of canonical IP metadata. contract IPMetadataProvider is IMetadataProvider { - /// @notice Gets the protocol-wide module registry. IModuleRegistry public immutable MODULE_REGISTRY; diff --git a/contracts/registries/metadata/MetadataProviderBase.sol b/contracts/registries/metadata/MetadataProviderBase.sol index 216c6d4e..e4a1a9bb 100644 --- a/contracts/registries/metadata/MetadataProviderBase.sol +++ b/contracts/registries/metadata/MetadataProviderBase.sol @@ -2,7 +2,6 @@ // See https://github.com/storyprotocol/protocol-contracts/blob/main/StoryProtocol-AlphaTestingAgreement-17942166.3.pdf pragma solidity ^0.8.23; -import { IP } from "../../lib/IP.sol"; import { IIPAccount } from "../../interfaces/IIPAccount.sol"; import { IMetadataProvider } from "../../interfaces/registries/metadata/IMetadataProvider.sol"; import { IMetadataProviderMigratable } from "../../interfaces/registries/metadata/IMetadataProviderMigratable.sol"; @@ -12,7 +11,6 @@ import { IPAssetRegistry } from "../../registries/IPAssetRegistry.sol"; /// @title IP Metadata Provider Base Contract /// @notice Metadata provider base contract for storing canonical IP metadata. abstract contract MetadataProviderBase is IMetadataProviderMigratable { - /// @notice Gets the protocol-wide IP asset registry. IPAssetRegistry public immutable IP_ASSET_REGISTRY; @@ -23,7 +21,7 @@ abstract contract MetadataProviderBase is IMetadataProviderMigratable { mapping(address ip => bytes metadata) internal _ipMetadata; /// @notice Restricts calls to only originate from a protocol-authorized caller. - modifier onlyIPAssetRegistry { + modifier onlyIPAssetRegistry() { if (msg.sender != address(IP_ASSET_REGISTRY)) { revert Errors.MetadataProvider__Unauthorized(); } @@ -85,5 +83,5 @@ abstract contract MetadataProviderBase is IMetadataProviderMigratable { /// @dev Checks whether two sets of metadata are compatible with one another. /// @param m1 The first set of bytes metadata being compared. /// @param m2 The second set of bytes metadata being compared. - function _compatible(bytes memory m1, bytes memory m2) internal virtual pure returns (bool); + function _compatible(bytes memory m1, bytes memory m2) internal pure virtual returns (bool); } diff --git a/contracts/registries/metadata/MetadataProviderV1.sol b/contracts/registries/metadata/MetadataProviderV1.sol index 9f0e65eb..ba9a190e 100644 --- a/contracts/registries/metadata/MetadataProviderV1.sol +++ b/contracts/registries/metadata/MetadataProviderV1.sol @@ -9,7 +9,6 @@ import { Errors } from "../../lib/Errors.sol"; /// @title IP Metadata Provider v1 /// @notice Storage provider for Story Protocol canonical IP metadata (v1). contract MetadataProviderV1 is MetadataProviderBase { - /// @notice Initializes the metadata provider contract. /// @param ipAssetRegistry The protocol-wide IP asset registry. constructor(address ipAssetRegistry) MetadataProviderBase(ipAssetRegistry) {} @@ -58,26 +57,18 @@ contract MetadataProviderV1 is MetadataProviderBase { revert Errors.MetadataProvider__RegistrantInvalid(); } } - + /// @dev Checks whether two sets of metadata are compatible with one another. /// TODO: Add try-catch for ABI-decoding error handling. - function _compatible(bytes memory m1, bytes memory m2) internal virtual override pure returns (bool) { + function _compatible(bytes memory m1, bytes memory m2) internal pure virtual override returns (bool) { IP.MetadataV1 memory m1Decoded = abi.decode(m1, (IP.MetadataV1)); IP.MetadataV1 memory m2Decoded = abi.decode(m2, (IP.MetadataV1)); return _hash(m1Decoded) == _hash(m2Decoded); } /// @dev Gets the bytes32 hash for a MetadataV1 data struct. - function _hash(IP.MetadataV1 memory data) internal pure returns(bytes32) { - return keccak256( - abi.encode( - data.name, - data.hash, - data.registrationDate, - data.registrant, - data.uri - ) - ); + function _hash(IP.MetadataV1 memory data) internal pure returns (bytes32) { + return keccak256(abi.encode(data.name, data.hash, data.registrationDate, data.registrant, data.uri)); } /// @dev Get the decoded canonical metadata belonging to an IP asset. diff --git a/contracts/utils/ShortStringOps.sol b/contracts/utils/ShortStringOps.sol index f0a19565..cddc0adb 100644 --- a/contracts/utils/ShortStringOps.sol +++ b/contracts/utils/ShortStringOps.sol @@ -1,6 +1,6 @@ // SPDX-License-Identifier: UNLICENSED // See https://github.com/storyprotocol/protocol-contracts/blob/main/StoryProtocol-AlphaTestingAgreement-17942166.3.pdf -pragma solidity ^0.8.19; +pragma solidity ^0.8.23; import { ShortString, ShortStrings } from "@openzeppelin/contracts/utils/ShortStrings.sol"; diff --git a/hardhat.config.ts b/hardhat.config.ts index 7015becc..b220c0e1 100644 --- a/hardhat.config.ts +++ b/hardhat.config.ts @@ -1,8 +1,8 @@ +import "@nomicfoundation/hardhat-ethers" import "@nomicfoundation/hardhat-foundry" -import "@nomiclabs/hardhat-waffle" -import "@nomiclabs/hardhat-ethers" import "@nomicfoundation/hardhat-verify" import "@tenderly/hardhat-tenderly" +import { TenderlyConfig } from "@tenderly/hardhat-tenderly/dist/tenderly/types" import * as tdly from "@tenderly/hardhat-tenderly" // also import tdly for setup, in addition to global import above import "@typechain/hardhat" // import "@openzeppelin/hardhat-upgrades" @@ -70,19 +70,21 @@ const config: HardhatUserConfig = { url: MAINNET_URL || "", accounts: [MAINNET_PRIVATEKEY], }, - ...(USE_TENDERLY? ({ - tenderly: { - chainId: 11155111, - url: TENDERLY_URL || "", - accounts: [TENDERLY_PRIVATEKEY], - } - }) : ({ - sepolia: { - chainId: 11155111, - url: SEPOLIA_URL || "", - accounts: [SEPOLIA_PRIVATEKEY], - } - })), + ...(USE_TENDERLY + ? { + tenderly: { + chainId: 11155111, + url: TENDERLY_URL || "", + accounts: [TENDERLY_PRIVATEKEY], + }, + } + : { + sepolia: { + chainId: 11155111, + url: SEPOLIA_URL || "", + accounts: [SEPOLIA_PRIVATEKEY], + }, + }), }, // @ts-ignore namedAccounts: { @@ -103,14 +105,15 @@ const config: HardhatUserConfig = { etherscan: { apiKey: ETHERSCAN_API_KEY, }, - ...(USE_TENDERLY? ({ - tenderly: { - project: process.env.TENDERLY_PROJECT_SLUG || "", - username: process.env.TENDERLY_USERNAME || "", - forkNetwork: 1, // fork mainnet - privateVerification: process.env.TENDERLY_PRIVATE_VERIFICATION === "true", - }, - }) : ({})), + ...(USE_TENDERLY + ? { + tenderly: { + project: process.env.TENDERLY_PROJECT_SLUG || "", + username: process.env.TENDERLY_USERNAME || "", + privateVerification: process.env.TENDERLY_PRIVATE_VERIFICATION === "true", + } as TenderlyConfig, + } + : {}), typechain: { outDir: "typechain", target: "ethers-v6", diff --git a/package.json b/package.json index 5640c2dc..9b14af13 100644 --- a/package.json +++ b/package.json @@ -8,10 +8,14 @@ "test": "test" }, "scripts": { - "lint": "npm run lint:solidity && npm run lint:javascript", - "lint:javascript": "eslint ./", - "lint:solidity": "solhint \"contracts/**/*.sol\" \"test/**/*.sol\"", - "test": "npx hardhat test" + "lint": "npm run lint:js && npm run lint:sol", + "lint:fix": "npm run lint:js:fix && npm run lint:sol:fix", + "lint:js": "prettier --log-level warn --ignore-path .gitignore '**/*.{js,ts}' --check && eslint --ignore-path .gitignore .", + "lint:js:fix": "prettier --log-level warn --ignore-path .gitignore '**/*.{js,ts}' --write && eslint --ignore-path .gitignore . --fix", + "lint:sol": "prettier --log-level warn --ignore-path .gitignore '{contracts,test}/**/*.sol' --check && solhint '{contracts,test}/**/*.sol'", + "lint:sol:fix": "prettier --log-level warn --ignore-path .gitignore '{contracts,test}/**/*.sol' --write", + "test": "npx hardhat test", + "prepare": "husky install" }, "author": "StoryProtocol", "license": "MIT", @@ -19,34 +23,34 @@ "@nomicfoundation/hardhat-ethers": "^3.0.5", "@nomicfoundation/hardhat-foundry": "^1.1.1", "@nomicfoundation/hardhat-verify": "^2.0.3", - "@nomiclabs/hardhat-ethers": "^2.2.3", - "@nomiclabs/hardhat-waffle": "^2.0.5", "@openzeppelin/hardhat-upgrades": "^3.0.2", - "@tenderly/hardhat-tenderly": "^2.1.0", + "@tenderly/hardhat-tenderly": "^2.2.1", "@typechain/ethers-v6": "^0.5.1", "@typechain/hardhat": "^9.1.0", "base64-sol": "^1.1.0", - "chai": "^4.3.7", - "dotenv": "^16.0.3", - "eslint": "^8.38.0", - "eslint-plugin-prettier": "^4.2.1", - "ethereum-waffle": "^4.0.10", - "ethers": "^5", + "chai": "^5.0.3", + "dotenv": "^16.4.1", + "ds-test": "https://github.com/dapphub/ds-test", + "eslint": "^8.56.0", + "eslint-plugin-prettier": "^5.1.3", + "ethers": "^6", + "forge-std": "github:foundry-rs/forge-std#v1.7.6", "hardhat": "^2.19.4", "hardhat-contract-sizer": "^2.10.0", "hardhat-deploy": "^0.11.45", "hardhat-deploy-ethers": "^0.4.1", - "hardhat-gas-reporter": "^1.0.9", + "hardhat-gas-reporter": "^1.0.10", + "minimatch": "^9.0.3", "mocha": "^10.2.0", - "prettier": "2.8.7", - "prettier-plugin-solidity": "^1.1.3", - "solhint": "^3.4.1", - "solhint-plugin-prettier": "^0.0.5", - "solidity-coverage": "^0.8.2", + "prettier": "^3.0.0", + "prettier-plugin-solidity": "^1.1.0", + "solhint": "^4.1.1", + "solhint-community": "^3.7.0", + "solhint-plugin-prettier": "^0.1.0", + "solidity-coverage": "^0.8.6", "ts-node": "^10.9.2", "typechain": "^8.3.2", - "forge-std": "github:foundry-rs/forge-std#v1.7.6", - "ds-test": "github:dapphub/ds-test" + "husky": "^8.0.0" }, "dependencies": { "@openzeppelin/contracts": "5.0.1", diff --git a/test/foundry/AccessController.t.sol b/test/foundry/AccessController.t.sol index 04a5c548..2087a64e 100644 --- a/test/foundry/AccessController.t.sol +++ b/test/foundry/AccessController.t.sol @@ -1,10 +1,9 @@ // SPDX-License-Identifier: MIT -pragma solidity ^0.8.21; +pragma solidity ^0.8.23; import { Test } from "forge-std/Test.sol"; import { ERC6551Registry } from "@erc6551/ERC6551Registry.sol"; -import { IERC6551Account } from "@erc6551/interfaces/IERC6551Account.sol"; import { AccessController } from "contracts/AccessController.sol"; import { IIPAccount } from "contracts/interfaces/IIPAccount.sol"; @@ -14,7 +13,6 @@ import { AccessPermission } from "contracts/lib/AccessPermission.sol"; import { Errors } from "contracts/lib/Errors.sol"; import { IPAccountRegistry } from "contracts/registries/IPAccountRegistry.sol"; import { ModuleRegistry } from "contracts/registries/ModuleRegistry.sol"; -import { MockAccessController } from "test/foundry/mocks/MockAccessController.sol"; import { MockERC721 } from "test/foundry/mocks/MockERC721.sol"; import { MockModule } from "test/foundry/mocks/MockModule.sol"; import { MockOrchestratorModule } from "test/foundry/mocks/MockOrchestratorModule.sol"; @@ -25,13 +23,13 @@ contract AccessControllerTest is Test { IPAccountRegistry public ipAccountRegistry; IModuleRegistry public moduleRegistry; IPAccountImpl public implementation; - MockERC721 nft = new MockERC721("MockERC721"); + MockERC721 public nft = new MockERC721("MockERC721"); MockModule public mockModule; MockModule public moduleWithoutPermission; IIPAccount public ipAccount; ERC6551Registry public erc6551Registry = new ERC6551Registry(); - address owner = vm.addr(1); - uint256 tokenId = 100; + address public owner = vm.addr(1); + uint256 public tokenId = 100; Governance public governance; function setUp() public { @@ -938,22 +936,16 @@ contract AccessControllerTest is Test { mockModule.executeNoReturn.selector, 3 ); - } function test_AccessController_revert_setGlobalPermissionWithZeroSignerAddress() public { - vm.expectRevert( - abi.encodeWithSelector( - Errors.AccessController__SignerIsZeroAddress.selector - ) - ); + vm.expectRevert(abi.encodeWithSelector(Errors.AccessController__SignerIsZeroAddress.selector)); accessController.setGlobalPermission( address(0), address(mockModule), mockModule.executeNoReturn.selector, AccessPermission.ALLOW ); - } function test_AccessController_ipAccountOwnerSetBatchPermissions() public { @@ -987,10 +979,7 @@ contract AccessControllerTest is Test { ipAccount.execute( address(accessController), 0, - abi.encodeWithSignature( - "setBatchPermissions((address,address,address,bytes4,uint8)[])", - permissionList - ) + abi.encodeWithSignature("setBatchPermissions((address,address,address,bytes4,uint8)[])", permissionList) ); assertEq( accessController.getPermission( @@ -1053,7 +1042,6 @@ contract AccessControllerTest is Test { ); } - function test_AccessController_revert_NonIpAccountOwnerSetBatchPermissions() public { moduleRegistry.registerModule("MockModule", address(mockModule)); address signer = vm.addr(2); @@ -1095,10 +1083,7 @@ contract AccessControllerTest is Test { ipAccount.execute( address(accessController), 0, - abi.encodeWithSignature( - "setBatchPermissions((address,address,address,bytes4,uint8)[])", - permissionList - ) + abi.encodeWithSignature("setBatchPermissions((address,address,address,bytes4,uint8)[])", permissionList) ); } @@ -1130,18 +1115,11 @@ contract AccessControllerTest is Test { }); vm.prank(owner); - vm.expectRevert( - abi.encodeWithSelector( - Errors.AccessController__IPAccountIsZeroAddress.selector - ) - ); + vm.expectRevert(abi.encodeWithSelector(Errors.AccessController__IPAccountIsZeroAddress.selector)); ipAccount.execute( address(accessController), 0, - abi.encodeWithSignature( - "setBatchPermissions((address,address,address,bytes4,uint8)[])", - permissionList - ) + abi.encodeWithSignature("setBatchPermissions((address,address,address,bytes4,uint8)[])", permissionList) ); } @@ -1173,18 +1151,11 @@ contract AccessControllerTest is Test { }); vm.prank(owner); - vm.expectRevert( - abi.encodeWithSelector( - Errors.AccessController__SignerIsZeroAddress.selector - ) - ); + vm.expectRevert(abi.encodeWithSelector(Errors.AccessController__SignerIsZeroAddress.selector)); ipAccount.execute( address(accessController), 0, - abi.encodeWithSignature( - "setBatchPermissions((address,address,address,bytes4,uint8)[])", - permissionList - ) + abi.encodeWithSignature("setBatchPermissions((address,address,address,bytes4,uint8)[])", permissionList) ); } @@ -1223,10 +1194,7 @@ contract AccessControllerTest is Test { ipAccount.execute( address(accessController), 0, - abi.encodeWithSignature( - "setBatchPermissions((address,address,address,bytes4,uint8)[])", - permissionList - ) + abi.encodeWithSignature("setBatchPermissions((address,address,address,bytes4,uint8)[])", permissionList) ); } @@ -1263,10 +1231,7 @@ contract AccessControllerTest is Test { ipAccount.execute( address(accessController), 0, - abi.encodeWithSignature( - "setBatchPermissions((address,address,address,bytes4,uint8)[])", - permissionList - ) + abi.encodeWithSignature("setBatchPermissions((address,address,address,bytes4,uint8)[])", permissionList) ); } diff --git a/test/foundry/IPAccount.t.sol b/test/foundry/IPAccount.t.sol index f0e20f27..bde2d417 100644 --- a/test/foundry/IPAccount.t.sol +++ b/test/foundry/IPAccount.t.sol @@ -1,24 +1,25 @@ // SPDX-License-Identifier: MIT -pragma solidity ^0.8.21; - -import "forge-std/Test.sol"; +pragma solidity ^0.8.23; import { ERC6551Registry } from "@erc6551/ERC6551Registry.sol"; +import { IERC6551Account } from "@erc6551/interfaces/IERC6551Account.sol"; +import { Test } from "forge-std/Test.sol"; -import "contracts/IPAccountImpl.sol"; -import "contracts/interfaces/IIPAccount.sol"; -import "contracts/registries/IPAccountRegistry.sol"; -import "contracts/registries/ModuleRegistry.sol"; - -import "test/foundry/mocks/MockAccessController.sol"; -import "test/foundry/mocks/MockERC721.sol"; -import "test/foundry/mocks/MockModule.sol"; +import { IPAccountImpl } from "contracts/IPAccountImpl.sol"; +import { IIPAccount } from "contracts/interfaces/IIPAccount.sol"; +import { IPAccountRegistry } from "contracts/registries/IPAccountRegistry.sol"; +import { ModuleRegistry } from "contracts/registries/ModuleRegistry.sol"; import { Governance } from "contracts/governance/Governance.sol"; +import { Errors } from "contracts/lib/Errors.sol"; + +import { MockAccessController } from "test/foundry/mocks/MockAccessController.sol"; +import { MockERC721 } from "test/foundry/mocks/MockERC721.sol"; +import { MockModule } from "test/foundry/mocks/MockModule.sol"; contract IPAccountTest is Test { IPAccountRegistry public registry; IPAccountImpl public implementation; - MockERC721 nft = new MockERC721("MockERC721"); + MockERC721 public nft = new MockERC721("MockERC721"); ERC6551Registry public erc6551Registry = new ERC6551Registry(); MockAccessController public accessController = new MockAccessController(); ModuleRegistry public moduleRegistry; @@ -37,32 +38,20 @@ contract IPAccountTest is Test { address owner = vm.addr(1); uint256 tokenId = 100; - address predictedAccount = registry.ipAccount( - block.chainid, - address(nft), - tokenId - ); + address predictedAccount = registry.ipAccount(block.chainid, address(nft), tokenId); nft.mintId(owner, tokenId); vm.prank(owner, owner); - address deployedAccount = registry.registerIpAccount( - block.chainid, - address(nft), - tokenId - ); + address deployedAccount = registry.registerIpAccount(block.chainid, address(nft), tokenId); assertTrue(deployedAccount != address(0)); assertEq(predictedAccount, deployedAccount); // Create account twice - deployedAccount = registry.registerIpAccount( - block.chainid, - address(nft), - tokenId - ); + deployedAccount = registry.registerIpAccount(block.chainid, address(nft), tokenId); assertEq(predictedAccount, deployedAccount); } @@ -73,11 +62,7 @@ contract IPAccountTest is Test { nft.mintId(owner, tokenId); vm.prank(owner, owner); - address account = registry.registerIpAccount( - block.chainid, - address(nft), - tokenId - ); + address account = registry.registerIpAccount(block.chainid, address(nft), tokenId); IIPAccount ipAccount = IIPAccount(payable(account)); @@ -102,10 +87,7 @@ contract IPAccountTest is Test { address newOwner = vm.addr(2); vm.prank(owner); nft.safeTransferFrom(owner, newOwner, tokenId); - assertEq( - ipAccount.isValidSigner(newOwner, ""), - IERC6551Account.isValidSigner.selector - ); + assertEq(ipAccount.isValidSigner(newOwner, ""), IERC6551Account.isValidSigner.selector); } function test_IPAccount_OwnerExecutionPass() public { @@ -115,11 +97,7 @@ contract IPAccountTest is Test { nft.mintId(owner, tokenId); vm.prank(owner, owner); - address account = registry.registerIpAccount( - block.chainid, - address(nft), - tokenId - ); + address account = registry.registerIpAccount(block.chainid, address(nft), tokenId); uint256 subTokenId = 111; nft.mintId(account, subTokenId); @@ -127,7 +105,11 @@ contract IPAccountTest is Test { IIPAccount ipAccount = IIPAccount(payable(account)); vm.prank(owner); - bytes memory result = ipAccount.execute(address(module), 0, abi.encodeWithSignature("executeSuccessfully(string)", "test")); + bytes memory result = ipAccount.execute( + address(module), + 0, + abi.encodeWithSignature("executeSuccessfully(string)", "test") + ); assertEq("test", abi.decode(result, (string))); assertEq(ipAccount.state(), 1); @@ -139,11 +121,7 @@ contract IPAccountTest is Test { nft.mintId(owner, tokenId); - address account = registry.registerIpAccount( - block.chainid, - address(nft), - tokenId - ); + address account = registry.registerIpAccount(block.chainid, address(nft), tokenId); uint256 subTokenId = 111; nft.mintId(account, subTokenId); @@ -170,11 +148,7 @@ contract IPAccountTest is Test { nft.mintId(owner, tokenId); - address account = registry.registerIpAccount( - block.chainid, - address(nft), - tokenId - ); + address account = registry.registerIpAccount(block.chainid, address(nft), tokenId); uint256 subTokenId = 111; nft.mintId(account, subTokenId); @@ -194,11 +168,7 @@ contract IPAccountTest is Test { nft.mintId(owner, tokenId); vm.prank(owner, owner); - address account = registry.registerIpAccount( - block.chainid, - address(nft), - tokenId - ); + address account = registry.registerIpAccount(block.chainid, address(nft), tokenId); address otherOwner = vm.addr(2); uint256 otherTokenId = 200; diff --git a/test/foundry/IPAccountMetaTx.t.sol b/test/foundry/IPAccountMetaTx.t.sol index f8686803..0a19d4c5 100644 --- a/test/foundry/IPAccountMetaTx.t.sol +++ b/test/foundry/IPAccountMetaTx.t.sol @@ -1,32 +1,28 @@ // SPDX-License-Identifier: MIT -pragma solidity ^0.8.21; - -import "forge-std/Test.sol"; -import "forge-std/console.sol"; +pragma solidity ^0.8.23; import { ERC6551Registry } from "@erc6551/ERC6551Registry.sol"; - -import "contracts/IPAccountImpl.sol"; -import "contracts/interfaces/IIPAccount.sol"; -import "contracts/interfaces/IAccessController.sol"; -import "contracts/registries/IPAccountRegistry.sol"; -import "contracts/registries/ModuleRegistry.sol"; - -import "contracts/AccessController.sol"; -import "test/foundry/mocks/MockERC721.sol"; -import "test/foundry/mocks/MockModule.sol"; -import "test/foundry/mocks/MockMetaTxModule.sol"; - import { MessageHashUtils } from "@openzeppelin/contracts/utils/cryptography/MessageHashUtils.sol"; -import { SignatureChecker } from "@openzeppelin/contracts/utils/cryptography/SignatureChecker.sol"; +import { Test } from "forge-std/Test.sol"; + +import { IPAccountImpl } from "contracts/IPAccountImpl.sol"; +import { IIPAccount } from "contracts/interfaces/IIPAccount.sol"; +import { IPAccountRegistry } from "contracts/registries/IPAccountRegistry.sol"; +import { ModuleRegistry } from "contracts/registries/ModuleRegistry.sol"; +import { AccessController } from "contracts/AccessController.sol"; import { MetaTx } from "contracts/lib/MetaTx.sol"; -import "contracts/lib/AccessPermission.sol"; +import { AccessPermission } from "contracts/lib/AccessPermission.sol"; import { Governance } from "contracts/governance/Governance.sol"; +import { Errors } from "contracts/lib/Errors.sol"; + +import { MockERC721 } from "test/foundry/mocks/MockERC721.sol"; +import { MockModule } from "test/foundry/mocks/MockModule.sol"; +import { MockMetaTxModule } from "test/foundry/mocks/MockMetaTxModule.sol"; contract IPAccountMetaTxTest is Test { IPAccountRegistry public registry; IPAccountImpl public implementation; - MockERC721 nft = new MockERC721("MockERC721"); + MockERC721 public nft = new MockERC721("MockERC721"); ERC6551Registry public erc6551Registry = new ERC6551Registry(); AccessController public accessController; ModuleRegistry public moduleRegistry; diff --git a/test/foundry/IPAssetRegistry.t.sol b/test/foundry/IPAssetRegistry.t.sol index 2148be5e..b908f59e 100644 --- a/test/foundry/IPAssetRegistry.t.sol +++ b/test/foundry/IPAssetRegistry.t.sol @@ -2,24 +2,20 @@ pragma solidity ^0.8.23; import { BaseTest } from "./utils/BaseTest.sol"; -import { IModuleRegistry } from "contracts/interfaces/registries/IModuleRegistry.sol"; import { IIPAssetRegistry } from "contracts/interfaces/registries/IIPAssetRegistry.sol"; import { IPAccountChecker } from "contracts/lib/registries/IPAccountChecker.sol"; import { IP } from "contracts/lib/IP.sol"; -import { MetadataProviderV1 } from "contracts/registries/metadata/MetadataProviderV1.sol"; import { IPAccountRegistry } from "contracts/registries/IPAccountRegistry.sol"; import { ERC6551Registry } from "@erc6551/ERC6551Registry.sol"; import { IPAssetRegistry } from "contracts/registries/IPAssetRegistry.sol"; -import { IPAccountImpl} from "contracts/IPAccountImpl.sol"; +import { IPAccountImpl } from "contracts/IPAccountImpl.sol"; import { MockAccessController } from "test/foundry/mocks/MockAccessController.sol"; -import { MockModuleRegistry } from "test/foundry/mocks/MockModuleRegistry.sol"; import { MockERC721 } from "test/foundry/mocks/MockERC721.sol"; import { Errors } from "contracts/lib/Errors.sol"; /// @title IP Asset Registry Testing Contract /// @notice Contract for testing core IP registration. contract IPAssetRegistryTest is BaseTest { - // Default IP record attributes. string public constant IP_NAME = "IPAsset"; string public constant IP_DESCRIPTION = "IPs all the way down."; @@ -57,41 +53,21 @@ contract IPAssetRegistryTest is BaseTest { address accessController = address(new MockAccessController()); erc6551Registry = address(new ERC6551Registry()); ipAccountImpl = address(new IPAccountImpl()); - ipAccountRegistry = new IPAccountRegistry( - erc6551Registry, - accessController, - ipAccountImpl - ); - registry = new IPAssetRegistry( - accessController, - erc6551Registry, - ipAccountImpl - ); + ipAccountRegistry = new IPAccountRegistry(erc6551Registry, accessController, ipAccountImpl); + registry = new IPAssetRegistry(accessController, erc6551Registry, ipAccountImpl); MockERC721 erc721 = new MockERC721("MockERC721"); tokenAddress = address(erc721); tokenId = erc721.mintId(alice, 99); assertEq(ipAccountRegistry.getIPAccountImpl(), ipAccountImpl); - ipId = _getAccount( - ipAccountImpl, - block.chainid, - tokenAddress, - tokenId, - ipAccountRegistry.IP_ACCOUNT_SALT() - ); + ipId = _getAccount(ipAccountImpl, block.chainid, tokenAddress, tokenId, ipAccountRegistry.IP_ACCOUNT_SALT()); } /// @notice Tests retrieval of IP canonical IDs. function test_IPAssetRegistry_IpId() public { assertEq( registry.ipId(block.chainid, tokenAddress, tokenId), - _getAccount( - ipAccountImpl, - block.chainid, - tokenAddress, - tokenId, - ipAccountRegistry.IP_ACCOUNT_SALT() - ) + _getAccount(ipAccountImpl, block.chainid, tokenAddress, tokenId, ipAccountRegistry.IP_ACCOUNT_SALT()) ); } @@ -118,14 +94,7 @@ contract IPAssetRegistryTest is BaseTest { address(registry.metadataProvider()), metadata ); - registry.register( - block.chainid, - tokenAddress, - tokenId, - resolver, - true, - metadata - ); + registry.register(block.chainid, tokenAddress, tokenId, resolver, true, metadata); /// Ensures IP asset post-registration conditions are met. assertEq(registry.resolver(ipId), resolver); @@ -156,14 +125,7 @@ contract IPAssetRegistryTest is BaseTest { address(registry.metadataProvider()), metadata ); - registry.register( - block.chainid, - tokenAddress, - tokenId, - resolver, - false, - metadata - ); + registry.register(block.chainid, tokenAddress, tokenId, resolver, false, metadata); /// Ensures IP asset post-registration conditions are met. assertEq(registry.resolver(ipId), resolver); @@ -174,22 +136,10 @@ contract IPAssetRegistryTest is BaseTest { /// @notice Tests registration of IP assets works with existing IP accounts. function test_IPAssetRegistry_RegisterExistingAccount() public { - registry.registerIpAccount( - block.chainid, - tokenAddress, - tokenId - ); + registry.registerIpAccount(block.chainid, tokenAddress, tokenId); assertTrue(IPAccountChecker.isRegistered(ipAccountRegistry, block.chainid, tokenAddress, tokenId)); bytes memory metadata = _generateMetadata(); - registry.register( - block.chainid, - tokenAddress, - tokenId, - resolver, - true, - metadata - ); - + registry.register(block.chainid, tokenAddress, tokenId, resolver, true, metadata); } /// @notice Tests registration of IP reverts when an IP has already been registered. @@ -205,10 +155,7 @@ contract IPAssetRegistryTest is BaseTest { registry.register(block.chainid, tokenAddress, tokenId, resolver, true, _generateMetadata()); vm.expectEmit(true, true, true, true); - emit IIPAssetRegistry.IPResolverSet( - ipId, - resolver2 - ); + emit IIPAssetRegistry.IPResolverSet(ipId, resolver2); vm.prank(alice); registry.setResolver(ipId, resolver2); } @@ -228,26 +175,19 @@ contract IPAssetRegistryTest is BaseTest { uint256 contractId, bytes32 salt ) internal view returns (address) { - return ERC6551Registry(erc6551Registry).account( - impl, - salt, - chainId, - contractAddress, - contractId - ); + return ERC6551Registry(erc6551Registry).account(impl, salt, chainId, contractAddress, contractId); } function _generateMetadata() internal view returns (bytes memory) { - return abi.encode( - IP.MetadataV1({ - name: IP_NAME, - hash: IP_HASH, - registrationDate: uint64(block.timestamp), - registrant: alice, - uri: IP_EXTERNAL_URL - - }) - ); + return + abi.encode( + IP.MetadataV1({ + name: IP_NAME, + hash: IP_HASH, + registrationDate: uint64(block.timestamp), + registrant: alice, + uri: IP_EXTERNAL_URL + }) + ); } - } diff --git a/test/foundry/ModuleRegistry.t.sol b/test/foundry/ModuleRegistry.t.sol index 25aafcda..a6e12993 100644 --- a/test/foundry/ModuleRegistry.t.sol +++ b/test/foundry/ModuleRegistry.t.sol @@ -4,16 +4,13 @@ pragma solidity ^0.8.23; import { Test } from "forge-std/Test.sol"; import { ERC6551Registry } from "@erc6551/ERC6551Registry.sol"; -import { IERC6551Account } from "@erc6551/interfaces/IERC6551Account.sol"; import { IPAccountImpl } from "contracts/IPAccountImpl.sol"; -import { IIPAccount } from "contracts/interfaces/IIPAccount.sol"; import { IPAccountRegistry } from "contracts/registries/IPAccountRegistry.sol"; import { ModuleRegistry } from "contracts/registries/ModuleRegistry.sol"; import { Errors } from "contracts/lib/Errors.sol"; import { MockAccessController } from "test/foundry/mocks/MockAccessController.sol"; -import { MockERC721 } from "test/foundry/mocks/MockERC721.sol"; import { MockModule } from "test/foundry/mocks/MockModule.sol"; import { Governance } from "contracts/governance/Governance.sol"; diff --git a/test/foundry/access/AccessControlled.t.sol b/test/foundry/access/AccessControlled.t.sol index 50d07cf6..9bbc109b 100644 --- a/test/foundry/access/AccessControlled.t.sol +++ b/test/foundry/access/AccessControlled.t.sol @@ -3,9 +3,7 @@ pragma solidity ^0.8.23; import { Test } from "forge-std/Test.sol"; -import { IAccessController } from "contracts/interfaces/IAccessController.sol"; import { ERC6551Registry } from "@erc6551/ERC6551Registry.sol"; -import { IERC6551Account } from "@erc6551/interfaces/IERC6551Account.sol"; import { AccessController } from "contracts/AccessController.sol"; import { IIPAccount } from "contracts/interfaces/IIPAccount.sol"; @@ -15,10 +13,7 @@ import { AccessPermission } from "contracts/lib/AccessPermission.sol"; import { Errors } from "contracts/lib/Errors.sol"; import { IPAccountRegistry } from "contracts/registries/IPAccountRegistry.sol"; import { ModuleRegistry } from "contracts/registries/ModuleRegistry.sol"; -import { MockAccessController } from "test/foundry/mocks/MockAccessController.sol"; import { MockERC721 } from "test/foundry/mocks/MockERC721.sol"; -import { MockModule } from "test/foundry/mocks/MockModule.sol"; -import { MockOrchestratorModule } from "test/foundry/mocks/MockOrchestratorModule.sol"; import { Governance } from "contracts/governance/Governance.sol"; import { MockAccessControlledModule } from "test/foundry/mocks/MockAccessControlledModule.sol"; @@ -27,12 +22,12 @@ contract AccessControlledTest is Test { IPAccountRegistry public ipAccountRegistry; IModuleRegistry public moduleRegistry; IPAccountImpl public implementation; - MockERC721 nft = new MockERC721("MockERC721"); + MockERC721 public nft = new MockERC721("MockERC721"); MockAccessControlledModule public mockModule; IIPAccount public ipAccount; ERC6551Registry public erc6551Registry = new ERC6551Registry(); - address owner = vm.addr(1); - uint256 tokenId = 100; + address public owner = vm.addr(1); + uint256 public tokenId = 100; Governance public governance; function setUp() public { @@ -201,12 +196,7 @@ contract AccessControlledTest is Test { function test_AccessControlled_revert_callIpAccountOrPermissionFunction_passInNonIpAccount() public { address nonIpAccount = vm.addr(7); - vm.expectRevert( - abi.encodeWithSelector( - Errors.AccessControlled__NotIpAccount.selector, - nonIpAccount - ) - ); + vm.expectRevert(abi.encodeWithSelector(Errors.AccessControlled__NotIpAccount.selector, nonIpAccount)); vm.prank(owner); mockModule.ipAccountOrPermissionFunction(nonIpAccount, "test", true); } diff --git a/test/foundry/governance/Governance.t.sol b/test/foundry/governance/Governance.t.sol index 38827077..5b5674f3 100644 --- a/test/foundry/governance/Governance.t.sol +++ b/test/foundry/governance/Governance.t.sol @@ -1,10 +1,9 @@ // SPDX-License-Identifier: MIT -pragma solidity ^0.8.21; +pragma solidity ^0.8.23; import { Test } from "forge-std/Test.sol"; import { ERC6551Registry } from "@erc6551/ERC6551Registry.sol"; -import { IERC6551Account } from "@erc6551/interfaces/IERC6551Account.sol"; import { AccessController } from "contracts/AccessController.sol"; import { IIPAccount } from "contracts/interfaces/IIPAccount.sol"; @@ -14,10 +13,8 @@ import { AccessPermission } from "contracts/lib/AccessPermission.sol"; import { Errors } from "contracts/lib/Errors.sol"; import { IPAccountRegistry } from "contracts/registries/IPAccountRegistry.sol"; import { ModuleRegistry } from "contracts/registries/ModuleRegistry.sol"; -import { MockAccessController } from "test/foundry/mocks/MockAccessController.sol"; import { MockERC721 } from "test/foundry/mocks/MockERC721.sol"; import { MockModule } from "test/foundry/mocks/MockModule.sol"; -import { MockOrchestratorModule } from "test/foundry/mocks/MockOrchestratorModule.sol"; import { Governance } from "contracts/governance/Governance.sol"; import { IGovernable } from "contracts/interfaces/governance/IGovernable.sol"; import { GovernanceLib } from "contracts/lib/GovernanceLib.sol"; @@ -27,13 +24,13 @@ contract GovernanceTest is Test { IPAccountRegistry public ipAccountRegistry; IModuleRegistry public moduleRegistry; IPAccountImpl public implementation; - MockERC721 nft = new MockERC721("MockERC721"); + MockERC721 public nft = new MockERC721("MockERC721"); MockModule public mockModule; MockModule public moduleWithoutPermission; IIPAccount public ipAccount; ERC6551Registry public erc6551Registry = new ERC6551Registry(); - address owner = vm.addr(1); - uint256 tokenId = 100; + address public owner = vm.addr(1); + uint256 public tokenId = 100; Governance public governance; function setUp() public { diff --git a/test/foundry/integration/BaseIntegration.sol b/test/foundry/integration/BaseIntegration.sol index 97efbc76..da66e9f8 100644 --- a/test/foundry/integration/BaseIntegration.sol +++ b/test/foundry/integration/BaseIntegration.sol @@ -6,7 +6,6 @@ import { IERC1155 } from "@openzeppelin/contracts/token/ERC1155/IERC1155.sol"; import { Strings } from "@openzeppelin/contracts/utils/Strings.sol"; import { Test } from "forge-std/Test.sol"; import { ERC6551Registry } from "@erc6551/ERC6551Registry.sol"; -import { IERC6551Account } from "@erc6551/interfaces/IERC6551Account.sol"; import { IERC6551Registry } from "@erc6551/interfaces/IERC6551Registry.sol"; import { ERC6551AccountLib } from "@erc6551/lib/ERC6551AccountLib.sol"; @@ -14,15 +13,11 @@ import { ERC6551AccountLib } from "@erc6551/lib/ERC6551AccountLib.sol"; import { AccessController } from "contracts/AccessController.sol"; import { Governance } from "contracts/governance/Governance.sol"; import { IPAccountImpl } from "contracts/IPAccountImpl.sol"; -import { IIPAccount } from "contracts/interfaces/IIPAccount.sol"; import { IRegistrationModule } from "contracts/interfaces/modules/IRegistrationModule.sol"; import { IIPAccountRegistry } from "contracts/interfaces/registries/IIPAccountRegistry.sol"; import { IIPAssetRegistry } from "contracts/interfaces/registries/IIPAssetRegistry.sol"; -import { ILicenseRegistry } from "contracts/interfaces/registries/ILicenseRegistry.sol"; import { ILicensingModule } from "contracts/interfaces/modules/licensing/ILicensingModule.sol"; -import { Errors } from "contracts/lib/Errors.sol"; import { IP } from "contracts/lib/IP.sol"; -import { Licensing } from "contracts/lib/Licensing.sol"; import { IP_RESOLVER_MODULE_KEY, REGISTRATION_MODULE_KEY } from "contracts/lib/modules/Module.sol"; import { IPMetadataProvider } from "contracts/registries/metadata/IPMetadataProvider.sol"; import { IPAccountRegistry } from "contracts/registries/IPAccountRegistry.sol"; @@ -145,11 +140,7 @@ contract BaseIntegration is Test { address(ipResolver) ); taggingModule = new TaggingModule(); - disputeModule = new DisputeModule( - address(accessController), - address(ipAssetRegistry), - address(governance) - ); + disputeModule = new DisputeModule(address(accessController), address(ipAssetRegistry), address(governance)); ipAssetRenderer = new IPAssetRenderer( address(ipAssetRegistry), address(licenseRegistry), @@ -516,7 +507,7 @@ contract BaseIntegration is Test { "license not burnt on linking" ); assertTrue(licensingModule.isParent(parentIpIds[i], ipId), "parent IP account is not parent"); - (uint256 index, bool isInherited, bool active) = licensingModule.policyStatus(parentIpIds[i], policyIds[i]); + (uint256 index, bool isInherited, ) = licensingModule.policyStatus(parentIpIds[i], policyIds[i]); assertEq( keccak256(abi.encode(licensingModule.policyForIpAtIndex(isInherited, parentIpIds[i], index))), keccak256(abi.encode(licensingModule.policyForIpAtIndex(true, ipId, i))), diff --git a/test/foundry/integration/big-bang/NftLicenseRoyalty.t.sol b/test/foundry/integration/big-bang/NftLicenseRoyalty.t.sol index e26bb122..d2eef30b 100644 --- a/test/foundry/integration/big-bang/NftLicenseRoyalty.t.sol +++ b/test/foundry/integration/big-bang/NftLicenseRoyalty.t.sol @@ -7,18 +7,15 @@ import { IERC1155 } from "@openzeppelin/contracts/token/ERC1155/IERC1155.sol"; import { EnumerableSet } from "@openzeppelin/contracts/utils/structs/EnumerableSet.sol"; // contract -import { IIPAccount } from "contracts/interfaces/IIPAccount.sol"; -import { ILiquidSplitClone } from "contracts/interfaces/modules/royalty/policies/ILiquidSplitClone.sol"; import { IRoyaltyModule } from "contracts/interfaces/modules/royalty/IRoyaltyModule.sol"; -import { IRoyaltyPolicyLS } from "contracts/interfaces/modules/royalty/policies/IRoyaltyPolicyLS.sol"; import { ILSClaimer } from "contracts/interfaces/modules/royalty/policies/ILSClaimer.sol"; import { IP } from "contracts/lib/IP.sol"; import { LSClaimer } from "contracts/modules/royalty-module/policies/LSClaimer.sol"; // test import { BaseIntegration } from "test/foundry/integration/BaseIntegration.sol"; -import { MintPaymentPolicyFrameworkManager } from "test/foundry/mocks/licensing/MintPaymentPolicyFrameworkManager.sol"; import { MockERC721 } from "test/foundry/mocks/MockERC721.sol"; +// solhint-disable-next-line max-line-length import { Integration_Shared_LicensingHelper, UMLPolicyGenericParams, UMLPolicyCommercialParams, UMLPolicyDerivativeParams } from "test/foundry/integration/shared/LicenseHelper.sol"; contract BigBang_Integration_NftLicenseRoyalty is BaseIntegration, Integration_Shared_LicensingHelper { @@ -245,7 +242,7 @@ contract BigBang_Integration_NftLicenseRoyalty is BaseIntegration, Integration_S // Dan is paying 65% of 1000 USDC royalty to parents (stored in Dan's Claimer). // The other 35% of 1000 USDC royalty goes directly to Dan's IPAccount. vm.expectEmit(address(USDC)); - emit IERC20.Transfer(LIQUID_SPLIT_MAIN, address(danClaimer), 749999998); + emit IERC20.Transfer(LIQUID_SPLIT_MAIN, address(danClaimer), 749999998); royaltyPolicyLS.claimRoyalties({ _account: danClaimer, _withdrawETH: 0, _tokens: tokens }); // Alice calls the claim her portion of rNFTs and tokens. She can only call `claim` once. @@ -253,12 +250,12 @@ contract BigBang_Integration_NftLicenseRoyalty is BaseIntegration, Integration_S vm.expectEmit(address(danSplitClone)); emit IERC1155.TransferSingle({ // rNFTs - operator: address(danClaimer), - from: address(danClaimer), - to: aliceSplitClone, - id: 0, - value: 250 - }); + operator: address(danClaimer), + from: address(danClaimer), + to: aliceSplitClone, + id: 0, + value: 250 + }); vm.expectEmit(address(USDC)); emit IERC20.Transfer(address(danClaimer), aliceSplitClone, 249999999); // alice should get 25% of 1000 USDC @@ -278,5 +275,5 @@ contract BigBang_Integration_NftLicenseRoyalty is BaseIntegration, Integration_S _tokens: tokens }); } - } + } } diff --git a/test/foundry/integration/big-bang/SingleNftCollection.t.sol b/test/foundry/integration/big-bang/SingleNftCollection.t.sol index e070d6ee..d2b1c645 100644 --- a/test/foundry/integration/big-bang/SingleNftCollection.t.sol +++ b/test/foundry/integration/big-bang/SingleNftCollection.t.sol @@ -13,6 +13,7 @@ import { Errors } from "contracts/lib/Errors.sol"; import { BaseIntegration } from "test/foundry/integration/BaseIntegration.sol"; import { MintPaymentPolicyFrameworkManager } from "test/foundry/mocks/licensing/MintPaymentPolicyFrameworkManager.sol"; import { MockERC721 } from "test/foundry/mocks/MockERC721.sol"; +// solhint-disable-next-line max-line-length import { Integration_Shared_LicensingHelper, UMLPolicyGenericParams, UMLPolicyCommercialParams, UMLPolicyDerivativeParams } from "test/foundry/integration/shared/LicenseHelper.sol"; contract BigBang_Integration_SingleNftCollection is BaseIntegration, Integration_Shared_LicensingHelper { @@ -315,7 +316,7 @@ contract BigBang_Integration_SingleNftCollection is BaseIntegration, Integration // This should revert since license[0] is commercial but license[1] is non-commercial vm.expectRevert(Errors.LicensingModule__IncompatibleLicensorCommercialPolicy.selector); - // Call `registrationModule.registerDerivativeIps` directly because expecting revert on the + // Call `registrationModule.registerDerivativeIps` directly because expecting revert on the // wrapper `registerDerivativeIps` fails due to the implementation of the wrapper function. registrationModule.registerDerivativeIp( carl_licenses, diff --git a/test/foundry/integration/flows/emergence-universe/EmergenceUniverse.t.sol b/test/foundry/integration/flows/emergence-universe/EmergenceUniverse.t.sol index 18bb0b08..aa2f73c4 100644 --- a/test/foundry/integration/flows/emergence-universe/EmergenceUniverse.t.sol +++ b/test/foundry/integration/flows/emergence-universe/EmergenceUniverse.t.sol @@ -3,14 +3,6 @@ pragma solidity ^0.8.23; import { Test } from "forge-std/Test.sol"; -import { IERC6551Account } from "@erc6551/interfaces/IERC6551Account.sol"; - -import { IIPAccount } from "contracts/interfaces/IIPAccount.sol"; -import { IPAccountImpl } from "contracts/IPAccountImpl.sol"; -import { IPAccountRegistry } from "contracts/registries/IPAccountRegistry.sol"; -import { MockAccessController } from "test/foundry/mocks/MockAccessController.sol"; -import { MockERC721 } from "test/foundry/mocks/MockERC721.sol"; -import { MockModule } from "test/foundry/mocks/MockModule.sol"; import { Users, UsersLib } from "test/foundry/utils/Users.sol"; contract Integration_Flow_EmergenceUniverse_Test is Test { @@ -20,7 +12,5 @@ contract Integration_Flow_EmergenceUniverse_Test is Test { u = UsersLib.createMockUsers(vm); } - function test_IntegrationFlow_EmergenceUniverse() public { - - } + function test_IntegrationFlow_EmergenceUniverse() public {} } diff --git a/test/foundry/integration/shared/LicenseHelper.sol b/test/foundry/integration/shared/LicenseHelper.sol index e112e72e..2a6ae942 100644 --- a/test/foundry/integration/shared/LicenseHelper.sol +++ b/test/foundry/integration/shared/LicenseHelper.sol @@ -6,7 +6,6 @@ import { ERC20 } from "@openzeppelin/contracts/token/ERC20/ERC20.sol"; // contract import { AccessController } from "contracts/AccessController.sol"; -import { Licensing } from "contracts/lib/Licensing.sol"; import { BasePolicyFrameworkManager } from "contracts/modules/licensing/BasePolicyFrameworkManager.sol"; import { UMLPolicyFrameworkManager, UMLPolicy } from "contracts/modules/licensing/UMLPolicyFrameworkManager.sol"; import { RoyaltyModule } from "contracts/modules/royalty-module/RoyaltyModule.sol"; @@ -14,7 +13,9 @@ import { LicensingModule } from "contracts/modules/licensing/LicensingModule.sol import { IPAccountRegistry } from "contracts/registries/IPAccountRegistry.sol"; // test -import { MockPolicyFrameworkManager, MockPolicyFrameworkConfig, MockPolicy } from "test/foundry/mocks/licensing/MockPolicyFrameworkManager.sol"; +// solhint-disable-next-line max-line-length +import { MockPolicyFrameworkManager, MockPolicyFrameworkConfig } from "test/foundry/mocks/licensing/MockPolicyFrameworkManager.sol"; +// solhint-disable-next-line max-line-length import { MintPaymentPolicyFrameworkManager, MintPaymentPolicy } from "test/foundry/mocks/licensing/MintPaymentPolicyFrameworkManager.sol"; import { MockRoyaltyPolicyLS } from "test/foundry/mocks/MockRoyaltyPolicyLS.sol"; diff --git a/test/foundry/mocks/MockAccessControlledModule.sol b/test/foundry/mocks/MockAccessControlledModule.sol index ce8d3adb..8b2e3d74 100644 --- a/test/foundry/mocks/MockAccessControlledModule.sol +++ b/test/foundry/mocks/MockAccessControlledModule.sol @@ -1,11 +1,11 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.23; -import "contracts/interfaces/modules/base/IModule.sol"; -import "contracts/interfaces/registries/IIPAccountRegistry.sol"; -import "contracts/lib/registries/IPAccountChecker.sol"; -import "contracts/interfaces/registries/IModuleRegistry.sol"; -import "contracts/access/AccessControlled.sol"; +import { IModule } from "contracts/interfaces/modules/base/IModule.sol"; +import { IIPAccountRegistry } from "contracts/interfaces/registries/IIPAccountRegistry.sol"; +import { IPAccountChecker } from "contracts/lib/registries/IPAccountChecker.sol"; +import { IModuleRegistry } from "contracts/interfaces/registries/IModuleRegistry.sol"; +import { AccessControlled } from "contracts/access/AccessControlled.sol"; /// @title MockAccessControlledModule /// @dev This contract is a mock implementation of an access-controlled module, used for testing purposes. @@ -84,5 +84,4 @@ contract MockAccessControlledModule is IModule, AccessControlled { } return param; } - } diff --git a/test/foundry/mocks/MockAccessController.sol b/test/foundry/mocks/MockAccessController.sol index 1e932a4c..39f69d24 100644 --- a/test/foundry/mocks/MockAccessController.sol +++ b/test/foundry/mocks/MockAccessController.sol @@ -1,23 +1,20 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.23; -import "contracts/interfaces/IAccessController.sol"; -import "contracts/interfaces/IIPAccount.sol"; -import "contracts/lib/Errors.sol"; -contract MockAccessController is IAccessController { +import { IAccessController } from "contracts/interfaces/IAccessController.sol"; +import { IIPAccount } from "contracts/interfaces/IIPAccount.sol"; +import { Errors } from "contracts/lib/Errors.sol"; +import { AccessPermission } from "contracts/lib/AccessPermission.sol"; +contract MockAccessController is IAccessController { bool public isAllowed = true; function setAllowed(bool _isAllowed) external { isAllowed = _isAllowed; } - function setGlobalPermission(address signer_, address to_, bytes4 func_, uint8 permission_) external{ + function setGlobalPermission(address signer_, address to_, bytes4 func_, uint8 permission_) external {} - } - - function setPermission(address, address, address, bytes4, uint8) external pure { - - } + function setPermission(address, address, address, bytes4, uint8) external pure {} function getPermission(address, address, address, bytes4) external pure returns (uint8) { return 1; diff --git a/test/foundry/mocks/MockERC20.sol b/test/foundry/mocks/MockERC20.sol index b3dca4ff..c6de4f27 100644 --- a/test/foundry/mocks/MockERC20.sol +++ b/test/foundry/mocks/MockERC20.sol @@ -5,12 +5,12 @@ import { ERC20 } from "@openzeppelin/contracts/token/ERC20/ERC20.sol"; contract MockERC20 is ERC20 { constructor() ERC20("MockERC20", "MERC20") {} - - function mint(address to, uint256 amount) external { - _mint(to, amount); - } - function burn(address from, uint256 amount) external { - _burn(from, amount); - } + function mint(address to, uint256 amount) external { + _mint(to, amount); + } + + function burn(address from, uint256 amount) external { + _burn(from, amount); + } } diff --git a/test/foundry/mocks/MockERC721.sol b/test/foundry/mocks/MockERC721.sol index 0ab75dc3..30065fe0 100644 --- a/test/foundry/mocks/MockERC721.sol +++ b/test/foundry/mocks/MockERC721.sol @@ -1,7 +1,7 @@ // SPDX-License-Identifier: BUSDL-1.1 pragma solidity ^0.8.23; -import "@openzeppelin/contracts/token/ERC721/ERC721.sol"; +import { ERC721 } from "@openzeppelin/contracts/token/ERC721/ERC721.sol"; contract MockERC721 is ERC721 { uint256 private _counter; @@ -25,11 +25,7 @@ contract MockERC721 is ERC721 { _burn(tokenId); } - function transferFrom( - address from, - address to, - uint256 tokenId - ) public override { + function transferFrom(address from, address to, uint256 tokenId) public override { _transfer(from, to, tokenId); } } diff --git a/test/foundry/mocks/MockIncompatibleMetadataProviderV2.sol b/test/foundry/mocks/MockIncompatibleMetadataProviderV2.sol index 734f870c..5cfbe390 100644 --- a/test/foundry/mocks/MockIncompatibleMetadataProviderV2.sol +++ b/test/foundry/mocks/MockIncompatibleMetadataProviderV2.sol @@ -2,21 +2,17 @@ // See https://github.com/storyprotocol/protocol-contracts/blob/main/StoryProtocol-AlphaTestingAgreement-17942166.3.pdf pragma solidity ^0.8.23; -import { IP } from "contracts/lib/IP.sol"; import { MetadataProviderV1 } from "contracts/registries/metadata/MetadataProviderV1.sol"; -import { Errors } from "contracts/lib/Errors.sol"; /// @title Mock IP Metadata Provider v2 /// @notice Mock storage provider for upgraded Story Protocol canonical IP metadata (v2). contract MockMetadataProviderV2 is MetadataProviderV1 { - /// @notice Core v2 metadata to associate with each IP. struct MetadataV2 { // The name associated with the IP. string name; // A keccak-256 hash of the IP content. bytes32 hash; - //////////////////////////////////////////////////////////////////////// // Note: Missing registration memory encoding /// //////////////////////////////////////////////////////////////////////// @@ -42,8 +38,7 @@ contract MockMetadataProviderV2 is MetadataProviderV1 { function _verifyMetadata(bytes memory data) internal virtual override {} /// @dev Checks whether two sets of metadata are compatible with one another. - function _compatible(bytes memory m1, bytes memory m2) internal virtual override pure returns (bool) { + function _compatible(bytes memory, bytes memory) internal pure virtual override returns (bool) { return true; } - } diff --git a/test/foundry/mocks/MockMetaTxModule.sol b/test/foundry/mocks/MockMetaTxModule.sol index 68b646dd..07c7dbdf 100644 --- a/test/foundry/mocks/MockMetaTxModule.sol +++ b/test/foundry/mocks/MockMetaTxModule.sol @@ -1,21 +1,21 @@ // SPDX-License-Identifier: MIT -pragma solidity ^0.8.21; +pragma solidity ^0.8.23; -import "contracts/interfaces/modules/base/IModule.sol"; -import "contracts/interfaces/IIPAccount.sol"; -import "contracts/interfaces/registries/IModuleRegistry.sol"; -import "contracts/interfaces/registries/IIPAccountRegistry.sol"; +import { IModule } from "contracts/interfaces/modules/base/IModule.sol"; +import { IIPAccount } from "contracts/interfaces/IIPAccount.sol"; +import { IModuleRegistry } from "contracts/interfaces/registries/IModuleRegistry.sol"; +import { IIPAccountRegistry } from "contracts/interfaces/registries/IIPAccountRegistry.sol"; import { IPAccountChecker } from "contracts/lib/registries/IPAccountChecker.sol"; import { IIPAccount } from "contracts/interfaces/IIPAccount.sol"; -import "contracts/interfaces/IAccessController.sol"; -import "contracts/lib/AccessPermission.sol"; +import { IAccessController } from "contracts/interfaces/IAccessController.sol"; +import { AccessPermission } from "contracts/lib/AccessPermission.sol"; contract MockMetaTxModule is IModule { using IPAccountChecker for IIPAccountRegistry; IIPAccountRegistry public ipAccountRegistry; IModuleRegistry public moduleRegistry; - IAccessController accessController; + IAccessController public accessController; constructor(address _ipAccountRegistry, address _moduleRegistry, address _accessController) { ipAccountRegistry = IIPAccountRegistry(_ipAccountRegistry); diff --git a/test/foundry/mocks/MockMetadataProviderV2.sol b/test/foundry/mocks/MockMetadataProviderV2.sol index 51d38b8b..b768d39d 100644 --- a/test/foundry/mocks/MockMetadataProviderV2.sol +++ b/test/foundry/mocks/MockMetadataProviderV2.sol @@ -2,14 +2,12 @@ // See https://github.com/storyprotocol/protocol-contracts/blob/main/StoryProtocol-AlphaTestingAgreement-17942166.3.pdf pragma solidity ^0.8.23; -import { IP } from "contracts/lib/IP.sol"; import { MetadataProviderV1 } from "contracts/registries/metadata/MetadataProviderV1.sol"; import { Errors } from "contracts/lib/Errors.sol"; /// @title Mock IP Metadata Provider v2 /// @notice Mock storage provider for upgraded Story Protocol canonical IP metadata (v2). contract MockMetadataProviderV2 is MetadataProviderV1 { - /// @notice Core v2 metadata to associate with each IP. struct MetadataV2 { // The name associated with the IP. @@ -40,7 +38,6 @@ contract MockMetadataProviderV2 is MetadataProviderV1 { return _metadataV2(ipId).decimals; } - /// @notice Initializes the metadata provider contract. /// @param ipAssetRegistry The protocol-wide IP asset registry. constructor(address ipAssetRegistry) MetadataProviderV1(ipAssetRegistry) {} @@ -59,25 +56,26 @@ contract MockMetadataProviderV2 is MetadataProviderV1 { } /// @dev Checks whether two sets of metadata are compatible with one another. - function _compatible(bytes memory m1, bytes memory m2) internal virtual override pure returns (bool) { + function _compatible(bytes memory m1, bytes memory m2) internal pure virtual override returns (bool) { MetadataV2 memory m1Decoded = abi.decode(m1, (MetadataV2)); MetadataV2 memory m2Decoded = abi.decode(m2, (MetadataV2)); return _hash(m1Decoded) == _hash(m2Decoded); } /// @dev Gets the bytes32 hash for a MetadataV1 data struct. - function _hash(MetadataV2 memory data) internal pure returns(bytes32) { - return keccak256( - abi.encode( - data.name, - data.hash, - data.registrationDate, - data.registrant, - data.uri, - data.nickname, - data.decimals - ) - ); + function _hash(MetadataV2 memory data) internal pure returns (bytes32) { + return + keccak256( + abi.encode( + data.name, + data.hash, + data.registrationDate, + data.registrant, + data.uri, + data.nickname, + data.decimals + ) + ); } /// @dev Get the decoded canonical metadata belonging to an IP asset. diff --git a/test/foundry/mocks/MockModule.sol b/test/foundry/mocks/MockModule.sol index 42caa3e7..87b86678 100644 --- a/test/foundry/mocks/MockModule.sol +++ b/test/foundry/mocks/MockModule.sol @@ -1,10 +1,11 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.23; -import "contracts/interfaces/modules/base/IModule.sol"; -import "contracts/interfaces/registries/IIPAccountRegistry.sol"; -import "contracts/lib/registries/IPAccountChecker.sol"; -import "contracts/interfaces/registries/IModuleRegistry.sol"; +import { IModule } from "contracts/interfaces/modules/base/IModule.sol"; +import { IIPAccount } from "contracts/interfaces/IIPAccount.sol"; +import { IIPAccountRegistry } from "contracts/interfaces/registries/IIPAccountRegistry.sol"; +import { IPAccountChecker } from "contracts/lib/registries/IPAccountChecker.sol"; +import { IModuleRegistry } from "contracts/interfaces/registries/IModuleRegistry.sol"; contract MockModule is IModule { using IPAccountChecker for IIPAccountRegistry; @@ -24,7 +25,7 @@ contract MockModule is IModule { return param; } - function executeNoReturn(string memory) view external { + function executeNoReturn(string memory) external view { require(ipAccountRegistry.isIpAccount(msg.sender), "MockModule: caller is not ipAccount"); } diff --git a/test/foundry/mocks/MockModuleRegistry.sol b/test/foundry/mocks/MockModuleRegistry.sol index c34ba289..e901e127 100644 --- a/test/foundry/mocks/MockModuleRegistry.sol +++ b/test/foundry/mocks/MockModuleRegistry.sol @@ -2,12 +2,10 @@ pragma solidity ^0.8.23; import { Strings } from "@openzeppelin/contracts/utils/Strings.sol"; -import { IModuleRegistry } from "contracts/interfaces/registries/IModuleRegistry.sol"; import { REGISTRATION_MODULE_KEY } from "contracts/lib/modules/Module.sol"; /// @title Mock Module Registry Contract contract MockModuleRegistry { - address public immutable REGISTRATION_MODULE; constructor(address registrationModule) { diff --git a/test/foundry/mocks/MockOrchestratorModule.sol b/test/foundry/mocks/MockOrchestratorModule.sol index c6a1d482..d1e82e0b 100644 --- a/test/foundry/mocks/MockOrchestratorModule.sol +++ b/test/foundry/mocks/MockOrchestratorModule.sol @@ -1,10 +1,10 @@ // SPDX-License-Identifier: MIT -pragma solidity ^0.8.21; +pragma solidity ^0.8.23; -import "contracts/interfaces/modules/base/IModule.sol"; -import "contracts/interfaces/IIPAccount.sol"; -import "contracts/interfaces/registries/IModuleRegistry.sol"; -import "contracts/interfaces/registries/IIPAccountRegistry.sol"; +import { IModule } from "contracts/interfaces/modules/base/IModule.sol"; +import { IIPAccount } from "contracts/interfaces/IIPAccount.sol"; +import { IModuleRegistry } from "contracts/interfaces/registries/IModuleRegistry.sol"; +import { IIPAccountRegistry } from "contracts/interfaces/registries/IIPAccountRegistry.sol"; import { IPAccountChecker } from "contracts/lib/registries/IPAccountChecker.sol"; import { IIPAccount } from "contracts/interfaces/IIPAccount.sol"; diff --git a/test/foundry/mocks/MockRoyaltyPolicyLS.sol b/test/foundry/mocks/MockRoyaltyPolicyLS.sol index 3b611384..3ec8bd29 100644 --- a/test/foundry/mocks/MockRoyaltyPolicyLS.sol +++ b/test/foundry/mocks/MockRoyaltyPolicyLS.sol @@ -34,7 +34,7 @@ contract MockRoyaltyPolicyLS is IRoyaltyPolicyLS, ERC1155Holder { ROYALTY_MODULE = _royaltyModule; } - function initPolicy(address _ipId, address[] calldata _parentIpIds, bytes calldata _data) external onlyRoyaltyModule { + function initPolicy(address _ipId, address[] calldata, bytes calldata) external onlyRoyaltyModule { royaltyData[_ipId] = LSRoyaltyData({ splitClone: address(0x1), claimer: address(0x2), @@ -67,11 +67,11 @@ contract MockRoyaltyPolicyLS is IRoyaltyPolicyLS, ERC1155Holder { function claimRoyalties(address _account, uint256 _withdrawETH, ERC20[] calldata _tokens) external pure {} - function _checkRoyaltyStackIsValid(address[] calldata _parentIpIds, uint32 _minRoyalty) internal pure returns (uint32, uint32) { + function _checkRoyaltyStackIsValid(address[] calldata, uint32) internal pure returns (uint32, uint32) { return (0, 0); } - function _deploySplitClone(address _ipId, address _claimer, uint32 royaltyStack) internal pure returns (address) { + function _deploySplitClone(address, address, uint32) internal pure returns (address) { return address(0xbeef); } diff --git a/test/foundry/mocks/licensing/MintPaymentPolicyFrameworkManager.sol b/test/foundry/mocks/licensing/MintPaymentPolicyFrameworkManager.sol index 2f8114b9..30c5811a 100644 --- a/test/foundry/mocks/licensing/MintPaymentPolicyFrameworkManager.sol +++ b/test/foundry/mocks/licensing/MintPaymentPolicyFrameworkManager.sol @@ -3,11 +3,8 @@ pragma solidity ^0.8.23; // external import { IERC20 } from "@openzeppelin/contracts/token/ERC20/IERC20.sol"; -import { ERC165, IERC165 } from "@openzeppelin/contracts/utils/introspection/ERC165.sol"; // contracts -import { Errors } from "contracts/lib/Errors.sol"; -import { Licensing } from "contracts/lib/Licensing.sol"; import { BasePolicyFrameworkManager } from "contracts/modules/licensing/BasePolicyFrameworkManager.sol"; import { IPolicyFrameworkManager } from "contracts/interfaces/modules/licensing/IPolicyFrameworkManager.sol"; @@ -75,12 +72,13 @@ contract MintPaymentPolicyFrameworkManager is BasePolicyFrameworkManager { address, // parentIpId bytes calldata // policyData ) external view returns (IPolicyFrameworkManager.VerifyLinkResponse memory) { - return IPolicyFrameworkManager.VerifyLinkResponse({ - isLinkingAllowed: true, - isRoyaltyRequired: false, - royaltyPolicy: royaltyPolicy, - royaltyDerivativeRevShare: 0 - }); + return + IPolicyFrameworkManager.VerifyLinkResponse({ + isLinkingAllowed: true, + isRoyaltyRequired: false, + royaltyPolicy: royaltyPolicy, + royaltyDerivativeRevShare: 0 + }); } function verifyTransfer( @@ -93,7 +91,7 @@ contract MintPaymentPolicyFrameworkManager is BasePolicyFrameworkManager { return true; } - function policyToJson(bytes memory policyData) public pure returns (string memory) { + function policyToJson(bytes memory) public pure returns (string memory) { return "MintPaymentPolicyFrameworkManager"; } diff --git a/test/foundry/mocks/licensing/MockPolicyFrameworkManager.sol b/test/foundry/mocks/licensing/MockPolicyFrameworkManager.sol index 27c19f53..600b0ca7 100644 --- a/test/foundry/mocks/licensing/MockPolicyFrameworkManager.sol +++ b/test/foundry/mocks/licensing/MockPolicyFrameworkManager.sol @@ -1,11 +1,7 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.23; -// external -import { ERC165, IERC165 } from "@openzeppelin/contracts/utils/introspection/ERC165.sol"; // contracts -import { Errors } from "contracts/lib/Errors.sol"; -import { Licensing } from "contracts/lib/Licensing.sol"; import { BasePolicyFrameworkManager } from "contracts/modules/licensing/BasePolicyFrameworkManager.sol"; import { IPolicyFrameworkManager } from "contracts/interfaces/modules/licensing/IPolicyFrameworkManager.sol"; @@ -56,7 +52,7 @@ contract MockPolicyFrameworkManager is BasePolicyFrameworkManager { ) external pure override returns (IPolicyFrameworkManager.VerifyLinkResponse memory) { MockPolicy memory policy = abi.decode(data, (MockPolicy)); return - IPolicyFrameworkManager.VerifyLinkResponse({ + IPolicyFrameworkManager.VerifyLinkResponse({ isLinkingAllowed: policy.returnVerifyLink, isRoyaltyRequired: false, royaltyPolicy: address(0), @@ -64,10 +60,10 @@ contract MockPolicyFrameworkManager is BasePolicyFrameworkManager { }); } - function policyToJson(bytes memory policyData) public pure returns (string memory) { + function policyToJson(bytes memory) public pure returns (string memory) { return "MockPolicyFrameworkManager"; } - + function processInheritedPolicies( bytes memory aggregator, uint256, // policyId, diff --git a/test/foundry/modules/ModuleBase.t.sol b/test/foundry/modules/ModuleBase.t.sol index 10b39400..013c372a 100644 --- a/test/foundry/modules/ModuleBase.t.sol +++ b/test/foundry/modules/ModuleBase.t.sol @@ -3,29 +3,17 @@ pragma solidity ^0.8.23; import { ERC6551Registry } from "@erc6551/ERC6551Registry.sol"; -import { MockAccessController } from "test/foundry/mocks/MockAccessController.sol"; import { BaseTest } from "test/foundry/utils/BaseTest.sol"; import { LicenseRegistry } from "contracts/registries/LicenseRegistry.sol"; import { LicensingModule } from "contracts/modules/licensing/LicensingModule.sol"; import { IModule } from "contracts/interfaces/modules/base/IModule.sol"; -import { BaseModule } from "contracts/modules/BaseModule.sol"; import { ModuleRegistry } from "contracts/registries/ModuleRegistry.sol"; import { AccessController } from "contracts/AccessController.sol"; -import { IAccessController } from "contracts/interfaces/IAccessController.sol"; -import { IModuleRegistry } from "contracts/interfaces/registries/IModuleRegistry.sol"; import { IPMetadataProvider } from "contracts/registries/metadata/IPMetadataProvider.sol"; import { IPAssetRegistry } from "contracts/registries/IPAssetRegistry.sol"; -import { IPAccountRegistry } from "contracts/registries/IPAccountRegistry.sol"; -import { MockModuleRegistry } from "test/foundry/mocks/MockModuleRegistry.sol"; -import { IIPAssetRegistry } from "contracts/interfaces/registries/IIPAssetRegistry.sol"; import { IPAccountImpl } from "contracts/IPAccountImpl.sol"; -import { MockERC721 } from "test/foundry/mocks/MockERC721.sol"; -import { IP } from "contracts/lib/IP.sol"; -import { Errors } from "contracts/lib/Errors.sol"; import { Governance } from "contracts/governance/Governance.sol"; import { RoyaltyModule } from "contracts/modules/royalty-module/RoyaltyModule.sol"; -import { IPResolver } from "contracts/resolvers/IPResolver.sol"; -import { RegistrationModule } from "contracts/modules/RegistrationModule.sol"; /// @title Module Base Test Contract /// @notice Base contract for testing standard module functionality. @@ -73,18 +61,8 @@ abstract contract ModuleBaseTest is BaseTest { address(ipAssetRegistry), address(licenseRegistry), address(royaltyModule) - ); - licenseRegistry.setLicensingModule(address(licensingModule)); - IPResolver ipResolver = new IPResolver( - address(accessController), - address(ipAssetRegistry) - ); - RegistrationModule registrationModule = new RegistrationModule( - address(accessController), - address(ipAssetRegistry), - address(licensingModule), - address(ipResolver) ); + licenseRegistry.setLicensingModule(address(licensingModule)); baseModule = IModule(_deployModule()); accessController.initialize(address(ipAssetRegistry), address(moduleRegistry)); royaltyModule.setLicensingModule(address(licensingModule)); diff --git a/test/foundry/modules/TaggingModule.t.sol b/test/foundry/modules/TaggingModule.t.sol index 1a4362af..8f3737dd 100644 --- a/test/foundry/modules/TaggingModule.t.sol +++ b/test/foundry/modules/TaggingModule.t.sol @@ -1,11 +1,10 @@ // SPDX-License-Identifier: MIT -pragma solidity ^0.8.21; +pragma solidity ^0.8.23; -import "forge-std/Test.sol"; -import "contracts/lib/Errors.sol"; +import { Test } from "forge-std/Test.sol"; import { TaggingModule } from "contracts/modules/tagging/TaggingModule.sol"; import { ShortStringOps } from "contracts/utils/ShortStringOps.sol"; -import { ShortString, ShortStrings } from "@openzeppelin/contracts/utils/ShortStrings.sol"; +import { ShortStrings } from "@openzeppelin/contracts/utils/ShortStrings.sol"; contract TaggingModuleTest is Test { using ShortStrings for *; diff --git a/test/foundry/modules/dispute/ArbitrationPolicySP.t.sol b/test/foundry/modules/dispute/ArbitrationPolicySP.t.sol index 6f269461..60a73964 100644 --- a/test/foundry/modules/dispute/ArbitrationPolicySP.t.sol +++ b/test/foundry/modules/dispute/ArbitrationPolicySP.t.sol @@ -2,18 +2,17 @@ pragma solidity ^0.8.23; // external -import {IERC20} from "@openzeppelin/contracts/token/ERC20/IERC20.sol"; +import { IERC20 } from "@openzeppelin/contracts/token/ERC20/IERC20.sol"; import { Strings } from "@openzeppelin/contracts/utils/Strings.sol"; import { ERC6551AccountLib } from "@erc6551/lib/ERC6551AccountLib.sol"; // contracts -import {Errors} from "contracts/lib/Errors.sol"; -import {ArbitrationPolicySP} from "contracts/modules/dispute-module/policies/ArbitrationPolicySP.sol"; -import { IP } from "contracts/lib/IP.sol"; +import { Errors } from "contracts/lib/Errors.sol"; +import { ArbitrationPolicySP } from "contracts/modules/dispute-module/policies/ArbitrationPolicySP.sol"; // test +// solhint-disable-next-line max-line-length import { UMLPolicyGenericParams, UMLPolicyCommercialParams, UMLPolicyDerivativeParams } from "test/foundry/integration/shared/LicenseHelper.sol"; -import { MintPaymentPolicyFrameworkManager } from "test/foundry/mocks/licensing/MintPaymentPolicyFrameworkManager.sol"; import { MockERC721 } from "test/foundry/mocks/MockERC721.sol"; -import { TestHelper } from "test/utils/TestHelper.sol"; +import { TestHelper } from "test/foundry/utils/TestHelper.sol"; contract TestArbitrationPolicySP is TestHelper { event GovernanceWithdrew(uint256 amount); @@ -118,12 +117,17 @@ contract TestArbitrationPolicySP is TestHelper { uint256 arbitrationPrice = 1000; address governance = address(3); - ArbitrationPolicySP arbitrationPolicySP = new ArbitrationPolicySP(disputeModule, paymentToken, arbitrationPrice, address(3)); + ArbitrationPolicySP arbitrationPolicySP = new ArbitrationPolicySP( + disputeModule, + paymentToken, + arbitrationPrice, + address(3) + ); assertEq(address(arbitrationPolicySP.DISPUTE_MODULE()), disputeModule); assertEq(address(arbitrationPolicySP.PAYMENT_TOKEN()), paymentToken); assertEq(arbitrationPolicySP.ARBITRATION_PRICE(), arbitrationPrice); - assertEq(arbitrationPolicySP.governance(), address(3)); + assertEq(arbitrationPolicySP.governance(), governance); } function test_ArbitrationPolicySP_onRaiseDispute_NotDisputeModule() public { diff --git a/test/foundry/modules/dispute/DisputeModule.t.sol b/test/foundry/modules/dispute/DisputeModule.t.sol index 2635bc4a..231aef8d 100644 --- a/test/foundry/modules/dispute/DisputeModule.t.sol +++ b/test/foundry/modules/dispute/DisputeModule.t.sol @@ -2,19 +2,17 @@ pragma solidity ^0.8.23; // external -import {IERC20} from "@openzeppelin/contracts/token/ERC20/IERC20.sol"; +import { IERC20 } from "@openzeppelin/contracts/token/ERC20/IERC20.sol"; import { Strings } from "@openzeppelin/contracts/utils/Strings.sol"; import { ERC6551AccountLib } from "@erc6551/lib/ERC6551AccountLib.sol"; // contracts -import {Errors} from "contracts/lib/Errors.sol"; -import {ShortStringOps} from "contracts/utils/ShortStringOps.sol"; -import {DisputeModule} from "contracts/modules/dispute-module/DisputeModule.sol"; -import { IP } from "contracts/lib/IP.sol"; +import { Errors } from "contracts/lib/Errors.sol"; +import { ShortStringOps } from "contracts/utils/ShortStringOps.sol"; // test +// solhint-disable-next-line max-line-length import { UMLPolicyGenericParams, UMLPolicyCommercialParams, UMLPolicyDerivativeParams } from "test/foundry/integration/shared/LicenseHelper.sol"; -import { MintPaymentPolicyFrameworkManager } from "test/foundry/mocks/licensing/MintPaymentPolicyFrameworkManager.sol"; import { MockERC721 } from "test/foundry/mocks/MockERC721.sol"; -import { TestHelper } from "test/utils/TestHelper.sol"; +import { TestHelper } from "test/foundry/utils/TestHelper.sol"; contract TestDisputeModule is TestHelper { event TagWhitelistUpdated(bytes32 tag, bool allowed); @@ -84,7 +82,6 @@ contract TestDisputeModule is TestHelper { }) ); - nft.mintId(deployer, 0); address expectedAddr = ERC6551AccountLib.computeAddress( @@ -223,16 +220,12 @@ contract TestDisputeModule is TestHelper { function test_DisputeModule_PolicySP_raiseDispute_revert_NotRegisteredIpId() public { vm.expectRevert(Errors.DisputeModule__NotRegisteredIpId.selector); - disputeModule.raiseDispute( - address(1), string("urlExample"), "PLAGIARISM", "" - ); + disputeModule.raiseDispute(address(1), string("urlExample"), "PLAGIARISM", ""); } function test_DisputeModule_PolicySP_raiseDispute_revert_NotWhitelistedDisputeTag() public { vm.expectRevert(Errors.DisputeModule__NotWhitelistedDisputeTag.selector); - disputeModule.raiseDispute( - ipAddr, string("urlExample"), "NOT_WHITELISTED", "" - ); + disputeModule.raiseDispute(ipAddr, string("urlExample"), "NOT_WHITELISTED", ""); } function test_DisputeModule_PolicySP_raiseDispute_revert_ZeroLinkToDisputeEvidence() public { @@ -358,7 +351,7 @@ contract TestDisputeModule is TestHelper { vm.stopPrank(); // set dispute judgement - (,,,,, bytes32 currentTagBefore) = disputeModule.disputes(1); + (, , , , , bytes32 currentTagBefore) = disputeModule.disputes(1); uint256 ipAccount1USDCBalanceBefore = USDC.balanceOf(ipAccount1); uint256 arbitrationPolicySPUSDCBalanceBefore = USDC.balanceOf(address(arbitrationPolicySP)); @@ -368,7 +361,7 @@ contract TestDisputeModule is TestHelper { vm.startPrank(arbitrationRelayer); disputeModule.setDisputeJudgement(1, true, ""); - (,,,,, bytes32 currentTagAfter) = disputeModule.disputes(1); + (, , , , , bytes32 currentTagAfter) = disputeModule.disputes(1); uint256 ipAccount1USDCBalanceAfter = USDC.balanceOf(ipAccount1); uint256 arbitrationPolicySPUSDCBalanceAfter = USDC.balanceOf(address(arbitrationPolicySP)); @@ -386,7 +379,7 @@ contract TestDisputeModule is TestHelper { vm.stopPrank(); // set dispute judgement - (,,,,, bytes32 currentTagBefore) = disputeModule.disputes(1); + (, , , , , bytes32 currentTagBefore) = disputeModule.disputes(1); uint256 ipAccount1USDCBalanceBefore = USDC.balanceOf(ipAccount1); uint256 arbitrationPolicySPUSDCBalanceBefore = USDC.balanceOf(address(arbitrationPolicySP)); @@ -396,7 +389,7 @@ contract TestDisputeModule is TestHelper { vm.startPrank(arbitrationRelayer); disputeModule.setDisputeJudgement(1, false, ""); - (,,,,, bytes32 currentTagAfter) = disputeModule.disputes(1); + (, , , , , bytes32 currentTagAfter) = disputeModule.disputes(1); uint256 ipAccount1USDCBalanceAfter = USDC.balanceOf(ipAccount1); uint256 arbitrationPolicySPUSDCBalanceAfter = USDC.balanceOf(address(arbitrationPolicySP)); @@ -429,7 +422,7 @@ contract TestDisputeModule is TestHelper { disputeModule.raiseDispute(ipAddr, string("urlExample"), "PLAGIARISM", ""); vm.stopPrank(); - (,,,,, bytes32 currentTagBeforeCancel) = disputeModule.disputes(1); + (, , , , , bytes32 currentTagBeforeCancel) = disputeModule.disputes(1); vm.startPrank(ipAccount1); vm.expectEmit(true, true, true, true, address(disputeModule)); @@ -438,7 +431,7 @@ contract TestDisputeModule is TestHelper { disputeModule.cancelDispute(1, ""); vm.stopPrank(); - (,,,,, bytes32 currentTagAfterCancel) = disputeModule.disputes(1); + (, , , , , bytes32 currentTagAfterCancel) = disputeModule.disputes(1); assertEq(currentTagBeforeCancel, bytes32("IN_DISPUTE")); assertEq(currentTagAfterCancel, bytes32(0)); @@ -473,7 +466,7 @@ contract TestDisputeModule is TestHelper { disputeModule.setDisputeJudgement(1, true, ""); vm.stopPrank(); - (,,,,, bytes32 currentTagBeforeResolve) = disputeModule.disputes(1); + (, , , , , bytes32 currentTagBeforeResolve) = disputeModule.disputes(1); // resolve dispute vm.startPrank(ipAccount1); @@ -482,7 +475,7 @@ contract TestDisputeModule is TestHelper { disputeModule.resolveDispute(1); - (,,,,, bytes32 currentTagAfterResolve) = disputeModule.disputes(1); + (, , , , , bytes32 currentTagAfterResolve) = disputeModule.disputes(1); assertEq(currentTagBeforeResolve, bytes32("PLAGIARISM")); assertEq(currentTagAfterResolve, bytes32(0)); diff --git a/test/foundry/modules/licensing/LicensingModule.t.sol b/test/foundry/modules/licensing/LicensingModule.t.sol index 1392e577..f79a5c37 100644 --- a/test/foundry/modules/licensing/LicensingModule.t.sol +++ b/test/foundry/modules/licensing/LicensingModule.t.sol @@ -20,6 +20,7 @@ import { RoyaltyModule } from "contracts/modules/royalty-module/RoyaltyModule.so import { IPAssetRegistry } from "contracts/registries/IPAssetRegistry.sol"; // test +// solhint-disable-next-line max-line-length import { MockPolicyFrameworkManager, MockPolicyFrameworkConfig, MockPolicy } from "test/foundry/mocks/licensing/MockPolicyFrameworkManager.sol"; import { MockAccessController } from "test/foundry/mocks/MockAccessController.sol"; import { MockERC721 } from "test/foundry/mocks/MockERC721.sol"; @@ -200,9 +201,7 @@ contract LicensingModuleTest is Test { assertFalse(isInherited); // Adding different policy to same ipId - policy = abi.encode( - MockPolicy({ returnVerifyLink: true, returnVerifyMint: false}) - ); + policy = abi.encode(MockPolicy({ returnVerifyLink: true, returnVerifyMint: false })); vm.prank(address(module1)); uint256 policyId2 = licensingModule.registerPolicy(true, policy); vm.prank(ipOwner); @@ -294,9 +293,7 @@ contract LicensingModuleTest is Test { licensingModule.registerPolicyFrameworkManager(address(module1)); bytes memory policy = _createPolicy(); - bytes memory policy2 = abi.encode( - MockPolicy({ returnVerifyLink: true, returnVerifyMint: true }) - ); + bytes memory policy2 = abi.encode(MockPolicy({ returnVerifyLink: true, returnVerifyMint: true })); IPAccountImpl ipAccount1 = IPAccountImpl(payable(ipId1)); vm.startPrank(address(module1)); @@ -396,9 +393,7 @@ contract LicensingModuleTest is Test { function test_LicensingModule_singleTransfer_revert_verifyFalse() public { licensingModule.registerPolicyFrameworkManager(address(module1)); - bytes memory policy = abi.encode( - MockPolicy({ returnVerifyLink: true, returnVerifyMint: true }) - ); + bytes memory policy = abi.encode(MockPolicy({ returnVerifyLink: true, returnVerifyMint: true })); vm.prank(address(module1)); uint256 policyId = licensingModule.registerPolicy(false, policy); vm.prank(ipOwner); @@ -520,8 +515,11 @@ contract LicensingModuleTest is Test { )); */ /* solhint-enable */ + + /* solhint-disable */ string memory expectedJson = "eyJuYW1lIjogIlN0b3J5IFByb3RvY29sIExpY2Vuc2UgTkZUIiwgImRlc2NyaXB0aW9uIjogIkxpY2Vuc2UgYWdyZWVtZW50IHN0YXRpbmcgdGhlIHRlcm1zIG9mIGEgU3RvcnkgUHJvdG9jb2wgSVBBc3NldCIsICJhdHRyaWJ1dGVzIjogW3sidHJhaXRfdHlwZSI6ICJBdHRyaWJ1dGlvbiIsICJ2YWx1ZSI6ICJ0cnVlIn0seyJ0cmFpdF90eXBlIjogIlRyYW5zZmVyYWJsZSIsICJ2YWx1ZSI6ICJ0cnVlIn0seyJ0cmFpdF90eXBlIjogIkNvbW1lcmljYWwgVXNlIiwgInZhbHVlIjogInRydWUifSx7InRyYWl0X3R5cGUiOiAiY29tbWVyY2lhbEF0dHJpYnV0aW9uIiwgInZhbHVlIjogInRydWUifSx7InRyYWl0X3R5cGUiOiAiY29tbWVyY2lhbFJldlNoYXJlIiwgInZhbHVlIjogMH0seyJ0cmFpdF90eXBlIjogImNvbW1lcmNpYWxpemVycyIsICJ2YWx1ZSI6IFsiY29tbWVyY2lhbGl6ZXIxIiwiY29tbWVyY2lhbGl6ZXIyIl19LCB7InRyYWl0X3R5cGUiOiAiZGVyaXZhdGl2ZXNBbGxvd2VkIiwgInZhbHVlIjogInRydWUifSx7InRyYWl0X3R5cGUiOiAiZGVyaXZhdGl2ZXNBdHRyaWJ1dGlvbiIsICJ2YWx1ZSI6ICJ0cnVlIn0seyJ0cmFpdF90eXBlIjogImRlcml2YXRpdmVzQXBwcm92YWwiLCAidmFsdWUiOiAidHJ1ZSJ9LHsidHJhaXRfdHlwZSI6ICJkZXJpdmF0aXZlc1JlY2lwcm9jYWwiLCAidmFsdWUiOiAidHJ1ZSJ9LHsidHJhaXRfdHlwZSI6ICJkZXJpdmF0aXZlc1JldlNoYXJlIiwgInZhbHVlIjogMH0seyJ0cmFpdF90eXBlIjogInRlcnJpdG9yaWVzIiwgInZhbHVlIjogWyJ0ZXJyaXRvcnkxIl19LCB7InRyYWl0X3R5cGUiOiAiZGlzdHJpYnV0aW9uQ2hhbm5lbHMiLCAidmFsdWUiOiBbImRpc3RyaWJ1dGlvbkNoYW5uZWwxIl19XX0="; + /* solhint-enable */ string memory expectedUri = string(abi.encodePacked("data:application/json;base64,", expectedJson)); diff --git a/test/foundry/modules/licensing/UMLPolicyFramework.derivation.t.sol b/test/foundry/modules/licensing/UMLPolicyFramework.derivation.t.sol index 2b2341ea..37086d66 100644 --- a/test/foundry/modules/licensing/UMLPolicyFramework.derivation.t.sol +++ b/test/foundry/modules/licensing/UMLPolicyFramework.derivation.t.sol @@ -3,7 +3,7 @@ pragma solidity ^0.8.23; import { Errors } from "contracts/lib/Errors.sol"; import { UMLPolicyFrameworkManager } from "contracts/modules/licensing/UMLPolicyFrameworkManager.sol"; -import { TestHelper } from "test/utils/TestHelper.sol"; +import { TestHelper } from "test/foundry/utils/TestHelper.sol"; contract UMLPolicyFrameworkCompatibilityTest is TestHelper { UMLPolicyFrameworkManager internal umlFramework; @@ -219,4 +219,4 @@ contract UMLPolicyFrameworkCompatibilityTest is TestHelper { vm.prank(alice); licensingModule.addPolicyToIp(ipId2, _getUmlPolicyId("comm_reciprocal")); } -} \ No newline at end of file +} diff --git a/test/foundry/modules/licensing/UMLPolicyFramework.multi-parent.sol b/test/foundry/modules/licensing/UMLPolicyFramework.multi-parent.sol index bab7ab52..0a3928d2 100644 --- a/test/foundry/modules/licensing/UMLPolicyFramework.multi-parent.sol +++ b/test/foundry/modules/licensing/UMLPolicyFramework.multi-parent.sol @@ -7,10 +7,9 @@ import { UMLFrameworkErrors } from "contracts/lib/UMLFrameworkErrors.sol"; import { UMLPolicy } from "contracts/interfaces/modules/licensing/IUMLPolicyFrameworkManager.sol"; import { UMLPolicyFrameworkManager } from "contracts/modules/licensing/UMLPolicyFrameworkManager.sol"; import { IPolicyFrameworkManager } from "contracts/interfaces/modules/licensing/IPolicyFrameworkManager.sol"; -import { TestHelper } from "test/utils/TestHelper.sol"; +import { TestHelper } from "test/foundry/utils/TestHelper.sol"; contract UMLPolicyFrameworkMultiParentTest is TestHelper { - UMLPolicyFrameworkManager internal umlFramework; string internal licenseUrl = "https://example.com/license"; address internal bob = address(0x111); @@ -24,13 +23,22 @@ contract UMLPolicyFrameworkMultiParentTest is TestHelper { mapping(address => address) internal ipIdToOwner; - modifier withUMLPolicySimple(string memory name, bool commercial, bool derivatives, bool reciprocal) { + modifier withUMLPolicySimple( + string memory name, + bool commercial, + bool derivatives, + bool reciprocal + ) { _mapUMLPolicySimple(name, commercial, derivatives, reciprocal, 100, 100); _addUMLPolicyFromMapping(name, address(umlFramework)); _; } - modifier withLicense(string memory policyName, address ipId, address owner) { + modifier withLicense( + string memory policyName, + address ipId, + address owner + ) { uint256 policyId = _getUmlPolicyId(policyName); Licensing.Policy memory policy = licensingModule.policy(policyId); @@ -45,7 +53,7 @@ contract UMLPolicyFrameworkMultiParentTest is TestHelper { function setUp() public override { super.setUp(); - + nft = erc721.ape; umlFramework = new UMLPolicyFrameworkManager( @@ -80,11 +88,12 @@ contract UMLPolicyFrameworkMultiParentTest is TestHelper { } function test_UMLPolicyFramework_multiParent_AliceSets3Parents_SamePolicyReciprocal() + public withUMLPolicySimple("reciprocal", true, true, true) withLicense("reciprocal", ipId1, alice) withLicense("reciprocal", ipId2, alice) withLicense("reciprocal", ipId3, alice) - public { + { vm.prank(alice); licensingModule.linkIpToParents(licenses, ipId4, 0); assertEq(licensingModule.totalParentsForIpId(ipId4), 3); @@ -99,24 +108,24 @@ contract UMLPolicyFrameworkMultiParentTest is TestHelper { } function test_UMLPolicyFramework_multiParent_revert_AliceSets3Parents_OneNonReciprocal() + public withUMLPolicySimple("reciprocal", true, true, true) withUMLPolicySimple("non_reciprocal", true, true, false) withLicense("reciprocal", ipId1, alice) withLicense("non_reciprocal", ipId2, alice) withLicense("reciprocal", ipId3, alice) - public { - vm.expectRevert( - UMLFrameworkErrors.UMLPolicyFrameworkManager__ReciprocalValueMismatch.selector - ); + { + vm.expectRevert(UMLFrameworkErrors.UMLPolicyFrameworkManager__ReciprocalValueMismatch.selector); vm.prank(alice); licensingModule.linkIpToParents(licenses, ipId4, 0); } function test_UMLPolicyFramework_multiParent_revert_AliceSets3Parents_3ReciprocalButDifferent() + public withUMLPolicySimple("reciprocal", true, true, true) withLicense("reciprocal", ipId1, alice) withLicense("reciprocal", ipId2, alice) - public { + { // Save a new policy (change some value to change the policyId) _mapUMLPolicySimple("other", true, true, true, 100, 100); _getMappedUmlPolicy("other").attribution = !_getMappedUmlPolicy("other").attribution; @@ -125,18 +134,30 @@ contract UMLPolicyFrameworkMultiParentTest is TestHelper { mockRoyaltyPolicyLS.setMinRoyalty(ipId3, 100); vm.prank(ipId3); licenses.push(licensingModule.mintLicense(_getUmlPolicyId("other"), ipId3, 1, alice)); - vm.expectRevert( - UMLFrameworkErrors.UMLPolicyFrameworkManager__ReciprocalButDifferentPolicyIds.selector - ); + vm.expectRevert(UMLFrameworkErrors.UMLPolicyFrameworkManager__ReciprocalButDifferentPolicyIds.selector); vm.prank(alice); licensingModule.linkIpToParents(licenses, ipId4, 0); } function test_UMLPolicyFramework_multiParent_NonReciprocalCommercial() public { // First we create 2 policies. - _mapUMLPolicySimple({name: "pol_a", commercial: true, derivatives: true, reciprocal: false, commercialRevShare: 100, derivativesRevShare: 100}); + _mapUMLPolicySimple({ + name: "pol_a", + commercial: true, + derivatives: true, + reciprocal: false, + commercialRevShare: 100, + derivativesRevShare: 100 + }); UMLPolicy memory polA = _getMappedUmlPolicy("pol_a"); - _mapUMLPolicySimple({name: "pol_b", commercial: true, derivatives: true, reciprocal: false, commercialRevShare: 100, derivativesRevShare: 100}); + _mapUMLPolicySimple({ + name: "pol_b", + commercial: true, + derivatives: true, + reciprocal: false, + commercialRevShare: 100, + derivativesRevShare: 100 + }); UMLPolicy memory polB = _getMappedUmlPolicy("pol_b"); // We set some indifferents polA.attribution = true; @@ -149,9 +170,23 @@ contract UMLPolicyFrameworkMultiParentTest is TestHelper { function test_UMLPolicyFramework_multiParent_revert_NonReciprocalCommercial() public { // First we create 2 policies. - _mapUMLPolicySimple({name: "pol_a", commercial: true, derivatives: true, reciprocal: false, commercialRevShare: 100, derivativesRevShare: 100}); + _mapUMLPolicySimple({ + name: "pol_a", + commercial: true, + derivatives: true, + reciprocal: false, + commercialRevShare: 100, + derivativesRevShare: 100 + }); UMLPolicy memory polA = _getMappedUmlPolicy("pol_a"); - _mapUMLPolicySimple({name: "pol_b", commercial: true, derivatives: true, reciprocal: false, commercialRevShare: 100, derivativesRevShare: 100}); + _mapUMLPolicySimple({ + name: "pol_b", + commercial: true, + derivatives: true, + reciprocal: false, + commercialRevShare: 100, + derivativesRevShare: 100 + }); UMLPolicy memory polB = _getMappedUmlPolicy("pol_b"); // We set some indifferents polA.attribution = true; @@ -165,15 +200,30 @@ contract UMLPolicyFrameworkMultiParentTest is TestHelper { polB.derivativesRevShare = 0; polB.royaltyPolicy = address(0x0); // TODO: passing in two different royaltyPolicy addresses + // solhint-disable-next-line max-line-length // _testRevertCompat(polA, polB, UMLFrameworkErrors.UMLPolicyFrameworkManager__CommercialValueMismatch.selector); _testRevertCompat(polA, polB, Errors.LicensingModule__IncompatibleLicensorCommercialPolicy.selector); } function test_UMLPolicyFramework_multiParent_NonReciprocalDerivatives() public { // First we create 2 policies. - _mapUMLPolicySimple({name: "pol_a", commercial: true, derivatives: true, reciprocal: false, commercialRevShare: 100, derivativesRevShare: 100}); + _mapUMLPolicySimple({ + name: "pol_a", + commercial: true, + derivatives: true, + reciprocal: false, + commercialRevShare: 100, + derivativesRevShare: 100 + }); UMLPolicy memory polA = _getMappedUmlPolicy("pol_a"); - _mapUMLPolicySimple({name: "pol_b", commercial: true, derivatives: true, reciprocal: false, commercialRevShare: 100, derivativesRevShare: 100}); + _mapUMLPolicySimple({ + name: "pol_b", + commercial: true, + derivatives: true, + reciprocal: false, + commercialRevShare: 100, + derivativesRevShare: 100 + }); UMLPolicy memory polB = _getMappedUmlPolicy("pol_b"); // We set some indifferents polA.attribution = true; @@ -187,9 +237,23 @@ contract UMLPolicyFrameworkMultiParentTest is TestHelper { function test_UMLPolicyFramework_multiParent_revert_NonReciprocalDerivatives() public { // First we create 2 policies. - _mapUMLPolicySimple({name: "pol_a", commercial: true, derivatives: true, reciprocal: false, commercialRevShare: 100, derivativesRevShare: 100}); + _mapUMLPolicySimple({ + name: "pol_a", + commercial: true, + derivatives: true, + reciprocal: false, + commercialRevShare: 100, + derivativesRevShare: 100 + }); UMLPolicy memory polA = _getMappedUmlPolicy("pol_a"); - _mapUMLPolicySimple({name: "pol_b", commercial: true, derivatives: true, reciprocal: false, commercialRevShare: 100, derivativesRevShare: 100}); + _mapUMLPolicySimple({ + name: "pol_b", + commercial: true, + derivatives: true, + reciprocal: false, + commercialRevShare: 100, + derivativesRevShare: 100 + }); UMLPolicy memory polB = _getMappedUmlPolicy("pol_b"); // We set some indifferents polA.attribution = true; @@ -203,15 +267,30 @@ contract UMLPolicyFrameworkMultiParentTest is TestHelper { polB.derivativesRevShare = 0; // TODO: passing in two different royaltyPolicy addresses + // solhint-disable-next-line max-line-length // _testRevertCompat(polA, polB, UMLFrameworkErrors.UMLPolicyFrameworkManager__DerivativesValueMismatch.selector); _testRevertCompat(polA, polB, Errors.LicensingModule__IncompatibleRoyaltyPolicyDerivativeRevShare.selector); } function test_UMLPolicyFramework_multiParent_NonReciprocalTerritories() public { // First we create 2 policies. - _mapUMLPolicySimple({name: "pol_a", commercial: true, derivatives: true, reciprocal: false, commercialRevShare: 100, derivativesRevShare: 100}); + _mapUMLPolicySimple({ + name: "pol_a", + commercial: true, + derivatives: true, + reciprocal: false, + commercialRevShare: 100, + derivativesRevShare: 100 + }); UMLPolicy memory polA = _getMappedUmlPolicy("pol_a"); - _mapUMLPolicySimple({name: "pol_b", commercial: true, derivatives: true, reciprocal: false, commercialRevShare: 100, derivativesRevShare: 100}); + _mapUMLPolicySimple({ + name: "pol_b", + commercial: true, + derivatives: true, + reciprocal: false, + commercialRevShare: 100, + derivativesRevShare: 100 + }); UMLPolicy memory polB = _getMappedUmlPolicy("pol_b"); // Territories (success same) @@ -228,14 +307,27 @@ contract UMLPolicyFrameworkMultiParentTest is TestHelper { // polB.transferable = !polB.transferable; // generates different policyId // vm.expectRevert(Errors.RoyaltyModule__AlreadySetRoyaltyPolicy.selector); // _testSuccessCompat(polA, polB, 4); - } function test_UMLPolicyFramework_multiParent_revert_NonReciprocalTerritories() public { // First we create 2 policies. - _mapUMLPolicySimple({name: "pol_a", commercial: true, derivatives: true, reciprocal: false, commercialRevShare: 100, derivativesRevShare: 100}); + _mapUMLPolicySimple({ + name: "pol_a", + commercial: true, + derivatives: true, + reciprocal: false, + commercialRevShare: 100, + derivativesRevShare: 100 + }); UMLPolicy memory polA = _getMappedUmlPolicy("pol_a"); - _mapUMLPolicySimple({name: "pol_b", commercial: true, derivatives: true, reciprocal: false, commercialRevShare: 100, derivativesRevShare: 100}); + _mapUMLPolicySimple({ + name: "pol_b", + commercial: true, + derivatives: true, + reciprocal: false, + commercialRevShare: 100, + derivativesRevShare: 100 + }); UMLPolicy memory polB = _getMappedUmlPolicy("pol_b"); // We set some indifferents polA.attribution = true; @@ -253,9 +345,23 @@ contract UMLPolicyFrameworkMultiParentTest is TestHelper { function test_UMLPolicyFramework_multiParent_NonReciprocalDistributionChannels() public { // First we create 2 policies. - _mapUMLPolicySimple({name: "pol_a", commercial: true, derivatives: true, reciprocal: false, commercialRevShare: 100, derivativesRevShare: 100}); + _mapUMLPolicySimple({ + name: "pol_a", + commercial: true, + derivatives: true, + reciprocal: false, + commercialRevShare: 100, + derivativesRevShare: 100 + }); UMLPolicy memory polA = _getMappedUmlPolicy("pol_a"); - _mapUMLPolicySimple({name: "pol_b", commercial: true, derivatives: true, reciprocal: false, commercialRevShare: 100, derivativesRevShare: 100}); + _mapUMLPolicySimple({ + name: "pol_b", + commercial: true, + derivatives: true, + reciprocal: false, + commercialRevShare: 100, + derivativesRevShare: 100 + }); UMLPolicy memory polB = _getMappedUmlPolicy("pol_b"); // Territories (success same) @@ -272,14 +378,27 @@ contract UMLPolicyFrameworkMultiParentTest is TestHelper { // polB.transferable = !polB.transferable; // generates different policyId // vm.expectRevert(Errors.RoyaltyModule__AlreadySetRoyaltyPolicy.selector); // _testSuccessCompat(polA, polB, 4); - } function test_UMLPolicyFramework_multiParent_revert_NonReciprocalDistributionChannels() public { // First we create 2 policies. - _mapUMLPolicySimple({name: "pol_a", commercial: true, derivatives: true, reciprocal: false, commercialRevShare: 100, derivativesRevShare: 100}); + _mapUMLPolicySimple({ + name: "pol_a", + commercial: true, + derivatives: true, + reciprocal: false, + commercialRevShare: 100, + derivativesRevShare: 100 + }); UMLPolicy memory polA = _getMappedUmlPolicy("pol_a"); - _mapUMLPolicySimple({name: "pol_b", commercial: true, derivatives: true, reciprocal: false, commercialRevShare: 100, derivativesRevShare: 100}); + _mapUMLPolicySimple({ + name: "pol_b", + commercial: true, + derivatives: true, + reciprocal: false, + commercialRevShare: 100, + derivativesRevShare: 100 + }); UMLPolicy memory polB = _getMappedUmlPolicy("pol_b"); // We set some indifferents polA.attribution = true; @@ -297,9 +416,23 @@ contract UMLPolicyFrameworkMultiParentTest is TestHelper { function test_UMLPolicyFramework_multiParent_NonReciprocalContentRestrictions() public { // First we create 2 policies. - _mapUMLPolicySimple({name: "pol_a", commercial: true, derivatives: true, reciprocal: false, commercialRevShare: 100, derivativesRevShare: 100}); + _mapUMLPolicySimple({ + name: "pol_a", + commercial: true, + derivatives: true, + reciprocal: false, + commercialRevShare: 100, + derivativesRevShare: 100 + }); UMLPolicy memory polA = _getMappedUmlPolicy("pol_a"); - _mapUMLPolicySimple({name: "pol_b", commercial: true, derivatives: true, reciprocal: false, commercialRevShare: 100, derivativesRevShare: 100}); + _mapUMLPolicySimple({ + name: "pol_b", + commercial: true, + derivatives: true, + reciprocal: false, + commercialRevShare: 100, + derivativesRevShare: 100 + }); UMLPolicy memory polB = _getMappedUmlPolicy("pol_b"); // Territories (success same) @@ -316,14 +449,27 @@ contract UMLPolicyFrameworkMultiParentTest is TestHelper { // polB.transferable = !polB.transferable; // generates different policyId // vm.expectRevert(Errors.RoyaltyModule__AlreadySetRoyaltyPolicy.selector); // _testSuccessCompat(polA, polB, 4); - } function test_UMLPolicyFramework_multiParent_revert_NonReciprocalContentRestrictions() public { // First we create 2 policies. - _mapUMLPolicySimple({name: "pol_a", commercial: true, derivatives: true, reciprocal: false, commercialRevShare: 100, derivativesRevShare: 100}); + _mapUMLPolicySimple({ + name: "pol_a", + commercial: true, + derivatives: true, + reciprocal: false, + commercialRevShare: 100, + derivativesRevShare: 100 + }); UMLPolicy memory polA = _getMappedUmlPolicy("pol_a"); - _mapUMLPolicySimple({name: "pol_b", commercial: true, derivatives: true, reciprocal: false, commercialRevShare: 100, derivativesRevShare: 100}); + _mapUMLPolicySimple({ + name: "pol_b", + commercial: true, + derivatives: true, + reciprocal: false, + commercialRevShare: 100, + derivativesRevShare: 100 + }); UMLPolicy memory polB = _getMappedUmlPolicy("pol_b"); // We set some indifferents polA.attribution = true; @@ -339,7 +485,10 @@ contract UMLPolicyFrameworkMultiParentTest is TestHelper { _testRevertCompat(polA, polB, UMLFrameworkErrors.UMLPolicyFrameworkManager__StringArrayMismatch.selector); } - function _test_register_mint_AB(UMLPolicy memory polA, UMLPolicy memory polB) internal returns (uint256 polAId, uint256 polBId) { + function _test_register_mint_AB( + UMLPolicy memory polA, + UMLPolicy memory polB + ) internal returns (uint256 polAId, uint256 polBId) { // Mock set minRoyalty for IPAccount 1 and 2 for `mintLicense`s to succeed mockRoyaltyPolicyLS.setMinRoyalty(ipId1, polA.commercialRevShare); mockRoyaltyPolicyLS.setMinRoyalty(ipId2, polB.commercialRevShare); @@ -359,7 +508,7 @@ contract UMLPolicyFrameworkMultiParentTest is TestHelper { vm.expectRevert(errorSelector); vm.prank(alice); licensingModule.linkIpToParents(licenses, ipId4, 0); - licenses = new uint256[](0); + licenses = new uint256[](0); } function _testSuccessCompat(UMLPolicy memory polA, UMLPolicy memory polB, uint256 expectedPolicies) internal { @@ -380,5 +529,4 @@ contract UMLPolicyFrameworkMultiParentTest is TestHelper { assertTrue(licensingModule.isPolicyIdSetForIp(true, ipId4, polBId)); licenses = new uint256[](0); // To call this function multiple times } - } diff --git a/test/foundry/modules/licensing/UMLPolicyFramework.t.sol b/test/foundry/modules/licensing/UMLPolicyFramework.t.sol index d8ceb3bc..7d8f7d25 100644 --- a/test/foundry/modules/licensing/UMLPolicyFramework.t.sol +++ b/test/foundry/modules/licensing/UMLPolicyFramework.t.sol @@ -1,23 +1,11 @@ // SPDX-License-Identifier: UNLICENSED pragma solidity ^0.8.23; -import { Strings } from "@openzeppelin/contracts/utils/Strings.sol"; -import { Test } from "forge-std/Test.sol"; -import { ERC6551Registry } from "@erc6551/ERC6551Registry.sol"; - -import { LicenseRegistry } from "contracts/registries/LicenseRegistry.sol"; -import { Licensing } from "contracts/lib/Licensing.sol"; import { Errors } from "contracts/lib/Errors.sol"; import { UMLFrameworkErrors } from "contracts/lib/UMLFrameworkErrors.sol"; -import { IUMLPolicyFrameworkManager, UMLPolicy } from "contracts/interfaces/modules/licensing/IUMLPolicyFrameworkManager.sol"; +import { UMLPolicy } from "contracts/interfaces/modules/licensing/IUMLPolicyFrameworkManager.sol"; import { UMLPolicyFrameworkManager } from "contracts/modules/licensing/UMLPolicyFrameworkManager.sol"; -import { MockAccessController } from "test/foundry/mocks/MockAccessController.sol"; -import { IPAccountImpl } from "contracts/IPAccountImpl.sol"; -import { IPAccountRegistry } from "contracts/registries/IPAccountRegistry.sol"; -import { MockERC721 } from "test/foundry/mocks/MockERC721.sol"; -import { RoyaltyModule } from "contracts/modules/royalty-module/RoyaltyModule.sol"; -import { IPAssetRegistry } from "contracts/registries/IPAssetRegistry.sol"; -import { TestHelper } from "test/utils/TestHelper.sol"; +import { TestHelper } from "test/foundry/utils/TestHelper.sol"; contract UMLPolicyFrameworkTest is TestHelper { UMLPolicyFrameworkManager internal umlFramework; @@ -78,7 +66,7 @@ contract UMLPolicyFrameworkTest is TestHelper { } ///////////////////////////////////////////////////////////// - ////// COMMERCIAL USE TERMS ////// + ////// COMMERCIAL USE TERMS ////// ///////////////////////////////////////////////////////////// function test_UMLPolicyFrameworkManager__commercialUse_disallowed_revert_settingIncompatibleTerms() public { @@ -107,7 +95,9 @@ contract UMLPolicyFrameworkTest is TestHelper { umlPolicy.commercialAttribution = false; umlPolicy.commercializers = new string[](1); umlPolicy.commercializers[0] = "test"; - vm.expectRevert(UMLFrameworkErrors.UMLPolicyFrameworkManager__CommercialDisabled_CantAddCommercializers.selector); + vm.expectRevert( + UMLFrameworkErrors.UMLPolicyFrameworkManager__CommercialDisabled_CantAddCommercializers.selector + ); umlFramework.registerPolicy(umlPolicy); // No rev share should be set; revert umlPolicy.commercializers = new string[](0); @@ -210,7 +200,7 @@ contract UMLPolicyFrameworkTest is TestHelper { } ///////////////////////////////////////////////////////////// - ////// APPROVAL TERMS ////// + ////// APPROVAL TERMS ////// ///////////////////////////////////////////////////////////// function test_UMLPolicyFrameworkManager_derivatives_withApproval_revert_linkNotApproved() public { @@ -239,7 +229,7 @@ contract UMLPolicyFrameworkTest is TestHelper { uint256 licenseId = licensingModule.mintLicense(policyId, ipId1, 1, ipOwner); assertFalse(umlFramework.isDerivativeApproved(licenseId, ipId2)); - + vm.prank(licenseRegistry.licensorIpId(licenseId)); umlFramework.setApproval(licenseId, ipId2, false); assertFalse(umlFramework.isDerivativeApproved(licenseId, ipId2)); @@ -275,14 +265,14 @@ contract UMLPolicyFrameworkTest is TestHelper { vm.prank(ipOwner); licensingModule.addPolicyToIp(ipId1, policyId); - + uint256 licenseId = licensingModule.mintLicense(policyId, ipId1, 1, ipOwner); assertFalse(umlFramework.isDerivativeApproved(licenseId, ipId2)); vm.expectRevert(Errors.LicenseRegistry__NotTransferable.selector); vm.prank(ipOwner); licenseRegistry.safeTransferFrom(ipOwner, licenseHolder, licenseId, 1, ""); - + vm.prank(licenseRegistry.licensorIpId(licenseId)); umlFramework.setApproval(licenseId, ipId2, true); assertTrue(umlFramework.isDerivativeApproved(licenseId, ipId2)); @@ -296,7 +286,7 @@ contract UMLPolicyFrameworkTest is TestHelper { } ///////////////////////////////////////////////////////////// - ////// TRANSFER TERMS ////// + ////// TRANSFER TERMS ////// ///////////////////////////////////////////////////////////// function test_UMLPolicyFrameworkManager__transferrable() public { diff --git a/test/foundry/modules/royalty/LSClaimer.t.sol b/test/foundry/modules/royalty/LSClaimer.t.sol index 147ba759..0b5e913a 100644 --- a/test/foundry/modules/royalty/LSClaimer.t.sol +++ b/test/foundry/modules/royalty/LSClaimer.t.sol @@ -2,30 +2,24 @@ pragma solidity ^0.8.23; // external -import { console2 } from "forge-std/console2.sol"; -import { ERC20, IERC20 } from "@openzeppelin/contracts/token/ERC20/ERC20.sol"; +import { ERC20 } from "@openzeppelin/contracts/token/ERC20/ERC20.sol"; import { Strings } from "@openzeppelin/contracts/utils/Strings.sol"; import { ERC6551AccountLib } from "@erc6551/lib/ERC6551AccountLib.sol"; // contracts -import { ILiquidSplitFactory } from "contracts/interfaces/modules/royalty/policies/ILiquidSplitFactory.sol"; import { Errors } from "contracts/lib/Errors.sol"; -import { IP } from "contracts/lib/IP.sol"; -import { BasePolicyFrameworkManager } from "contracts/modules/licensing/BasePolicyFrameworkManager.sol"; -import { UMLPolicyFrameworkManager } from "contracts/modules/licensing/UMLPolicyFrameworkManager.sol"; import { ILiquidSplitClone } from "contracts/interfaces/modules/royalty/policies/ILiquidSplitClone.sol"; import { ILiquidSplitMain } from "contracts/interfaces/modules/royalty/policies/ILiquidSplitMain.sol"; import { LSClaimer } from "contracts/modules/royalty-module/policies/LSClaimer.sol"; import { RoyaltyPolicyLS } from "contracts/modules/royalty-module/policies/RoyaltyPolicyLS.sol"; // test +// solhint-disable-next-line max-line-length import { UMLPolicyGenericParams, UMLPolicyCommercialParams, UMLPolicyDerivativeParams } from "test/foundry/integration/shared/LicenseHelper.sol"; -import { MintPaymentPolicyFrameworkManager } from "test/foundry/mocks/licensing/MintPaymentPolicyFrameworkManager.sol"; -import { MockERC721 } from "test/foundry/mocks/MockERC721.sol"; -import { TestHelper } from "test/utils/TestHelper.sol"; +import { TestHelper } from "test/foundry/utils/TestHelper.sol"; contract TestLSClaimer is TestHelper { - RoyaltyPolicyLS testRoyaltyPolicyLS; + RoyaltyPolicyLS public testRoyaltyPolicyLS; address[] public LONG_CHAIN = new address[](100); address[] public accounts = new address[](2); uint32[] public initAllocations = new uint32[](2); @@ -103,7 +97,7 @@ contract TestLSClaimer is TestHelper { new address[](0), // no parent abi.encode(10) ); - + vm.stopPrank(); vm.startPrank(deployer); uint256[] memory licenseId = new uint256[](1); @@ -125,7 +119,7 @@ contract TestLSClaimer is TestHelper { ); string memory ipAcctName = string(abi.encodePacked("IPAccount", Strings.toString(nftIds[i + 1]))); vm.label(expectedAddr, ipAcctName); - + registrationModule.registerDerivativeIp( licenseId, address(nft), @@ -284,7 +278,7 @@ contract TestLSClaimer is TestHelper { USDC.mint(address(lsClaimer100), usdcRoyaltyAmount); address claimerIpId = _getIpId(nft, nftIds[0]); - (address claimerSplitClone,,,) = testRoyaltyPolicyLS.royaltyData(_getIpId(nft, nftIds[0])); + (address claimerSplitClone, , , ) = testRoyaltyPolicyLS.royaltyData(_getIpId(nft, nftIds[0])); tokens[0] = USDC; uint256 lsClaimerUSDCBalBefore = USDC.balanceOf(address(lsClaimer100)); diff --git a/test/foundry/modules/royalty/RoyaltyModule.t.sol b/test/foundry/modules/royalty/RoyaltyModule.t.sol index a0c962d4..ce89d043 100644 --- a/test/foundry/modules/royalty/RoyaltyModule.t.sol +++ b/test/foundry/modules/royalty/RoyaltyModule.t.sol @@ -1,21 +1,18 @@ // SPDX-License-Identifier: UNLICENSED pragma solidity ^0.8.23; - -import {console2} from "forge-std/console2.sol"; -import {ERC20} from "@openzeppelin/contracts/token/ERC20/ERC20.sol"; -import {IERC20} from "@openzeppelin/contracts/token/ERC20/IERC20.sol"; - -import {RoyaltyModule} from "contracts/modules/royalty-module/RoyaltyModule.sol"; -import { TestHelper } from "../../../utils/TestHelper.sol"; +// contracts +import { RoyaltyModule } from "contracts/modules/royalty-module/RoyaltyModule.sol"; import { Errors } from "contracts/lib/Errors.sol"; +// tests +import { TestHelper } from "../../utils/TestHelper.sol"; contract TestRoyaltyModule is TestHelper { event RoyaltyPolicyWhitelistUpdated(address royaltyPolicy, bool allowed); event RoyaltyTokenWhitelistUpdated(address token, bool allowed); event RoyaltyPolicySet(address ipId, address royaltyPolicy, bytes data); event RoyaltyPaid(address receiverIpId, address payerIpId, address sender, address token, uint256 amount); - + function setUp() public override { super.setUp(); @@ -197,7 +194,7 @@ contract TestRoyaltyModule is TestHelper { } function test_RoyaltyModule_payRoyaltyOnBehalf() public { - uint256 royaltyAmount = 100 * 10 ** 6; + uint256 royaltyAmount = 100 * 10 ** 6; address[] memory parentIpIds1 = new address[](0); uint32 minRoyaltyIpAccount1 = 100; // 10% @@ -209,11 +206,11 @@ contract TestRoyaltyModule is TestHelper { address[] memory parentIpIds2 = new address[](0); uint32 minRoyaltyIpAccount2 = 100; // 10% bytes memory data2 = abi.encode(minRoyaltyIpAccount2); - + royaltyModule.setRoyaltyPolicy(ipAccount2, address(royaltyPolicyLS), parentIpIds2, data2); vm.stopPrank(); - (address splitClone1,,,) = royaltyPolicyLS.royaltyData(ipAccount1); + (address splitClone1, , , ) = royaltyPolicyLS.royaltyData(ipAccount1); vm.startPrank(ipAccount2); USDC.approve(address(royaltyPolicyLS), royaltyAmount); @@ -232,4 +229,4 @@ contract TestRoyaltyModule is TestHelper { assertEq(ipAccount2USDCBalBefore - ipAccount2USDCBalAfter, royaltyAmount); assertEq(splitClone1USDCBalAfter - splitClone1USDCBalBefore, royaltyAmount); } -} \ No newline at end of file +} diff --git a/test/foundry/modules/royalty/RoyaltyPolicyLS.t.sol b/test/foundry/modules/royalty/RoyaltyPolicyLS.t.sol index 0e1f0118..15cb6ecd 100644 --- a/test/foundry/modules/royalty/RoyaltyPolicyLS.t.sol +++ b/test/foundry/modules/royalty/RoyaltyPolicyLS.t.sol @@ -1,14 +1,13 @@ // SPDX-License-Identifier: UNLICENSED pragma solidity ^0.8.23; -import { console2 } from "forge-std/console2.sol"; -import { IERC20 } from "@openzeppelin/contracts/token/ERC20/IERC20.sol"; +// external import { ERC20 } from "@openzeppelin/contracts/token/ERC20/ERC20.sol"; - -import { TestHelper } from "../../../utils/TestHelper.sol"; +// contracts import { RoyaltyPolicyLS } from "../../../../contracts/modules/royalty-module/policies/RoyaltyPolicyLS.sol"; -import { ILiquidSplitClone } from "../../../../contracts/interfaces/modules/royalty/policies/ILiquidSplitClone.sol"; import { Errors } from "../../../../contracts/lib/Errors.sol"; +// tests +import { TestHelper } from "../../utils/TestHelper.sol"; contract TestLSClaimer is TestHelper { RoyaltyPolicyLS internal testRoyaltyPolicyLS; @@ -31,7 +30,12 @@ contract TestLSClaimer is TestHelper { function test_RoyaltyPolicyLS_constructor_revert_ZeroLicensingModule() public { vm.expectRevert(Errors.RoyaltyPolicyLS__ZeroLicensingModule.selector); - testRoyaltyPolicyLS = new RoyaltyPolicyLS(address(royaltyModule), address(0), LIQUID_SPLIT_FACTORY, LIQUID_SPLIT_MAIN); + testRoyaltyPolicyLS = new RoyaltyPolicyLS( + address(royaltyModule), + address(0), + LIQUID_SPLIT_FACTORY, + LIQUID_SPLIT_MAIN + ); } function test_RoyaltyPolicyLS_constructor_revert_ZeroLiquidSplitFactory() public { @@ -47,18 +51,23 @@ contract TestLSClaimer is TestHelper { } function test_RoyaltyPolicyLS_constructor() public { - testRoyaltyPolicyLS = new RoyaltyPolicyLS(address(royaltyModule), address(1), LIQUID_SPLIT_FACTORY, LIQUID_SPLIT_MAIN); + testRoyaltyPolicyLS = new RoyaltyPolicyLS( + address(royaltyModule), + address(1), + LIQUID_SPLIT_FACTORY, + LIQUID_SPLIT_MAIN + ); assertEq(testRoyaltyPolicyLS.ROYALTY_MODULE(), address(royaltyModule)); assertEq(testRoyaltyPolicyLS.LICENSING_MODULE(), address(1)); assertEq(testRoyaltyPolicyLS.LIQUID_SPLIT_FACTORY(), LIQUID_SPLIT_FACTORY); - assertEq(testRoyaltyPolicyLS.LIQUID_SPLIT_MAIN(), LIQUID_SPLIT_MAIN); + assertEq(testRoyaltyPolicyLS.LIQUID_SPLIT_MAIN(), LIQUID_SPLIT_MAIN); } function test_RoyaltyPolicyLS_initPolicy_NotRoyalModule() public { vm.startPrank(address(licensingModule)); address[] memory parentIpIds = new address[](0); - uint32 minRoyaltyIpAccount1 = 100; + uint32 minRoyaltyIpAccount1 = 100; bytes memory data = abi.encode(minRoyaltyIpAccount1); vm.expectRevert(Errors.RoyaltyPolicyLS__NotRoyaltyModule.selector); @@ -69,7 +78,7 @@ contract TestLSClaimer is TestHelper { vm.startPrank(address(licensingModule)); // set root parent royalty policy address[] memory parentIpIds1 = new address[](0); - uint32 minRoyaltyIpAccount1 = 100; + uint32 minRoyaltyIpAccount1 = 100; bytes memory data1 = abi.encode(minRoyaltyIpAccount1); royaltyModule.setRoyaltyPolicy(ipAccount1, address(royaltyPolicyLS), parentIpIds1, data1); @@ -87,7 +96,7 @@ contract TestLSClaimer is TestHelper { vm.startPrank(address(licensingModule)); // set root parent royalty policy address[] memory parentIpIds1 = new address[](0); - uint32 minRoyaltyIpAccount1 = 100; + uint32 minRoyaltyIpAccount1 = 100; bytes memory data1 = abi.encode(minRoyaltyIpAccount1); royaltyModule.setRoyaltyPolicy(ipAccount1, address(royaltyPolicyLS), parentIpIds1, data1); @@ -113,13 +122,15 @@ contract TestLSClaimer is TestHelper { function test_RoyaltyPolicyLS_initPolicy_rootIPA() public { address[] memory parentIpIds = new address[](0); - uint32 minRoyaltyIpAccount1 = 0; + uint32 minRoyaltyIpAccount1 = 0; bytes memory data = abi.encode(minRoyaltyIpAccount1); vm.startPrank(address(licensingModule)); royaltyModule.setRoyaltyPolicy(ipAccount1, address(royaltyPolicyLS), parentIpIds, data); - (address splitClone, address claimer, uint32 royaltyStack, uint32 minRoyalty) = royaltyPolicyLS.royaltyData(ipAccount1); + (address splitClone, address claimer, uint32 royaltyStack, uint32 minRoyalty) = royaltyPolicyLS.royaltyData( + ipAccount1 + ); assertFalse(splitClone == address(0)); assertEq(claimer, address(royaltyPolicyLS)); @@ -131,18 +142,20 @@ contract TestLSClaimer is TestHelper { vm.startPrank(address(licensingModule)); // set root parent royalty policy address[] memory parentIpIds1 = new address[](0); - uint32 minRoyaltyIpAccount1 = 100; + uint32 minRoyaltyIpAccount1 = 100; bytes memory data1 = abi.encode(minRoyaltyIpAccount1); royaltyModule.setRoyaltyPolicy(ipAccount1, address(royaltyPolicyLS), parentIpIds1, data1); // set derivative royalty policy address[] memory parentIpIds2 = new address[](1); parentIpIds2[0] = ipAccount1; - uint32 minRoyaltyIpAccount2 = 200; + uint32 minRoyaltyIpAccount2 = 200; bytes memory data2 = abi.encode(minRoyaltyIpAccount2); royaltyModule.setRoyaltyPolicy(ipAccount2, address(royaltyPolicyLS), parentIpIds2, data2); - (address splitClone, address claimer, uint32 royaltyStack, uint32 minRoyalty) = royaltyPolicyLS.royaltyData(ipAccount2); + (address splitClone, address claimer, uint32 royaltyStack, uint32 minRoyalty) = royaltyPolicyLS.royaltyData( + ipAccount2 + ); assertFalse(splitClone == address(0)); assertFalse(claimer == address(royaltyPolicyLS)); @@ -161,10 +174,10 @@ contract TestLSClaimer is TestHelper { vm.startPrank(address(licensingModule)); // set root parent royalty policy address[] memory parentIpIds1 = new address[](0); - uint32 minRoyaltyIpAccount1 = 100; + uint32 minRoyaltyIpAccount1 = 100; bytes memory data1 = abi.encode(minRoyaltyIpAccount1); royaltyModule.setRoyaltyPolicy(ipAccount1, address(royaltyPolicyLS), parentIpIds1, data1); - (address splitClone1, address claimer2,,) = royaltyPolicyLS.royaltyData(ipAccount1); + (address splitClone1, , , ) = royaltyPolicyLS.royaltyData(ipAccount1); vm.stopPrank(); uint256 royaltyAmount = 1000 * 10 ** 6; @@ -191,17 +204,17 @@ contract TestLSClaimer is TestHelper { vm.startPrank(address(licensingModule)); // set root parent royalty policy address[] memory parentIpIds1 = new address[](0); - uint32 minRoyaltyIpAccount1 = 100; + uint32 minRoyaltyIpAccount1 = 100; bytes memory data1 = abi.encode(minRoyaltyIpAccount1); royaltyModule.setRoyaltyPolicy(ipAccount1, address(royaltyPolicyLS), parentIpIds1, data1); // set derivative royalty policy address[] memory parentIpIds2 = new address[](1); parentIpIds2[0] = ipAccount1; - uint32 minRoyaltyIpAccount2 = 200; + uint32 minRoyaltyIpAccount2 = 200; bytes memory data2 = abi.encode(minRoyaltyIpAccount2); royaltyModule.setRoyaltyPolicy(ipAccount2, address(royaltyPolicyLS), parentIpIds2, data2); - (address splitClone2, address claimer2,,) = royaltyPolicyLS.royaltyData(ipAccount2); + (address splitClone2, address claimer2, , ) = royaltyPolicyLS.royaltyData(ipAccount2); // send USDC to 0xSplitClone uint256 royaltyAmount = 1000 * 10 ** 6; @@ -223,21 +236,21 @@ contract TestLSClaimer is TestHelper { assertApproxEqRel(splitMainUSDCBalAfter - splitMainUSDCBalBefore, royaltyAmount, 0.0001e18); } - function test_RoyaltyPolicyLS_claimRoyalties() public{ + function test_RoyaltyPolicyLS_claimRoyalties() public { vm.startPrank(address(licensingModule)); // set root parent royalty policy address[] memory parentIpIds1 = new address[](0); - uint32 minRoyaltyIpAccount1 = 100; + uint32 minRoyaltyIpAccount1 = 100; bytes memory data1 = abi.encode(minRoyaltyIpAccount1); royaltyModule.setRoyaltyPolicy(ipAccount1, address(royaltyPolicyLS), parentIpIds1, data1); // set derivative royalty policy address[] memory parentIpIds2 = new address[](1); parentIpIds2[0] = ipAccount1; - uint32 minRoyaltyIpAccount2 = 200; + uint32 minRoyaltyIpAccount2 = 200; bytes memory data2 = abi.encode(minRoyaltyIpAccount2); royaltyModule.setRoyaltyPolicy(ipAccount2, address(royaltyPolicyLS), parentIpIds2, data2); - (address splitClone2, address claimer2,,) = royaltyPolicyLS.royaltyData(ipAccount2); + (address splitClone2, address claimer2, , ) = royaltyPolicyLS.royaltyData(ipAccount2); vm.stopPrank(); // send USDC to 0xSplitClone @@ -255,4 +268,4 @@ contract TestLSClaimer is TestHelper { royaltyPolicyLS.claimRoyalties(ipAccount2, 0, tokens); } -} \ No newline at end of file +} diff --git a/test/foundry/registries/metadata/IPAssetRenderer.t.sol b/test/foundry/registries/metadata/IPAssetRenderer.t.sol index 668551e1..c16679e1 100644 --- a/test/foundry/registries/metadata/IPAssetRenderer.t.sol +++ b/test/foundry/registries/metadata/IPAssetRenderer.t.sol @@ -4,46 +4,35 @@ pragma solidity ^0.8.23; import { Strings } from "@openzeppelin/contracts/utils/Strings.sol"; import { Base64 } from "@openzeppelin/contracts/utils/Base64.sol"; -import { ResolverBaseTest } from "test/foundry/resolvers/ResolverBase.t.sol"; import { IPResolver } from "contracts/resolvers/IPResolver.sol"; -import { IResolver } from "contracts/interfaces/resolvers/IResolver.sol"; import { AccessController } from "contracts/AccessController.sol"; import { ModuleRegistry } from "contracts/registries/ModuleRegistry.sol"; import { ERC6551Registry } from "@erc6551/ERC6551Registry.sol"; -import { IModuleRegistry } from "contracts/interfaces/registries/IModuleRegistry.sol"; import { IPAssetRegistry } from "contracts/registries/IPAssetRegistry.sol"; import { RegistrationModule } from "contracts/modules/RegistrationModule.sol"; import { IPAccountRegistry } from "contracts/registries/IPAccountRegistry.sol"; import { LicenseRegistry } from "contracts/registries/LicenseRegistry.sol"; -import { MockModuleRegistry } from "test/foundry/mocks/MockModuleRegistry.sol"; import { MetadataProviderV1 } from "contracts/registries/metadata/MetadataProviderV1.sol"; import { RegistrationModule } from "contracts/modules/RegistrationModule.sol"; -import { IIPAssetRegistry } from "contracts/interfaces/registries/IIPAssetRegistry.sol"; import { IPAssetRenderer } from "contracts/registries/metadata/IPAssetRenderer.sol"; import { BaseTest } from "test/foundry/utils/BaseTest.sol"; -import { IPAccountImpl} from "contracts/IPAccountImpl.sol"; +import { IPAccountImpl } from "contracts/IPAccountImpl.sol"; import { MockERC721 } from "test/foundry/mocks/MockERC721.sol"; -import { ModuleBaseTest } from "test/foundry/modules/ModuleBase.t.sol"; import { IP } from "contracts/lib/IP.sol"; -import { Errors } from "contracts/lib/Errors.sol"; -import { IP_RESOLVER_MODULE_KEY, REGISTRATION_MODULE_KEY } from "contracts/lib/modules/Module.sol"; import { Governance } from "contracts/governance/Governance.sol"; import { RoyaltyModule } from "contracts/modules/royalty-module/RoyaltyModule.sol"; import { LicensingModule } from "contracts/modules/licensing/LicensingModule.sol"; -import "forge-std/console2.sol"; - /// @title IP Asset Renderer Test Contract /// @notice Tests IP asset rendering functionality. /// TODO: Make this inherit module base to avoid code duplication. contract IPAssetRendererTest is BaseTest { - // Module placeholders // TODO: Mock these out. - address taggingModule = vm.addr(0x1111); + address public taggingModule = vm.addr(0x1111); /// @notice Gets the metadata provider used for IP registration. - MetadataProviderV1 metadataProvider; + MetadataProviderV1 public metadataProvider; /// @notice Used for registration in the IP asset registry. RegistrationModule public registrationModule; @@ -94,7 +83,7 @@ contract IPAssetRendererTest is BaseTest { accessController = new AccessController(address(governance)); moduleRegistry = new ModuleRegistry(address(governance)); MockERC721 erc721 = new MockERC721("MockERC721"); - + ERC6551Registry erc6551Registry = new ERC6551Registry(); IPAccountImpl ipAccountImpl = new IPAccountImpl(); ipAccountRegistry = new IPAccountRegistry( @@ -108,7 +97,6 @@ contract IPAssetRendererTest is BaseTest { address(ipAccountImpl) ); RoyaltyModule royaltyModule = new RoyaltyModule(address(governance)); - uint i; licenseRegistry = new LicenseRegistry(); licensingModule = new LicensingModule( address(accessController), @@ -117,10 +105,7 @@ contract IPAssetRendererTest is BaseTest { address(licenseRegistry) ); licenseRegistry.setLicensingModule(address(licensingModule)); - resolver = new IPResolver( - address(accessController), - address(ipAssetRegistry) - ); + resolver = new IPResolver(address(accessController), address(ipAssetRegistry)); renderer = new IPAssetRenderer( address(ipAssetRegistry), address(licenseRegistry), @@ -145,18 +130,10 @@ contract IPAssetRendererTest is BaseTest { registrationDate: IP_REGISTRATION_DATE, registrant: alice, uri: IP_EXTERNAL_URL - }) ); vm.prank(address(registrationModule)); - ipId = ipAssetRegistry.register( - block.chainid, - address(erc721), - tokenId, - address(resolver), - true, - metadata - ); + ipId = ipAssetRegistry.register(block.chainid, address(erc721), tokenId, address(resolver), true, metadata); } /// @notice Tests that the constructor works as expected. @@ -172,7 +149,7 @@ contract IPAssetRendererTest is BaseTest { /// @notice Tests that the renderer can properly resolve descriptions. function test_IPAssetRenderer_Description() public virtual { assertEq( - renderer.description(ipId), + renderer.description(ipId), string.concat( IP_NAME, ", IP #", @@ -224,20 +201,35 @@ contract IPAssetRendererTest is BaseTest { ); string memory ipIdStr = Strings.toHexString(uint160(ipId)); - string memory uriEncoding = string(abi.encodePacked( - '{"name": "IP Asset #', ipIdStr, '", "description": "', description, '", "attributes": [', - '{"trait_type": "Name", "value": "IPAsset"},', - '{"trait_type": "Owner", "value": "', ownerStr, '"},' - '{"trait_type": "Registrant", "value": "', ownerStr, '"},', - '{"trait_type": "Hash", "value": "0x3078303000000000000000000000000000000000000000000000000000000000"},', - '{"trait_type": "Registration Date", "value": "', Strings.toString(IP_REGISTRATION_DATE), '"}', - ']}' - )); - string memory expectedURI = string(abi.encodePacked( - "data:application/json;base64,", - Base64.encode(bytes(string(abi.encodePacked(uriEncoding)))) - )); + /* solhint-disable */ + string memory uriEncoding = string( + abi.encodePacked( + '{"name": "IP Asset #', + ipIdStr, + '", "description": "', + description, + '", "attributes": [', + '{"trait_type": "Name", "value": "IPAsset"},', + '{"trait_type": "Owner", "value": "', + ownerStr, + '"},' + '{"trait_type": "Registrant", "value": "', + ownerStr, + '"},', + '{"trait_type": "Hash", "value": "0x3078303000000000000000000000000000000000000000000000000000000000"},', + '{"trait_type": "Registration Date", "value": "', + Strings.toString(IP_REGISTRATION_DATE), + '"}', + "]}" + ) + ); + /* solhint-enable */ + string memory expectedURI = string( + abi.encodePacked( + "data:application/json;base64,", + Base64.encode(bytes(string(abi.encodePacked(uriEncoding)))) + ) + ); assertEq(expectedURI, renderer.tokenURI(ipId)); } - } diff --git a/test/foundry/registries/metadata/MetadataProvider.t.sol b/test/foundry/registries/metadata/MetadataProvider.t.sol index 8095921e..a0f11ce8 100644 --- a/test/foundry/registries/metadata/MetadataProvider.t.sol +++ b/test/foundry/registries/metadata/MetadataProvider.t.sol @@ -5,27 +5,22 @@ import { BaseTest } from "test/foundry/utils/BaseTest.sol"; import { IP } from "contracts/lib/IP.sol"; import { IPAccountRegistry } from "contracts/registries/IPAccountRegistry.sol"; import { IPResolver } from "contracts/resolvers/IPResolver.sol"; -import { MockModuleRegistry } from "test/foundry/mocks/MockModuleRegistry.sol"; import { ModuleRegistry } from "contracts/registries/ModuleRegistry.sol"; import { IPAssetRegistry } from "contracts/registries/IPAssetRegistry.sol"; -import { LicenseRegistry } from "contracts/registries/LicenseRegistry.sol"; import { ERC6551Registry } from "@erc6551/ERC6551Registry.sol"; -import { IPAccountImpl} from "contracts/IPAccountImpl.sol"; +import { IPAccountImpl } from "contracts/IPAccountImpl.sol"; import { MockMetadataProviderV2 } from "test/foundry/mocks/MockMetadataProviderV2.sol"; import { AccessController } from "contracts/AccessController.sol"; import { IPAssetRegistry } from "contracts/registries/IPAssetRegistry.sol"; import { Governance } from "contracts/governance/Governance.sol"; -import { IIPAccount } from "contracts/interfaces/IIPAccount.sol"; import { MetadataProviderV1 } from "contracts/registries/metadata/MetadataProviderV1.sol"; import { IMetadataProvider } from "contracts/interfaces/registries/metadata/IMetadataProvider.sol"; import { Errors } from "contracts/lib/Errors.sol"; import { MockERC721 } from "test/foundry/mocks/MockERC721.sol"; -import { RoyaltyModule } from "contracts/modules/royalty-module/RoyaltyModule.sol"; /// @title IP Metadata Provider Testing Contract /// @notice Contract for metadata provider settings. contract MetadataProviderTest is BaseTest { - /// @notice Struct depicting the expected upgraded canonical Metadata. struct ExpectedUpgradedMetadataV2 { //////////////////////////////////////////////////////////////////////// @@ -56,7 +51,6 @@ contract MetadataProviderTest is BaseTest { string name; // A keccak-256 hash of the IP content. bytes32 hash; - //////////////////////////////////////////////////////////////////////// // Note: Missing registration memory encoding /// //////////////////////////////////////////////////////////////////////// @@ -73,13 +67,12 @@ contract MetadataProviderTest is BaseTest { uint256 decimals; } - // Default IP asset metadata attributes. string public constant IP_NAME = "IPAsset"; string public constant IP_DESCRIPTION = "IPs all the way down."; bytes32 public constant IP_HASH = "0x99"; string public constant IP_EXTERNAL_URL = "https://storyprotocol.xyz"; - + // Default upgraded additional IP asset metadata attributes. string public constant IP_NICKNAME = "IP Man"; uint256 public constant IP_DECIMALS = 9999; @@ -109,7 +102,6 @@ contract MetadataProviderTest is BaseTest { registrationDate: uint64(block.timestamp), registrant: alice, uri: IP_EXTERNAL_URL - }) ); @@ -126,29 +118,13 @@ contract MetadataProviderTest is BaseTest { address(ipAccountImpl) ); vm.prank(bob); - registry = new IPAssetRegistry( - address(accessController), - address(erc6551Registry), - address(ipAccountImpl) - ); - RoyaltyModule royaltyModule = new RoyaltyModule(address(governance)); + registry = new IPAssetRegistry(address(accessController), address(erc6551Registry), address(ipAccountImpl)); accessController.initialize(address(ipAccountRegistry), address(moduleRegistry)); - LicenseRegistry licenseRegistry = new LicenseRegistry(); MockERC721 erc721 = new MockERC721("MockERC721"); uint256 tokenId = erc721.mintId(alice, 99); - IPResolver resolver = new IPResolver( - address(accessController), - address(registry) - ); - ipId = registry.register( - block.chainid, - address(erc721), - tokenId, - address(resolver), - true, - v1Metadata - ); + IPResolver resolver = new IPResolver(address(accessController), address(registry)); + ipId = registry.register(block.chainid, address(erc721), tokenId, address(resolver), true, v1Metadata); metadataProvider = MetadataProviderV1(registry.metadataProvider()); upgradedProvider = new MockMetadataProviderV2(address(registry)); @@ -163,16 +139,10 @@ contract MetadataProviderTest is BaseTest { /// @notice Tests metadata is properly stored. function test_MetadataProvider_SetMetadata() public { vm.expectEmit(true, true, true, true); - emit IMetadataProvider.MetadataSet( - ipId, - v1Metadata - ); + emit IMetadataProvider.MetadataSet(ipId, v1Metadata); vm.prank(address(registry)); metadataProvider.setMetadata(ipId, v1Metadata); - assertEq( - metadataProvider.getMetadata(ipId), - v1Metadata - ); + assertEq(metadataProvider.getMetadata(ipId), v1Metadata); assertEq(metadataProvider.name(ipId), IP_NAME); assertEq(metadataProvider.hash(ipId), IP_HASH); assertEq(metadataProvider.registrationDate(ipId), uint64(block.timestamp)); @@ -189,7 +159,6 @@ contract MetadataProviderTest is BaseTest { registrationDate: uint64(block.timestamp), registrant: address(0), uri: IP_EXTERNAL_URL - }) ); vm.expectRevert(Errors.MetadataProvider__RegistrantInvalid.selector); @@ -263,7 +232,6 @@ contract MetadataProviderTest is BaseTest { metadataProvider.upgrade(payable(ipId), v2Metadata); } - /// @notice Checks that metadata setting reverts if not called by the registry. function test_MetadataProvider_SetUpgradeProvider() public { vm.prank(address(registry)); @@ -278,7 +246,6 @@ contract MetadataProviderTest is BaseTest { metadataProvider.setUpgradeProvider(address(0)); } - /// @notice Checks that metadata setting reverts if not called by the registry. function test_MetadataProvider_SetMetadata_Reverts_Unauthorized() public { vm.expectRevert(Errors.MetadataProvider__Unauthorized.selector); diff --git a/test/foundry/resolvers/IPResolver.t.sol b/test/foundry/resolvers/IPResolver.t.sol index c5b0e0ab..a5cfb4f8 100644 --- a/test/foundry/resolvers/IPResolver.t.sol +++ b/test/foundry/resolvers/IPResolver.t.sol @@ -5,24 +5,13 @@ import { ResolverBaseTest } from "test/foundry/resolvers/ResolverBase.t.sol"; import { IPResolver } from "contracts/resolvers/IPResolver.sol"; import { KeyValueResolver } from "contracts/resolvers/KeyValueResolver.sol"; import { IKeyValueResolver } from "contracts/interfaces/resolvers/IKeyValueResolver.sol"; -import { IResolver } from "contracts/interfaces/resolvers/IResolver.sol"; -import { ERC6551Registry } from "@erc6551/ERC6551Registry.sol"; -import { IModuleRegistry } from "contracts/interfaces/registries/IModuleRegistry.sol"; -import { IPAssetRegistry } from "contracts/registries/IPAssetRegistry.sol"; -import { RegistrationModule } from "contracts/modules/RegistrationModule.sol"; -import { MockModuleRegistry } from "test/foundry/mocks/MockModuleRegistry.sol"; -import { IIPAssetRegistry } from "contracts/interfaces/registries/IIPAssetRegistry.sol"; -import { IPAccountImpl} from "contracts/IPAccountImpl.sol"; import { MockERC721 } from "test/foundry/mocks/MockERC721.sol"; -import { ModuleBaseTest } from "test/foundry/modules/ModuleBase.t.sol"; import { IP } from "contracts/lib/IP.sol"; -import { Errors } from "contracts/lib/Errors.sol"; import { IP_RESOLVER_MODULE_KEY } from "contracts/lib/modules/Module.sol"; /// @title IP Resolver Test Contract /// @notice Tests IP metadata resolver functionality. contract IPResolverTest is ResolverBaseTest { - // Test record attributes. string public constant TEST_KEY = "Key"; string public constant TEST_VALUE = "Value"; @@ -50,17 +39,9 @@ contract IPResolverTest is ResolverBaseTest { registrationDate: uint64(block.timestamp), registrant: alice, uri: "https://storyprotocol.xyz" - }) ); - ipId = ipAssetRegistry.register( - block.chainid, - address(erc721), - tokenId, - address(ipResolver), - true, - metadata - ); + ipId = ipAssetRegistry.register(block.chainid, address(erc721), tokenId, address(ipResolver), true, metadata); } /// @notice Tests that the IP resolver interface is supported. @@ -73,27 +54,17 @@ contract IPResolverTest is ResolverBaseTest { vm.prank(ipId); accessController.setPermission(ipId, alice, address(ipResolver), KeyValueResolver.setValue.selector, 1); vm.prank(alice); - ipResolver.setValue( - ipId, - TEST_KEY, - TEST_VALUE - ); + ipResolver.setValue(ipId, TEST_KEY, TEST_VALUE); assertEq(ipResolver.value(ipId, TEST_KEY), TEST_VALUE); } /// @dev Gets the expected name for the module. - function _expectedName() internal virtual view override returns (string memory) { + function _expectedName() internal view virtual override returns (string memory) { return "IP_RESOLVER_MODULE"; } /// @dev Deploys a new IP Metadata Resolver. function _deployModule() internal override returns (address) { - return address( - new IPResolver( - address(accessController), - address(ipAssetRegistry) - ) - ); + return address(new IPResolver(address(accessController), address(ipAssetRegistry))); } - } diff --git a/test/foundry/resolvers/ResolverBase.t.sol b/test/foundry/resolvers/ResolverBase.t.sol index b64868d0..43ca3097 100644 --- a/test/foundry/resolvers/ResolverBase.t.sol +++ b/test/foundry/resolvers/ResolverBase.t.sol @@ -1,16 +1,12 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.23; -import { MockAccessController } from "test/foundry/mocks/MockAccessController.sol"; import { ModuleBaseTest } from "test/foundry/modules/ModuleBase.t.sol"; import { IResolver } from "contracts/interfaces/resolvers/IResolver.sol"; -import { IAccessController } from "contracts/interfaces/IAccessController.sol"; -import { Errors } from "contracts/lib/Errors.sol"; /// @title Resolver Base Test Contract /// @notice Base contract for testing standard resolver functionality. abstract contract ResolverBaseTest is ModuleBaseTest { - /// @notice The resolver SUT. IResolver public baseResolver; @@ -24,5 +20,4 @@ abstract contract ResolverBaseTest is ModuleBaseTest { function test_Resolver_SupportsInterface() public virtual { assertTrue(baseResolver.supportsInterface(type(IResolver).interfaceId)); } - } diff --git a/test/foundry/utils/BaseTest.sol b/test/foundry/utils/BaseTest.sol index e68e5f6e..823509a1 100644 --- a/test/foundry/utils/BaseTest.sol +++ b/test/foundry/utils/BaseTest.sol @@ -1,13 +1,12 @@ // SPDX-License-Identifier: MIT pragma solidity ^0.8.23; -import "forge-std/Test.sol"; +import { Test } from "forge-std/Test.sol"; /// @title Base Test Contract -/// @notice This contract provides a set of protocol-unrelated testing utilities +/// @notice This contract provides a set of protocol-unrelated testing utilities /// that may be extended by testing contracts. contract BaseTest is Test { - // Test public keys EOAs for deriving reusable EOA addresses. uint256 internal alicePk = 0xa11ce; uint256 internal bobPk = 0xb0b; diff --git a/test/utils/DeployHelper.sol b/test/foundry/utils/DeployHelper.sol similarity index 87% rename from test/utils/DeployHelper.sol rename to test/foundry/utils/DeployHelper.sol index 4758a04b..67fb78da 100644 --- a/test/utils/DeployHelper.sol +++ b/test/foundry/utils/DeployHelper.sol @@ -2,28 +2,15 @@ pragma solidity ^0.8.23; import { Test } from "forge-std/Test.sol"; -import { console2 } from "forge-std/console2.sol"; // external -import { IERC1155 } from "@openzeppelin/contracts/token/ERC1155/IERC1155.sol"; -import { Strings } from "@openzeppelin/contracts/utils/Strings.sol"; import { Test } from "forge-std/Test.sol"; import { ERC6551Registry } from "@erc6551/ERC6551Registry.sol"; -import { IERC6551Account } from "@erc6551/interfaces/IERC6551Account.sol"; -import { IERC6551Registry } from "@erc6551/interfaces/IERC6551Registry.sol"; -import { ERC6551AccountLib } from "@erc6551/lib/ERC6551AccountLib.sol"; // contracts import { AccessController } from "contracts/AccessController.sol"; import { Governance } from "contracts/governance/Governance.sol"; import { IPAccountImpl } from "contracts/IPAccountImpl.sol"; -import { IIPAccount } from "contracts/interfaces/IIPAccount.sol"; -import { IRegistrationModule } from "contracts/interfaces/modules/IRegistrationModule.sol"; -import { IIPAccountRegistry } from "contracts/interfaces/registries/IIPAccountRegistry.sol"; -import { IIPAssetRegistry } from "contracts/interfaces/registries/IIPAssetRegistry.sol"; -import { ILicenseRegistry } from "contracts/interfaces/registries/ILicenseRegistry.sol"; -import { Errors } from "contracts/lib/Errors.sol"; -import { Licensing } from "contracts/lib/Licensing.sol"; import { IP_RESOLVER_MODULE_KEY, REGISTRATION_MODULE_KEY, DISPUTE_MODULE_KEY } from "contracts/lib/modules/Module.sol"; import { IPMetadataProvider } from "contracts/registries/metadata/IPMetadataProvider.sol"; import { IPAccountRegistry } from "contracts/registries/IPAccountRegistry.sol"; @@ -44,20 +31,16 @@ import { ArbitrationPolicySP } from "contracts/modules/dispute-module/policies/A // test import { MockERC20 } from "test/foundry/mocks/MockERC20.sol"; import { MockERC721 } from "test/foundry/mocks/MockERC721.sol"; -import { MockModule } from "test/foundry/mocks/MockModule.sol"; import { MockUSDC } from "test/foundry/mocks/MockUSDC.sol"; import { MockRoyaltyPolicyLS } from "test/foundry/mocks/MockRoyaltyPolicyLS.sol"; import { Users, UsersLib } from "test/foundry/utils/Users.sol"; - struct MockERC721s { MockERC721 ape; MockERC721 cat; MockERC721 dog; } -import "forge-std/console2.sol"; - contract DeployHelper is Test { ERC6551Registry internal erc6551Registry; IPAccountImpl internal ipAccountImpl; @@ -117,7 +100,7 @@ contract DeployHelper is Test { function _deployContracts() internal { governance = new Governance(u.admin); - + accessController = new AccessController(address(governance)); erc6551Registry = new ERC6551Registry(); ipAccountImpl = new IPAccountImpl(); @@ -151,11 +134,7 @@ contract DeployHelper is Test { address(ipResolver) ); taggingModule = new TaggingModule(); - disputeModule = new DisputeModule( - address(accessController), - address(ipAssetRegistry), - address(governance) - ); + disputeModule = new DisputeModule(address(accessController), address(ipAssetRegistry), address(governance)); ipAssetRenderer = new IPAssetRenderer( address(ipAssetRegistry), address(licenseRegistry), diff --git a/test/utils/TestHelper.sol b/test/foundry/utils/TestHelper.sol similarity index 94% rename from test/utils/TestHelper.sol rename to test/foundry/utils/TestHelper.sol index 7a319f30..52e77b95 100644 --- a/test/utils/TestHelper.sol +++ b/test/foundry/utils/TestHelper.sol @@ -2,16 +2,18 @@ pragma solidity ^0.8.23; // external -import { console2 } from "forge-std/console2.sol"; +// solhint-disable no-console +import { console2 } from "forge-std/console2.sol"; // console to indicate setUp call. import { Test } from "forge-std/Test.sol"; // contracts import { UMLPolicyFrameworkManager, UMLPolicy } from "contracts/modules/licensing/UMLPolicyFrameworkManager.sol"; // test +// solhint-disable-next-line max-line-length import { UMLPolicyGenericParams, UMLPolicyCommercialParams, UMLPolicyDerivativeParams } from "test/foundry/integration/shared/LicenseHelper.sol"; import { MockERC721 } from "test/foundry/mocks/MockERC721.sol"; -import { DeployHelper } from "test/utils/DeployHelper.sol"; +import { DeployHelper } from "test/foundry/utils/DeployHelper.sol"; struct PolicyFrameworkManagerData { string name; @@ -45,6 +47,7 @@ contract TestHelper is Test, DeployHelper { string[] internal emptyStringArray = new string[](0); function setUp() public virtual { + // solhint-disable no-console console2.log("TestHelper.setUp"); deployer = vm.addr(accountA); arbitrationRelayer = vm.addr(accountC); @@ -101,8 +104,7 @@ contract TestHelper is Test, DeployHelper { contentRestrictions: gparams.contentRestrictions, royaltyPolicy: cparams.royaltyPolicy }); - policyIds[pName] = UMLPolicyFrameworkManager(pfms["uml"].addr) - .registerPolicy(policies[pName]); + policyIds[pName] = UMLPolicyFrameworkManager(pfms["uml"].addr).registerPolicy(policies[pName]); } function _mapUMLPolicySimple( @@ -133,7 +135,7 @@ contract TestHelper is Test, DeployHelper { }); } - function _addUMLPolicyFromMapping(string memory name, address umlFramework) internal returns (uint256){ + function _addUMLPolicyFromMapping(string memory name, address umlFramework) internal returns (uint256) { string memory pName = string(abi.encodePacked("uml_", name)); policyIds[pName] = UMLPolicyFrameworkManager(umlFramework).registerPolicy(policies[pName]); return policyIds[pName]; @@ -149,7 +151,6 @@ contract TestHelper is Test, DeployHelper { return policyIds[pName]; } - function _getIpId(MockERC721 mnft, uint256 tokenId) internal view returns (address ipId) { return _getIpId(address(mnft), tokenId); } diff --git a/tsconfig.json b/tsconfig.json index 6d2760ef..fb188201 100644 --- a/tsconfig.json +++ b/tsconfig.json @@ -31,12 +31,12 @@ "resolveJsonModule": true, "sourceMap": true, "forceConsistentCasingInFileNames": true, - "types": ["jest", "node"], + "types": ["node"], "baseUrl": "src", "paths": { "@gtp/*": ["./*"] } }, - "include": ["scripts/**/*"], + "include": ["script/hardhat/**/*"], "exclude": ["node_modules"] } diff --git a/yarn.lock b/yarn.lock index 555f60a9..92a9e312 100644 --- a/yarn.lock +++ b/yarn.lock @@ -147,120 +147,11 @@ resolved "https://registry.yarnpkg.com/@eslint/js/-/js-8.56.0.tgz#ef20350fec605a7f7035a01764731b2de0f3782b" integrity sha512-gMsVel9D7f2HLkBma9VbtzZRehRogVRfbr++f06nL2vnCGCNlzOD+/MUov/F4p8myyAHspEhVobgjpX64q5m6A== -"@ethereum-waffle/chai@4.0.10": - version "4.0.10" - resolved "https://registry.yarnpkg.com/@ethereum-waffle/chai/-/chai-4.0.10.tgz#6f600a40b6fdaed331eba42b8625ff23f3a0e59a" - integrity sha512-X5RepE7Dn8KQLFO7HHAAe+KeGaX/by14hn90wePGBhzL54tq4Y8JscZFu+/LCwCl6TnkAAy5ebiMoqJ37sFtWw== - dependencies: - "@ethereum-waffle/provider" "4.0.5" - debug "^4.3.4" - json-bigint "^1.0.0" - -"@ethereum-waffle/compiler@4.0.3": - version "4.0.3" - resolved "https://registry.yarnpkg.com/@ethereum-waffle/compiler/-/compiler-4.0.3.tgz#069e2df24b879b8a7b78857bad6f8bf6ebc8a5b1" - integrity sha512-5x5U52tSvEVJS6dpCeXXKvRKyf8GICDwiTwUvGD3/WD+DpvgvaoHOL82XqpTSUHgV3bBq6ma5/8gKUJUIAnJCw== - dependencies: - "@resolver-engine/imports" "^0.3.3" - "@resolver-engine/imports-fs" "^0.3.3" - "@typechain/ethers-v5" "^10.0.0" - "@types/mkdirp" "^0.5.2" - "@types/node-fetch" "^2.6.1" - mkdirp "^0.5.1" - node-fetch "^2.6.7" - -"@ethereum-waffle/ens@4.0.3": - version "4.0.3" - resolved "https://registry.yarnpkg.com/@ethereum-waffle/ens/-/ens-4.0.3.tgz#4a46ac926414f3c83b4e8cc2562c8e2aee06377a" - integrity sha512-PVLcdnTbaTfCrfSOrvtlA9Fih73EeDvFS28JQnT5M5P4JMplqmchhcZB1yg/fCtx4cvgHlZXa0+rOCAk2Jk0Jw== - -"@ethereum-waffle/mock-contract@4.0.4": - version "4.0.4" - resolved "https://registry.yarnpkg.com/@ethereum-waffle/mock-contract/-/mock-contract-4.0.4.tgz#f13fea29922d87a4d2e7c4fc8fe72ea04d2c13de" - integrity sha512-LwEj5SIuEe9/gnrXgtqIkWbk2g15imM/qcJcxpLyAkOj981tQxXmtV4XmQMZsdedEsZ/D/rbUAOtZbgwqgUwQA== - -"@ethereum-waffle/provider@4.0.5": - version "4.0.5" - resolved "https://registry.yarnpkg.com/@ethereum-waffle/provider/-/provider-4.0.5.tgz#8a65dbf0263f4162c9209608205dee1c960e716b" - integrity sha512-40uzfyzcrPh+Gbdzv89JJTMBlZwzya1YLDyim8mVbEqYLP5VRYWoGp0JMyaizgV3hMoUFRqJKVmIUw4v7r3hYw== - dependencies: - "@ethereum-waffle/ens" "4.0.3" - "@ganache/ethereum-options" "0.1.4" - debug "^4.3.4" - ganache "7.4.3" - -"@ethereumjs/block@^3.5.0", "@ethereumjs/block@^3.6.0", "@ethereumjs/block@^3.6.2": - version "3.6.3" - resolved "https://registry.yarnpkg.com/@ethereumjs/block/-/block-3.6.3.tgz#d96cbd7af38b92ebb3424223dbf773f5ccd27f84" - integrity sha512-CegDeryc2DVKnDkg5COQrE0bJfw/p0v3GBk2W5/Dj5dOVfEmb50Ux0GLnSPypooLnfqjwFaorGuT9FokWB3GRg== - dependencies: - "@ethereumjs/common" "^2.6.5" - "@ethereumjs/tx" "^3.5.2" - ethereumjs-util "^7.1.5" - merkle-patricia-tree "^4.2.4" - -"@ethereumjs/blockchain@^5.5.0": - version "5.5.3" - resolved "https://registry.yarnpkg.com/@ethereumjs/blockchain/-/blockchain-5.5.3.tgz#aa49a6a04789da6b66b5bcbb0d0b98efc369f640" - integrity sha512-bi0wuNJ1gw4ByNCV56H0Z4Q7D+SxUbwyG12Wxzbvqc89PXLRNR20LBcSUZRKpN0+YCPo6m0XZL/JLio3B52LTw== - dependencies: - "@ethereumjs/block" "^3.6.2" - "@ethereumjs/common" "^2.6.4" - "@ethereumjs/ethash" "^1.1.0" - debug "^4.3.3" - ethereumjs-util "^7.1.5" - level-mem "^5.0.1" - lru-cache "^5.1.1" - semaphore-async-await "^1.5.1" - -"@ethereumjs/common@2.6.0": - version "2.6.0" - resolved "https://registry.yarnpkg.com/@ethereumjs/common/-/common-2.6.0.tgz#feb96fb154da41ee2cc2c5df667621a440f36348" - integrity sha512-Cq2qS0FTu6O2VU1sgg+WyU9Ps0M6j/BEMHN+hRaECXCV/r0aI78u4N6p52QW/BDVhwWZpCdrvG8X7NJdzlpNUA== - dependencies: - crc-32 "^1.2.0" - ethereumjs-util "^7.1.3" - -"@ethereumjs/common@^2.6.0", "@ethereumjs/common@^2.6.4", "@ethereumjs/common@^2.6.5": - version "2.6.5" - resolved "https://registry.yarnpkg.com/@ethereumjs/common/-/common-2.6.5.tgz#0a75a22a046272579d91919cb12d84f2756e8d30" - integrity sha512-lRyVQOeCDaIVtgfbowla32pzeDv2Obr8oR8Put5RdUBNRGr1VGPGQNGP6elWIpgK3YdpzqTOh4GyUGOureVeeA== - dependencies: - crc-32 "^1.2.0" - ethereumjs-util "^7.1.5" - -"@ethereumjs/ethash@^1.1.0": - version "1.1.0" - resolved "https://registry.yarnpkg.com/@ethereumjs/ethash/-/ethash-1.1.0.tgz#7c5918ffcaa9cb9c1dc7d12f77ef038c11fb83fb" - integrity sha512-/U7UOKW6BzpA+Vt+kISAoeDie1vAvY4Zy2KF5JJb+So7+1yKmJeJEHOGSnQIj330e9Zyl3L5Nae6VZyh2TJnAA== - dependencies: - "@ethereumjs/block" "^3.5.0" - "@types/levelup" "^4.3.0" - buffer-xor "^2.0.1" - ethereumjs-util "^7.1.1" - miller-rabin "^4.0.0" - "@ethereumjs/rlp@^4.0.1": version "4.0.1" resolved "https://registry.yarnpkg.com/@ethereumjs/rlp/-/rlp-4.0.1.tgz#626fabfd9081baab3d0a3074b0c7ecaf674aaa41" integrity sha512-tqsQiBQDQdmPWE1xkkBq4rlSW5QZpLOUJ5RJh2/9fug+q9tnUhuZoVLk7s0scUIKTOzEtR72DFBXI4WiZcMpvw== -"@ethereumjs/tx@3.4.0": - version "3.4.0" - resolved "https://registry.yarnpkg.com/@ethereumjs/tx/-/tx-3.4.0.tgz#7eb1947eefa55eb9cf05b3ca116fb7a3dbd0bce7" - integrity sha512-WWUwg1PdjHKZZxPPo274ZuPsJCWV3SqATrEKQP1n2DrVYVP1aZIYpo/mFaA0BDoE0tIQmBeimRCEA0Lgil+yYw== - dependencies: - "@ethereumjs/common" "^2.6.0" - ethereumjs-util "^7.1.3" - -"@ethereumjs/tx@^3.4.0", "@ethereumjs/tx@^3.5.2": - version "3.5.2" - resolved "https://registry.yarnpkg.com/@ethereumjs/tx/-/tx-3.5.2.tgz#197b9b6299582ad84f9527ca961466fce2296c1c" - integrity sha512-gQDNJWKrSDGu2w7w0PzVXVBNMzb7wwdDOmOqczmhNjqFxFuIbhVJDwiGEnxFNC2/b8ifcZzY7MLcluizohRzNw== - dependencies: - "@ethereumjs/common" "^2.6.4" - ethereumjs-util "^7.1.5" - "@ethereumjs/util@^8.1.0": version "8.1.0" resolved "https://registry.yarnpkg.com/@ethereumjs/util/-/util-8.1.0.tgz#299df97fb6b034e0577ce9f94c7d9d1004409ed4" @@ -270,24 +161,6 @@ ethereum-cryptography "^2.0.0" micro-ftch "^0.3.1" -"@ethereumjs/vm@5.6.0": - version "5.6.0" - resolved "https://registry.yarnpkg.com/@ethereumjs/vm/-/vm-5.6.0.tgz#e0ca62af07de820143674c30b776b86c1983a464" - integrity sha512-J2m/OgjjiGdWF2P9bj/4LnZQ1zRoZhY8mRNVw/N3tXliGI8ai1sI1mlDPkLpeUUM4vq54gH6n0ZlSpz8U/qlYQ== - dependencies: - "@ethereumjs/block" "^3.6.0" - "@ethereumjs/blockchain" "^5.5.0" - "@ethereumjs/common" "^2.6.0" - "@ethereumjs/tx" "^3.4.0" - async-eventemitter "^0.2.4" - core-js-pure "^3.0.1" - debug "^2.2.0" - ethereumjs-util "^7.1.3" - functional-red-black-tree "^1.0.1" - mcl-wasm "^0.7.1" - merkle-patricia-tree "^4.2.2" - rustbn.js "~0.2.0" - "@ethersproject/abi@5.7.0", "@ethersproject/abi@^5.0.9", "@ethersproject/abi@^5.1.2", "@ethersproject/abi@^5.7.0": version "5.7.0" resolved "https://registry.yarnpkg.com/@ethersproject/abi/-/abi-5.7.0.tgz#b3f3e045bbbeed1af3947335c247ad625a44e449" @@ -635,68 +508,6 @@ resolved "https://registry.yarnpkg.com/@fastify/busboy/-/busboy-2.1.0.tgz#0709e9f4cb252351c609c6e6d8d6779a8d25edff" integrity sha512-+KpH+QxZU7O4675t3mnkQKcZZg56u+K/Ct2K+N2AZYNVK8kyeo/bI18tI8aPm3tvNNRyTWfj6s5tnGNlcbQRsA== -"@ganache/ethereum-address@0.1.4": - version "0.1.4" - resolved "https://registry.yarnpkg.com/@ganache/ethereum-address/-/ethereum-address-0.1.4.tgz#0e6d66f4a24f64bf687cb3ff7358fb85b9d9005e" - integrity sha512-sTkU0M9z2nZUzDeHRzzGlW724xhMLXo2LeX1hixbnjHWY1Zg1hkqORywVfl+g5uOO8ht8T0v+34IxNxAhmWlbw== - dependencies: - "@ganache/utils" "0.1.4" - -"@ganache/ethereum-options@0.1.4": - version "0.1.4" - resolved "https://registry.yarnpkg.com/@ganache/ethereum-options/-/ethereum-options-0.1.4.tgz#6a559abb44225e2b8741a8f78a19a46714a71cd6" - integrity sha512-i4l46taoK2yC41FPkcoDlEVoqHS52wcbHPqJtYETRWqpOaoj9hAg/EJIHLb1t6Nhva2CdTO84bG+qlzlTxjAHw== - dependencies: - "@ganache/ethereum-address" "0.1.4" - "@ganache/ethereum-utils" "0.1.4" - "@ganache/options" "0.1.4" - "@ganache/utils" "0.1.4" - bip39 "3.0.4" - seedrandom "3.0.5" - -"@ganache/ethereum-utils@0.1.4": - version "0.1.4" - resolved "https://registry.yarnpkg.com/@ganache/ethereum-utils/-/ethereum-utils-0.1.4.tgz#fae4b5b9e642e751ff1fa0cd7316c92996317257" - integrity sha512-FKXF3zcdDrIoCqovJmHLKZLrJ43234Em2sde/3urUT/10gSgnwlpFmrv2LUMAmSbX3lgZhW/aSs8krGhDevDAg== - dependencies: - "@ethereumjs/common" "2.6.0" - "@ethereumjs/tx" "3.4.0" - "@ethereumjs/vm" "5.6.0" - "@ganache/ethereum-address" "0.1.4" - "@ganache/rlp" "0.1.4" - "@ganache/utils" "0.1.4" - emittery "0.10.0" - ethereumjs-abi "0.6.8" - ethereumjs-util "7.1.3" - -"@ganache/options@0.1.4": - version "0.1.4" - resolved "https://registry.yarnpkg.com/@ganache/options/-/options-0.1.4.tgz#325b07e6de85094667aaaaf3d653e32404a04b78" - integrity sha512-zAe/craqNuPz512XQY33MOAG6Si1Xp0hCvfzkBfj2qkuPcbJCq6W/eQ5MB6SbXHrICsHrZOaelyqjuhSEmjXRw== - dependencies: - "@ganache/utils" "0.1.4" - bip39 "3.0.4" - seedrandom "3.0.5" - -"@ganache/rlp@0.1.4": - version "0.1.4" - resolved "https://registry.yarnpkg.com/@ganache/rlp/-/rlp-0.1.4.tgz#f4043afda83e1a14a4f80607b103daf166a9b374" - integrity sha512-Do3D1H6JmhikB+6rHviGqkrNywou/liVeFiKIpOBLynIpvZhRCgn3SEDxyy/JovcaozTo/BynHumfs5R085MFQ== - dependencies: - "@ganache/utils" "0.1.4" - rlp "2.2.6" - -"@ganache/utils@0.1.4": - version "0.1.4" - resolved "https://registry.yarnpkg.com/@ganache/utils/-/utils-0.1.4.tgz#25d60d7689e3dda6a8a7ad70e3646f07c2c39a1f" - integrity sha512-oatUueU3XuXbUbUlkyxeLLH3LzFZ4y5aSkNbx6tjSIhVTPeh+AuBKYt4eQ73FFcTB3nj/gZoslgAh5CN7O369w== - dependencies: - emittery "0.10.0" - keccak "3.0.1" - seedrandom "3.0.5" - optionalDependencies: - "@trufflesuite/bigint-buffer" "1.1.9" - "@humanwhocodes/config-array@^0.11.13": version "0.11.14" resolved "https://registry.yarnpkg.com/@humanwhocodes/config-array/-/config-array-0.11.14.tgz#d78e481a039f7566ecc9660b4ea7fe6b1fec442b" @@ -1030,16 +841,6 @@ "@nomicfoundation/solidity-analyzer-win32-ia32-msvc" "0.1.1" "@nomicfoundation/solidity-analyzer-win32-x64-msvc" "0.1.1" -"@nomiclabs/hardhat-ethers@^2.2.3": - version "2.2.3" - resolved "https://registry.yarnpkg.com/@nomiclabs/hardhat-ethers/-/hardhat-ethers-2.2.3.tgz#b41053e360c31a32c2640c9a45ee981a7e603fe0" - integrity sha512-YhzPdzb612X591FOe68q+qXVXGG2ANZRvDo0RRUtimev85rCrAlv/TLMEZw5c+kq9AbzocLTVX/h2jVIFPL9Xg== - -"@nomiclabs/hardhat-waffle@^2.0.5": - version "2.0.6" - resolved "https://registry.yarnpkg.com/@nomiclabs/hardhat-waffle/-/hardhat-waffle-2.0.6.tgz#d11cb063a5f61a77806053e54009c40ddee49a54" - integrity sha512-+Wz0hwmJGSI17B+BhU/qFRZ1l6/xMW82QGXE/Gi+WTmwgJrQefuBs1lIf7hzQ1hLk6hpkvb/zwcNkpVKRYTQYg== - "@openzeppelin/contracts-upgradeable@5.0.1": version "5.0.1" resolved "https://registry.yarnpkg.com/@openzeppelin/contracts-upgradeable/-/contracts-upgradeable-5.0.1.tgz#ebc163cbed2de6b8b69bff628261d18deb912a81" @@ -1120,42 +921,36 @@ proper-lockfile "^4.1.1" solidity-ast "^0.4.51" -"@resolver-engine/core@^0.3.3": - version "0.3.3" - resolved "https://registry.yarnpkg.com/@resolver-engine/core/-/core-0.3.3.tgz#590f77d85d45bc7ecc4e06c654f41345db6ca967" - integrity sha512-eB8nEbKDJJBi5p5SrvrvILn4a0h42bKtbCTri3ZxCGt6UvoQyp7HnGOfki944bUjBSHKK3RvgfViHn+kqdXtnQ== - dependencies: - debug "^3.1.0" - is-url "^1.2.4" - request "^2.85.0" +"@pkgr/core@^0.1.0": + version "0.1.1" + resolved "https://registry.yarnpkg.com/@pkgr/core/-/core-0.1.1.tgz#1ec17e2edbec25c8306d424ecfbf13c7de1aaa31" + integrity sha512-cq8o4cWH0ibXh9VGi5P20Tu9XF/0fFXl9EUinr9QfTM7a7p0oTA4iJRCQWppXR1Pg8dSM0UCItCkPwsk9qWWYA== -"@resolver-engine/fs@^0.3.3": - version "0.3.3" - resolved "https://registry.yarnpkg.com/@resolver-engine/fs/-/fs-0.3.3.tgz#fbf83fa0c4f60154a82c817d2fe3f3b0c049a973" - integrity sha512-wQ9RhPUcny02Wm0IuJwYMyAG8fXVeKdmhm8xizNByD4ryZlx6PP6kRen+t/haF43cMfmaV7T3Cx6ChOdHEhFUQ== - dependencies: - "@resolver-engine/core" "^0.3.3" - debug "^3.1.0" +"@pnpm/config.env-replace@^1.1.0": + version "1.1.0" + resolved "https://registry.yarnpkg.com/@pnpm/config.env-replace/-/config.env-replace-1.1.0.tgz#ab29da53df41e8948a00f2433f085f54de8b3a4c" + integrity sha512-htyl8TWnKL7K/ESFa1oW2UB5lVDxuF5DpM7tBi6Hu2LNL3mWkIzNLG6N4zoCUP1lCKNxWy/3iu8mS8MvToGd6w== -"@resolver-engine/imports-fs@^0.3.3": - version "0.3.3" - resolved "https://registry.yarnpkg.com/@resolver-engine/imports-fs/-/imports-fs-0.3.3.tgz#4085db4b8d3c03feb7a425fbfcf5325c0d1e6c1b" - integrity sha512-7Pjg/ZAZtxpeyCFlZR5zqYkz+Wdo84ugB5LApwriT8XFeQoLwGUj4tZFFvvCuxaNCcqZzCYbonJgmGObYBzyCA== +"@pnpm/network.ca-file@^1.0.1": + version "1.0.2" + resolved "https://registry.yarnpkg.com/@pnpm/network.ca-file/-/network.ca-file-1.0.2.tgz#2ab05e09c1af0cdf2fcf5035bea1484e222f7983" + integrity sha512-YcPQ8a0jwYU9bTdJDpXjMi7Brhkr1mXsXrUJvjqM2mQDgkRiz8jFaQGOdaLxgjtUfQgZhKy/O3cG/YwmgKaxLA== dependencies: - "@resolver-engine/fs" "^0.3.3" - "@resolver-engine/imports" "^0.3.3" - debug "^3.1.0" + graceful-fs "4.2.10" -"@resolver-engine/imports@^0.3.3": - version "0.3.3" - resolved "https://registry.yarnpkg.com/@resolver-engine/imports/-/imports-0.3.3.tgz#badfb513bb3ff3c1ee9fd56073e3144245588bcc" - integrity sha512-anHpS4wN4sRMwsAbMXhMfOD/y4a4Oo0Cw/5+rue7hSwGWsDOQaAU1ClK1OxjUC35/peazxEl8JaSRRS+Xb8t3Q== +"@pnpm/npm-conf@^2.1.0": + version "2.2.2" + resolved "https://registry.yarnpkg.com/@pnpm/npm-conf/-/npm-conf-2.2.2.tgz#0058baf1c26cbb63a828f0193795401684ac86f0" + integrity sha512-UA91GwWPhFExt3IizW6bOeY/pQ0BkuNwKjk9iQW9KqxluGCrg4VenZ0/L+2Y0+ZOtme72EVvg6v0zo3AMQRCeA== dependencies: - "@resolver-engine/core" "^0.3.3" - debug "^3.1.0" - hosted-git-info "^2.6.0" - path-browserify "^1.0.0" - url "^0.11.0" + "@pnpm/config.env-replace" "^1.1.0" + "@pnpm/network.ca-file" "^1.0.1" + config-chain "^1.1.11" + +"@prettier/sync@^0.3.0": + version "0.3.0" + resolved "https://registry.yarnpkg.com/@prettier/sync/-/sync-0.3.0.tgz#91f2cfc23490a21586d1cf89c6f72157c000ca1e" + integrity sha512-3dcmCyAxIcxy036h1I7MQU/uEEBq8oLwf1CE3xeze+MPlgkdlb/+w6rGR/1dhp6Hqi17fRS6nvwnOzkESxEkOw== "@scure/base@~1.1.0", "@scure/base@~1.1.4": version "1.1.5" @@ -1264,6 +1059,11 @@ "@sentry/types" "5.30.0" tslib "^1.9.3" +"@sindresorhus/is@^5.2.0": + version "5.6.0" + resolved "https://registry.yarnpkg.com/@sindresorhus/is/-/is-5.6.0.tgz#41dd6093d34652cddb5d5bdeee04eafc33826668" + integrity sha512-TV7t8GKYaJWsn00tFDqBw8+Uqmr8A0fRU1tvTQhyZzGv0sJCGRQL3JGMI3ucuKo3XIZdUP+Lx7/gh2t3lewy7g== + "@smithy/types@^2.9.1": version "2.9.1" resolved "https://registry.yarnpkg.com/@smithy/types/-/types-2.9.1.tgz#ed04d4144eed3b8bd26d20fc85aae8d6e357ebb9" @@ -1295,7 +1095,14 @@ resolved "https://registry.yarnpkg.com/@solidity-parser/parser/-/parser-0.18.0.tgz#8e77a02a09ecce957255a2f48c9a7178ec191908" integrity sha512-yfORGUIPgLck41qyN7nbwJRAx17/jAIXCTanHOJZhB6PJ1iAk/84b/xlsVKFSyNyLXIj0dhppoE0+CRws7wlzA== -"@tenderly/hardhat-tenderly@^2.1.0": +"@szmarczak/http-timer@^5.0.1": + version "5.0.1" + resolved "https://registry.yarnpkg.com/@szmarczak/http-timer/-/http-timer-5.0.1.tgz#c7c1bf1141cdd4751b0399c8fc7b8b664cd5be3a" + integrity sha512-+PmQX0PiAYPMeVYe237LJAYvOMYW1j2rH5YROyS3b4CTVJum34HfRvKvAzozHAQG0TnHNdUfY9nCeUyRAs//cw== + dependencies: + defer-to-connect "^2.0.1" + +"@tenderly/hardhat-tenderly@^2.2.1": version "2.2.1" resolved "https://registry.yarnpkg.com/@tenderly/hardhat-tenderly/-/hardhat-tenderly-2.2.1.tgz#dfb8886d3eb290487e28863b12b6c8839c9e5bd7" integrity sha512-15Kc+YQtFv1jvG9/V5vurGFWbeRKl6srztsd8H11HjiLvsyf9EmXqsap79SZp0Q1EKIaWxC9KiAgzROzkRoi7A== @@ -1313,20 +1120,6 @@ tslog "^4.3.1" typescript "^5.2.2" -"@trufflesuite/bigint-buffer@1.1.10": - version "1.1.10" - resolved "https://registry.yarnpkg.com/@trufflesuite/bigint-buffer/-/bigint-buffer-1.1.10.tgz#a1d9ca22d3cad1a138b78baaf15543637a3e1692" - integrity sha512-pYIQC5EcMmID74t26GCC67946mgTJFiLXOT/BYozgrd4UEY2JHEGLhWi9cMiQCt5BSqFEvKkCHNnoj82SRjiEw== - dependencies: - node-gyp-build "4.4.0" - -"@trufflesuite/bigint-buffer@1.1.9": - version "1.1.9" - resolved "https://registry.yarnpkg.com/@trufflesuite/bigint-buffer/-/bigint-buffer-1.1.9.tgz#e2604d76e1e4747b74376d68f1312f9944d0d75d" - integrity sha512-bdM5cEGCOhDSwminryHJbRmXc1x7dPKg6Pqns3qyTwFlxsqUgxE29lsERS3PlIW1HTjoIGMUqsk1zQQwST1Yxw== - dependencies: - node-gyp-build "4.3.0" - "@tsconfig/node10@^1.0.7": version "1.0.9" resolved "https://registry.yarnpkg.com/@tsconfig/node10/-/node10-1.0.9.tgz#df4907fc07a886922637b15e02d4cebc4c0021b2" @@ -1347,14 +1140,6 @@ resolved "https://registry.yarnpkg.com/@tsconfig/node16/-/node16-1.0.4.tgz#0b92dcc0cc1c81f6f306a381f28e31b1a56536e9" integrity sha512-vxhUy4J8lyeyinH7Azl1pdd43GJhZH/tP2weN8TntQblOY+A0XbT8DJk1/oCPuOOyg/Ja757rG0CgHcWC8OfMA== -"@typechain/ethers-v5@^10.0.0": - version "10.2.1" - resolved "https://registry.yarnpkg.com/@typechain/ethers-v5/-/ethers-v5-10.2.1.tgz#50241e6957683281ecfa03fb5a6724d8a3ce2391" - integrity sha512-n3tQmCZjRE6IU4h6lqUGiQ1j866n5MTCBJreNEHHVWXa2u9GJTaeYyU1/k+1qLutkyw+sS6VAN+AbeiTqsxd/A== - dependencies: - lodash "^4.17.15" - ts-essentials "^7.0.1" - "@typechain/ethers-v6@^0.5.1": version "0.5.1" resolved "https://registry.yarnpkg.com/@typechain/ethers-v6/-/ethers-v6-0.5.1.tgz#42fe214a19a8b687086c93189b301e2b878797ea" @@ -1370,11 +1155,6 @@ dependencies: fs-extra "^9.1.0" -"@types/abstract-leveldown@*": - version "7.2.5" - resolved "https://registry.yarnpkg.com/@types/abstract-leveldown/-/abstract-leveldown-7.2.5.tgz#db2cf364c159fb1f12be6cd3549f56387eaf8d73" - integrity sha512-/2B0nQF4UdupuxeKTJA2+Rj1D+uDemo6P4kMwKCpbfpnzeVaWSELTsAw4Lxn3VJD6APtRrZOCuYo+4nHUQfTfg== - "@types/bn.js@^4.11.3": version "4.11.6" resolved "https://registry.yarnpkg.com/@types/bn.js/-/bn.js-4.11.6.tgz#c306c70d9358aaea33cd4eda092a742b9505967c" @@ -1411,21 +1191,12 @@ "@types/minimatch" "*" "@types/node" "*" -"@types/level-errors@*": - version "3.0.2" - resolved "https://registry.yarnpkg.com/@types/level-errors/-/level-errors-3.0.2.tgz#f33ec813c50780b547463da9ad8acac89ee457d9" - integrity sha512-gyZHbcQ2X5hNXf/9KS2qGEmgDe9EN2WDM3rJ5Ele467C0nA1sLhtmv1bZiPMDYfAYCfPWft0uQIaTvXbASSTRA== - -"@types/levelup@^4.3.0": - version "4.3.3" - resolved "https://registry.yarnpkg.com/@types/levelup/-/levelup-4.3.3.tgz#4dc2b77db079b1cf855562ad52321aa4241b8ef4" - integrity sha512-K+OTIjJcZHVlZQN1HmU64VtrC0jC3dXWQozuEIR9zVvltIk90zaGPM2AgT+fIkChpzHhFE3YnvFLCbLtzAmexA== - dependencies: - "@types/abstract-leveldown" "*" - "@types/level-errors" "*" - "@types/node" "*" +"@types/http-cache-semantics@^4.0.2": + version "4.0.4" + resolved "https://registry.yarnpkg.com/@types/http-cache-semantics/-/http-cache-semantics-4.0.4.tgz#b979ebad3919799c979b17c72621c0bc0a31c6c4" + integrity sha512-1m0bIFVc7eJWyve9S0RnuRgcQqF/Xd5QsUZAZeQFr1Q3/p9JWoQQEqmVy+DPTNpGXwhgIetAoYF8JSc33q29QA== -"@types/lru-cache@5.1.1", "@types/lru-cache@^5.1.0": +"@types/lru-cache@^5.1.0": version "5.1.1" resolved "https://registry.yarnpkg.com/@types/lru-cache/-/lru-cache-5.1.1.tgz#c48c2e27b65d2a153b19bfc1a317e30872e01eef" integrity sha512-ssE3Vlrys7sdIzs5LOxCzTVMsU7i9oa/IaW92wF32JFb3CVczqOkru2xspuKczHEbG3nvmPY7IFqVmGGHdNbYw== @@ -1435,21 +1206,6 @@ resolved "https://registry.yarnpkg.com/@types/minimatch/-/minimatch-5.1.2.tgz#07508b45797cb81ec3f273011b054cd0755eddca" integrity sha512-K0VQKziLUWkVKiRVrx4a40iPaxTUefQmjtkQofBkYRcoaaL/8rhwDWww9qWbrgicNOgnpIsMxyNIUM4+n6dUIA== -"@types/mkdirp@^0.5.2": - version "0.5.2" - resolved "https://registry.yarnpkg.com/@types/mkdirp/-/mkdirp-0.5.2.tgz#503aacfe5cc2703d5484326b1b27efa67a339c1f" - integrity sha512-U5icWpv7YnZYGsN4/cmh3WD2onMY0aJIiTE6+51TwJCttdHvtCYmkBNOobHlXwrJRL0nkH9jH4kD+1FAdMN4Tg== - dependencies: - "@types/node" "*" - -"@types/node-fetch@^2.6.1": - version "2.6.11" - resolved "https://registry.yarnpkg.com/@types/node-fetch/-/node-fetch-2.6.11.tgz#9b39b78665dae0e82a08f02f4967d62c66f95d24" - integrity sha512-24xFj9R5+rfQJLRyM56qh+wnVSYhyXC2tkoBndtY0U+vubqNsYXGjufB2nn8Q6gt0LrARwL6UBtMCSVCwl4B1g== - dependencies: - "@types/node" "*" - form-data "^4.0.0" - "@types/node@*": version "20.11.16" resolved "https://registry.yarnpkg.com/@types/node/-/node-20.11.16.tgz#4411f79411514eb8e2926f036c86c9f0e4ec6708" @@ -1457,11 +1213,6 @@ dependencies: undici-types "~5.26.4" -"@types/node@11.11.6": - version "11.11.6" - resolved "https://registry.yarnpkg.com/@types/node/-/node-11.11.6.tgz#df929d1bb2eee5afdda598a41930fe50b43eaa6a" - integrity sha512-Exw4yUWMBXM3X+8oqzJNRqZSwUAaS4+7NdvHqQuFi/d+synz++xmX3QIf+BFqneW8N31R8Ky+sikfZUXq07ggQ== - "@types/node@18.15.13": version "18.15.13" resolved "https://registry.yarnpkg.com/@types/node/-/node-18.15.13.tgz#f64277c341150c979e42b00e4ac289290c9df469" @@ -1509,11 +1260,6 @@ dependencies: "@types/node" "*" -"@types/seedrandom@3.0.1": - version "3.0.1" - resolved "https://registry.yarnpkg.com/@types/seedrandom/-/seedrandom-3.0.1.tgz#1254750a4fec4aff2ebec088ccd0bb02e91fedb4" - integrity sha512-giB9gzDeiCeloIXDgzFBCgjj1k4WxcDrZtGl6h1IqmUPlxF+Nx8Ve+96QCyDZ/HseB/uvDsKbpib9hU5cU53pw== - "@ungap/structured-clone@^1.2.0": version "1.2.0" resolved "https://registry.yarnpkg.com/@ungap/structured-clone/-/structured-clone-1.2.0.tgz#756641adb587851b5ccb3e095daf27ae581c8406" @@ -1542,40 +1288,6 @@ abstract-level@^1.0.0, abstract-level@^1.0.2, abstract-level@^1.0.3, abstract-le module-error "^1.0.1" queue-microtask "^1.2.3" -abstract-leveldown@^6.2.1: - version "6.3.0" - resolved "https://registry.yarnpkg.com/abstract-leveldown/-/abstract-leveldown-6.3.0.tgz#d25221d1e6612f820c35963ba4bd739928f6026a" - integrity sha512-TU5nlYgta8YrBMNpc9FwQzRbiXsj49gsALsXadbGHt9CROPzX5fB0rWDR5mtdpOOKa5XqRFpbj1QroPAoPzVjQ== - dependencies: - buffer "^5.5.0" - immediate "^3.2.3" - level-concat-iterator "~2.0.0" - level-supports "~1.0.0" - xtend "~4.0.0" - -abstract-leveldown@^7.2.0: - version "7.2.0" - resolved "https://registry.yarnpkg.com/abstract-leveldown/-/abstract-leveldown-7.2.0.tgz#08d19d4e26fb5be426f7a57004851b39e1795a2e" - integrity sha512-DnhQwcFEaYsvYDnACLZhMmCWd3rkOeEvglpa4q5i/5Jlm3UIsWaxVzuXvDLFCSCWRO3yy2/+V/G7FusFgejnfQ== - dependencies: - buffer "^6.0.3" - catering "^2.0.0" - is-buffer "^2.0.5" - level-concat-iterator "^3.0.0" - level-supports "^2.0.1" - queue-microtask "^1.2.3" - -abstract-leveldown@~6.2.1: - version "6.2.3" - resolved "https://registry.yarnpkg.com/abstract-leveldown/-/abstract-leveldown-6.2.3.tgz#036543d87e3710f2528e47040bc3261b77a9a8eb" - integrity sha512-BsLm5vFMRUrrLeCcRc+G0t2qOaTzpoJQLOubq2XM72eNpjF5UdU5o/5NvlNhx95XHcAvcl8OMXr4mlg/fRgUXQ== - dependencies: - buffer "^5.5.0" - immediate "^3.2.3" - level-concat-iterator "~2.0.0" - level-supports "~1.0.0" - xtend "~4.0.0" - acorn-jsx@^5.3.2: version "5.3.2" resolved "https://registry.yarnpkg.com/acorn-jsx/-/acorn-jsx-5.3.2.tgz#7ed5bb55908b3b2f1bc55c6af1653bada7f07937" @@ -1626,7 +1338,7 @@ aggregate-error@^3.0.0: clean-stack "^2.0.0" indent-string "^4.0.0" -ajv@^6.12.3, ajv@^6.12.4, ajv@^6.12.6: +ajv@^6.12.4, ajv@^6.12.6: version "6.12.6" resolved "https://registry.yarnpkg.com/ajv/-/ajv-6.12.6.tgz#baf5a62e802b07d977034586f8c3baf5adf26df4" integrity sha512-j3fVLgvTo527anyYyJOGTYJbG+vnnQYvE0m5mmkc1TK+nxAppkCLMIL0aZ4dblVCNoGShhm+kzE4ZUykBoMg4g== @@ -1803,22 +1515,10 @@ asap@~2.0.6: resolved "https://registry.yarnpkg.com/asap/-/asap-2.0.6.tgz#e50347611d7e690943208bbdafebcbc2fb866d46" integrity sha512-BSHWgDSAiKs50o2Re8ppvp3seVHXSRM44cdSsT9FfNEUUZLOGWVCsiWaRPWM1Znn+mqZ1OfVZ3z3DWEzSp7hRA== -asn1@~0.2.3: - version "0.2.6" - resolved "https://registry.yarnpkg.com/asn1/-/asn1-0.2.6.tgz#0d3a7bb6e64e02a90c0303b31f292868ea09a08d" - integrity sha512-ix/FxPn0MDjeyJ7i/yoHGFt/EX6LyNbxSEhPPXODPL+KB0VPk86UYfL0lMdy+KCnv+fmvIzySwaK5COwqVbWTQ== - dependencies: - safer-buffer "~2.1.0" - -assert-plus@1.0.0, assert-plus@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/assert-plus/-/assert-plus-1.0.0.tgz#f12e0f3c5d77b0b1cdd9146942e4e96c1e4dd525" - integrity sha512-NfJ4UzBCcQGLDlQq7nHxH+tv3kyZ0hHQqF5BO6J7tNJeP5do1llPr8dZ8zHonfhAu0PHAdMkSo+8o0wxg9lZWw== - -assertion-error@^1.1.0: - version "1.1.0" - resolved "https://registry.yarnpkg.com/assertion-error/-/assertion-error-1.1.0.tgz#e60b6b0e8f301bd97e5375215bda406c85118c0b" - integrity sha512-jgsaNduz+ndvGyFt3uSuWqvy4lCnIJiovtouQN5JZHOKCS2QuhEdbcQHFhVksz2N2U9hXJo8odG7ETyWlEeuDw== +assertion-error@^2.0.1: + version "2.0.1" + resolved "https://registry.yarnpkg.com/assertion-error/-/assertion-error-2.0.1.tgz#f641a196b335690b1070bf00b6e7593fec190bf7" + integrity sha512-Izi8RQcffqCeNVgFigKli1ssklIbpHnCYc6AknXGYoB6grJqyeby7jv12JUQgmTAnIDnbck1uxksT4dzN3PWBA== ast-parents@^0.0.1: version "0.0.1" @@ -1830,13 +1530,6 @@ astral-regex@^2.0.0: resolved "https://registry.yarnpkg.com/astral-regex/-/astral-regex-2.0.0.tgz#483143c567aeed4785759c0865786dc77d7d2e31" integrity sha512-Z7tMw1ytTXt5jqMcOP+OQteU1VuNK9Y02uuJtKQ1Sv69jXQKKg5cibLwGJow8yzZP+eAc18EmLGPal0bp36rvQ== -async-eventemitter@^0.2.4: - version "0.2.4" - resolved "https://registry.yarnpkg.com/async-eventemitter/-/async-eventemitter-0.2.4.tgz#f5e7c8ca7d3e46aab9ec40a292baf686a0bafaca" - integrity sha512-pd20BwL7Yt1zwDFy+8MX8F1+WCT8aQeKj0kQnTrH9WaeRETlRamVhD0JtRPmrV4GfOJ2F9CvdQkZeZhnh2TuHw== - dependencies: - async "^2.4.0" - async-retry@^1.3.3: version "1.3.3" resolved "https://registry.yarnpkg.com/async-retry/-/async-retry-1.3.3.tgz#0e7f36c04d8478e7a58bdbed80cedf977785f280" @@ -1849,13 +1542,6 @@ async@1.x: resolved "https://registry.yarnpkg.com/async/-/async-1.5.2.tgz#ec6a61ae56480c0c3cb241c95618e20892f9672a" integrity sha512-nSVgobk4rv61R9PUSDtYt7mPVB2olxNR5RWJcAsH676/ef11bUZwvu7+RGYrYauVdDPcO519v68wRhXQtxsV9w== -async@^2.4.0: - version "2.6.4" - resolved "https://registry.yarnpkg.com/async/-/async-2.6.4.tgz#706b7ff6084664cd7eae713f6f965433b5504221" - integrity sha512-mzo5dfJYwAn29PeiJ0zvwTo04zj8HDJj0Mn8TD7sno7q12prdbnasKJHhkm2c1LgrhlJ0teaea8860oxi51mGA== - dependencies: - lodash "^4.17.14" - asynckit@^0.4.0: version "0.4.0" resolved "https://registry.yarnpkg.com/asynckit/-/asynckit-0.4.0.tgz#c79ed97f7f34cb8f2ba1bc9790bcc366474b4b79" @@ -1871,16 +1557,6 @@ available-typed-arrays@^1.0.5, available-typed-arrays@^1.0.6: resolved "https://registry.yarnpkg.com/available-typed-arrays/-/available-typed-arrays-1.0.6.tgz#ac812d8ce5a6b976d738e1c45f08d0b00bc7d725" integrity sha512-j1QzY8iPNPG4o4xmO3ptzpRxTciqD3MgEHtifP/YnJpIo58Xu+ne4BejlbkuaLfXn/nz6HFiw29bLpj2PNMdGg== -aws-sign2@~0.7.0: - version "0.7.0" - resolved "https://registry.yarnpkg.com/aws-sign2/-/aws-sign2-0.7.0.tgz#b46e890934a9591f2d2f6f86d7e6a9f1b3fe76a8" - integrity sha512-08kcGqnYf/YmjoRhfxyu+CLxBjUtHLXLXX/vUfx9l2LYzG3c1m61nrpyFUZI6zeS+Li/wWMMidD9KgrqtGq3mA== - -aws4@^1.8.0: - version "1.12.0" - resolved "https://registry.yarnpkg.com/aws4/-/aws4-1.12.0.tgz#ce1c9d143389679e253b314241ea9aa5cec980d3" - integrity sha512-NmWvPnx0F1SfrQbYwOi7OeaNGokp9XhzNioJ/CSBs8Qa4vxug81mhJEAVZwxXuBmYB5KDRfMq/F3RR0BIU7sWg== - axios@^0.21.1: version "0.21.4" resolved "https://registry.yarnpkg.com/axios/-/axios-0.21.4.tgz#c67b90dc0568e5c1cf2b0b858c43ba28e2eda575" @@ -1927,13 +1603,6 @@ base64-sol@^1.1.0: resolved "https://registry.yarnpkg.com/base64-sol/-/base64-sol-1.1.0.tgz#39c3c91a35790b6eb3b8e73114b46bacf0fc2865" integrity sha512-mksLxtFyBcXd3LYK5UxyMj29YR//zoaeXpJaKRbnLQC0E99oCJl7VpKaJDXWAuTvnhxBU9XNYzhxSL8umsrxWg== -bcrypt-pbkdf@^1.0.0: - version "1.0.2" - resolved "https://registry.yarnpkg.com/bcrypt-pbkdf/-/bcrypt-pbkdf-1.0.2.tgz#a4301d389b6a43f9b67ff3ca11a3f6637e360e9e" - integrity sha512-qeFIXtP4MSoi6NLqO12WfqARWWuCKi2Rn/9hJLEmtB5yTNr9DqFWkJRCf2qShWzPeAMRnOgCrq0sg/KLv5ES9w== - dependencies: - tweetnacl "^0.14.3" - bech32@1.1.4: version "1.1.4" resolved "https://registry.yarnpkg.com/bech32/-/bech32-1.1.4.tgz#e38c9f37bf179b8eb16ae3a772b40c356d4832e9" @@ -1944,26 +1613,11 @@ bigint-crypto-utils@^3.0.23: resolved "https://registry.yarnpkg.com/bigint-crypto-utils/-/bigint-crypto-utils-3.3.0.tgz#72ad00ae91062cf07f2b1def9594006c279c1d77" integrity sha512-jOTSb+drvEDxEq6OuUybOAv/xxoh3cuYRUIPyu8sSHQNKM303UQ2R1DAo45o1AkcIXw6fzbaFI1+xGGdaXs2lg== -bignumber.js@^9.0.0: - version "9.1.2" - resolved "https://registry.yarnpkg.com/bignumber.js/-/bignumber.js-9.1.2.tgz#b7c4242259c008903b13707983b5f4bbd31eda0c" - integrity sha512-2/mKyZH9K85bzOEfhXDBFZTGd1CTs+5IHpeFQo9luiBG7hghdC851Pj2WAhb6E3R6b9tZj/XKhbg4fum+Kepug== - binary-extensions@^2.0.0: version "2.2.0" resolved "https://registry.yarnpkg.com/binary-extensions/-/binary-extensions-2.2.0.tgz#75f502eeaf9ffde42fc98829645be4ea76bd9e2d" integrity sha512-jDctJ/IVQbZoJykoeHbhXpOlNBqGNcwXJKJog42E5HDPUwQTSdjCHdihjj0DlnheQ7blbT6dHOafNAiS8ooQKA== -bip39@3.0.4: - version "3.0.4" - resolved "https://registry.yarnpkg.com/bip39/-/bip39-3.0.4.tgz#5b11fed966840b5e1b8539f0f54ab6392969b2a0" - integrity sha512-YZKQlb752TrUWqHWj7XAwCSjYEgGAk+/Aas3V7NyjQeZYsztO8JnQUaCWhcnL4T+jL8nvB8typ2jRPzTlgugNw== - dependencies: - "@types/node" "11.11.6" - create-hash "^1.1.0" - pbkdf2 "^3.0.9" - randombytes "^2.0.1" - blakejs@^1.1.0: version "1.2.1" resolved "https://registry.yarnpkg.com/blakejs/-/blakejs-1.2.1.tgz#5057e4206eadb4a97f7c0b6e197a505042fc3814" @@ -1974,7 +1628,7 @@ bn.js@4.11.6: resolved "https://registry.yarnpkg.com/bn.js/-/bn.js-4.11.6.tgz#53344adb14617a13f6e8dd2ce28905d1c0ba3215" integrity sha512-XWwnNNFCuuSQ0m3r3C4LE3EiORltHd9M05pq6FOlVeiophzRbMo50Sbz1ehl8K3Z+jw9+vmgnXefY1hz8X+2wA== -bn.js@^4.0.0, bn.js@^4.11.0, bn.js@^4.11.1, bn.js@^4.11.8, bn.js@^4.11.9: +bn.js@^4.11.0, bn.js@^4.11.8, bn.js@^4.11.9: version "4.12.0" resolved "https://registry.yarnpkg.com/bn.js/-/bn.js-4.12.0.tgz#775b3f278efbb9718eec7361f483fb36fbbfea88" integrity sha512-c98Bf3tPniI+scsdk237ku1Dc3ujXQTSgyiPUDEOe7tRkhrqridvh8klBv0HCEso1OLOYcHuCv/cS6DNxKH+ZA== @@ -2020,7 +1674,7 @@ braces@^3.0.2, braces@~3.0.2: dependencies: fill-range "^7.0.1" -brorand@^1.0.1, brorand@^1.1.0: +brorand@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/brorand/-/brorand-1.1.0.tgz#12c25efe40a45e3c323eb8675a0a0ce57b22371f" integrity sha512-cKV8tMCEpQs4hK/ik71d6LrPOnpkpGBR0wzxqr68g2m/LB2GxVYQroAjMJZRVM1Y4BCjCKc3vAamxSzOY2RP+w== @@ -2078,13 +1732,6 @@ buffer-xor@^1.0.3: resolved "https://registry.yarnpkg.com/buffer-xor/-/buffer-xor-1.0.3.tgz#26e61ed1422fb70dd42e6e36729ed51d855fe8d9" integrity sha512-571s0T7nZWK6vB67HI5dyUF7wXiNcfaPPPTl6zYCNApANjIvYJTg7hlud/+cJpdAhS7dVzqMLmfhfHR3rAcOjQ== -buffer-xor@^2.0.1: - version "2.0.2" - resolved "https://registry.yarnpkg.com/buffer-xor/-/buffer-xor-2.0.2.tgz#34f7c64f04c777a1f8aac5e661273bb9dd320289" - integrity sha512-eHslX0bin3GB+Lx2p7lEYRShRewuNZL3fUl4qlVJGGiwoPGftmt8JQgk2Y9Ji5/01TnVDo33E5b5O3vUB1HdqQ== - dependencies: - safe-buffer "^5.1.1" - buffer@4.9.2: version "4.9.2" resolved "https://registry.yarnpkg.com/buffer/-/buffer-4.9.2.tgz#230ead344002988644841ab0244af8c44bbe3ef8" @@ -2094,14 +1741,6 @@ buffer@4.9.2: ieee754 "^1.1.4" isarray "^1.0.0" -buffer@^5.5.0, buffer@^5.6.0: - version "5.7.1" - resolved "https://registry.yarnpkg.com/buffer/-/buffer-5.7.1.tgz#ba62e7c13133053582197160851a8f648e99eed0" - integrity sha512-EHcyIPBQ4BSGlvjB16k5KgAJ27CIsHY/2JBmCRReo48y9rQ3MaUzWX3KVlBa4U7MyX02HdVj0K7C3WaB3ju7FQ== - dependencies: - base64-js "^1.3.1" - ieee754 "^1.1.13" - buffer@^6.0.3: version "6.0.3" resolved "https://registry.yarnpkg.com/buffer/-/buffer-6.0.3.tgz#2ace578459cc8fbe2a70aaa8f52ee63b6a74c6c6" @@ -2110,18 +1749,29 @@ buffer@^6.0.3: base64-js "^1.3.1" ieee754 "^1.2.1" -bufferutil@4.0.5: - version "4.0.5" - resolved "https://registry.yarnpkg.com/bufferutil/-/bufferutil-4.0.5.tgz#da9ea8166911cc276bf677b8aed2d02d31f59028" - integrity sha512-HTm14iMQKK2FjFLRTM5lAVcyaUzOnqbPtesFIvREgXpJHdQm8bWS+GkQgIkfaBYRHuCnea7w8UVNfwiAQhlr9A== - dependencies: - node-gyp-build "^4.3.0" - bytes@3.1.2: version "3.1.2" resolved "https://registry.yarnpkg.com/bytes/-/bytes-3.1.2.tgz#8b0beeb98605adf1b128fa4386403c009e0221a5" integrity sha512-/Nf7TyzTx6S3yRJObOAV7956r8cr2+Oj8AC5dt8wSP3BQAoeX58NoHyCU8P8zGkNXStjTSi6fzO6F0pBdcYbEg== +cacheable-lookup@^7.0.0: + version "7.0.0" + resolved "https://registry.yarnpkg.com/cacheable-lookup/-/cacheable-lookup-7.0.0.tgz#3476a8215d046e5a3202a9209dd13fec1f933a27" + integrity sha512-+qJyx4xiKra8mZrcwhjMRMUhD5NR1R8esPkzIYxX96JiecFoxAXFuz/GpR3+ev4PE1WamHip78wV0vcmPQtp8w== + +cacheable-request@^10.2.8: + version "10.2.14" + resolved "https://registry.yarnpkg.com/cacheable-request/-/cacheable-request-10.2.14.tgz#eb915b665fda41b79652782df3f553449c406b9d" + integrity sha512-zkDT5WAF4hSSoUgyfg5tFIxz8XQK+25W/TLVojJTMKBaxevLBBtLxgqguAuVQB8PVW79FVjHcU+GJ9tVbDZ9mQ== + dependencies: + "@types/http-cache-semantics" "^4.0.2" + get-stream "^6.0.1" + http-cache-semantics "^4.1.1" + keyv "^4.5.3" + mimic-response "^4.0.0" + normalize-url "^8.0.0" + responselike "^3.0.0" + call-bind@^1.0.2, call-bind@^1.0.5, call-bind@^1.0.6: version "1.0.6" resolved "https://registry.yarnpkg.com/call-bind/-/call-bind-1.0.6.tgz#6c46675fc7a5e9de82d75a233d586c8b7ac0d931" @@ -2152,7 +1802,7 @@ caseless@^0.12.0, caseless@~0.12.0: resolved "https://registry.yarnpkg.com/caseless/-/caseless-0.12.0.tgz#1b681c21ff84033c826543090689420d187151dc" integrity sha512-4tYFyifaFfGacoiObjJegolkwSU4xQNGbVgUiNYVUxbQ2x2lUsFvY4hVgVzGiIe6WLOPqycWXA40l+PWsxthUw== -catering@^2.0.0, catering@^2.1.0, catering@^2.1.1: +catering@^2.1.0, catering@^2.1.1: version "2.1.1" resolved "https://registry.yarnpkg.com/catering/-/catering-2.1.1.tgz#66acba06ed5ee28d5286133982a927de9a04b510" integrity sha512-K7Qy8O9p76sL3/3m7/zLKbRkyOlSZAgzEaLhyj2mXS8PsCud2Eo4hAb8aLtZqHh0QGqLcb9dlJSu6lHRVENm1w== @@ -2171,18 +1821,16 @@ cbor@^9.0.0: dependencies: nofilter "^3.1.0" -chai@^4.3.7: - version "4.4.1" - resolved "https://registry.yarnpkg.com/chai/-/chai-4.4.1.tgz#3603fa6eba35425b0f2ac91a009fe924106e50d1" - integrity sha512-13sOfMv2+DWduEU+/xbun3LScLoqN17nBeTLUsmDfKdoiC1fr0n9PU4guu4AhRcOVFk/sW8LyZWHuhWtQZiF+g== +chai@^5.0.3: + version "5.0.3" + resolved "https://registry.yarnpkg.com/chai/-/chai-5.0.3.tgz#db8e109373b86e7fb33d3ef0d0116f0fa8019066" + integrity sha512-wKGCtYv2kVY5WEjKqQ3fSIZWtTFveZCtzinhTZbx3/trVkxefiwovhpU9kRVCwxvKKCEjTWXPdM1/T7zPoDgow== dependencies: - assertion-error "^1.1.0" - check-error "^1.0.3" - deep-eql "^4.1.3" - get-func-name "^2.0.2" - loupe "^2.3.6" - pathval "^1.1.1" - type-detect "^4.0.8" + assertion-error "^2.0.1" + check-error "^2.0.0" + deep-eql "^5.0.1" + loupe "^3.1.0" + pathval "^2.0.0" chalk@^2.4.2: version "2.4.2" @@ -2206,12 +1854,10 @@ chalk@^4.0.0, chalk@^4.1.0, chalk@^4.1.2: resolved "https://registry.yarnpkg.com/charenc/-/charenc-0.0.2.tgz#c0a1d2f3a7092e03774bfa83f14c0fc5790a8667" integrity sha512-yrLQ/yVUFXkzg7EDQsPieE/53+0RlaWTs+wBrvW36cyilJ2SaDWfl4Yj7MtLTXleV9uEKefbAGUPv2/iWSooRA== -check-error@^1.0.3: - version "1.0.3" - resolved "https://registry.yarnpkg.com/check-error/-/check-error-1.0.3.tgz#a6502e4312a7ee969f646e83bb3ddd56281bd694" - integrity sha512-iKEoDYaRmd1mxM90a2OEfWhjsjPpYPuQ+lMYsoxB126+t8fw7ySEO48nmDg5COTjxDI65/Y2OWpeEHk3ZOe8zg== - dependencies: - get-func-name "^2.0.2" +check-error@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/check-error/-/check-error-2.0.0.tgz#589a4f201b6256fd93a2d165089fe43d2676d8c6" + integrity sha512-tjLAOBHKVxtPoHe/SA7kNOMvhCRdCJ3vETdeY0RuAc9popf+hyaSV6ZEg9hr4cpWF7jmo/JSWEnLDrnijS9Tog== chokidar@3.5.3: version "3.5.3" @@ -2334,7 +1980,7 @@ colors@1.4.0, colors@^1.1.2: resolved "https://registry.yarnpkg.com/colors/-/colors-1.4.0.tgz#c50491479d4c1bdaed2c9ced32cf7c7dc2360f78" integrity sha512-a+UqTh4kgZg/SlGvfbzDHpgRu7AAQOmmqRHJnxhRZICKFUT91brVhNNt58CMWU9PsBbv3PDCZUHbVxuDiH2mtA== -combined-stream@^1.0.6, combined-stream@^1.0.8, combined-stream@~1.0.6: +combined-stream@^1.0.6, combined-stream@^1.0.8: version "1.0.8" resolved "https://registry.yarnpkg.com/combined-stream/-/combined-stream-1.0.8.tgz#c3d45a8b34fd730631a110a8a2520682b31d5a7f" integrity sha512-FQN4MRfuJeHf7cBbBMJFXhKSDq+2kAArBlmRBvcvFE5BB1HZKXtSFASDhdlz9zOYwxh8lDdnvmMOe/+5cdoEdg== @@ -2376,10 +2022,10 @@ commander@^10.0.0: resolved "https://registry.yarnpkg.com/commander/-/commander-10.0.1.tgz#881ee46b4f77d1c1dccc5823433aa39b022cbe06" integrity sha512-y4Mg2tXshplEbSGzx7amzPwKKOCGuoSRP/CjEdwwk0FOGlUbq6lKuoyDZTNZkmxHdJtp54hdfY/JUrdL7Xfdug== -commander@^8.1.0: - version "8.3.0" - resolved "https://registry.yarnpkg.com/commander/-/commander-8.3.0.tgz#4837ea1b2da67b9c616a67afbb0fafee567bca66" - integrity sha512-OkTL9umf+He2DZkUq8f8J9of7yL6RJKI24dVITBmNfZBmri9zYZQrKkuXiKhyfPSu8tUhnVBB1iKXevvnlR4Ww== +commander@^11.1.0: + version "11.1.0" + resolved "https://registry.yarnpkg.com/commander/-/commander-11.1.0.tgz#62fdce76006a68e5c1ab3314dc92e800eb83d906" + integrity sha512-yPVavfyCcRhmorC7rWlkHn15b4wDVgVmBA7kV4QVBsF7kv/9TKJAbAXVTxvTnwP8HHKjRCJDClKbciiYS7p0DQ== commander@^9.4.0: version "9.5.0" @@ -2406,21 +2052,19 @@ concat-stream@^1.6.0, concat-stream@^1.6.2: readable-stream "^2.2.2" typedarray "^0.0.6" +config-chain@^1.1.11: + version "1.1.13" + resolved "https://registry.yarnpkg.com/config-chain/-/config-chain-1.1.13.tgz#fad0795aa6a6cdaff9ed1b68e9dff94372c232f4" + integrity sha512-qj+f8APARXHrM0hraqXYb2/bOVSV4PvJQlNZ/DVj0QrmNM2q2euizkeuVckQ57J+W0mRH6Hvi+k50M4Jul2VRQ== + dependencies: + ini "^1.3.4" + proto-list "~1.2.1" + cookie@^0.4.1: version "0.4.2" resolved "https://registry.yarnpkg.com/cookie/-/cookie-0.4.2.tgz#0e41f24de5ecf317947c82fc789e06a884824432" integrity sha512-aSWTXFzaKWkvHO1Ny/s+ePFpvKsPnjc551iI41v3ny/ow6tBG5Vd+FuqGNhh1LxOmVzOlGUriIlOaokOvhaStA== -core-js-pure@^3.0.1: - version "3.35.1" - resolved "https://registry.yarnpkg.com/core-js-pure/-/core-js-pure-3.35.1.tgz#f33ad7fdf9dddae260339a30e5f8363f5c49a3bc" - integrity sha512-zcIdi/CL3MWbBJYo5YCeVAAx+Sy9yJE9I3/u9LkFABwbeaPhTMRWraM8mYFp9jW5Z50hOy7FVzCc8dCrpZqtIQ== - -core-util-is@1.0.2: - version "1.0.2" - resolved "https://registry.yarnpkg.com/core-util-is/-/core-util-is-1.0.2.tgz#b5fd54220aa2bc5ab57aab7140c940754503c1a7" - integrity sha512-3lqz5YjWTYnW6dlDa5TLaTCcShfar1e40rmcJVwCBJC6mWlFuj0eCHIElmG1g5kyuJ/GD+8Wn4FFCcz4gJPfaQ== - core-util-is@~1.0.0: version "1.0.3" resolved "https://registry.yarnpkg.com/core-util-is/-/core-util-is-1.0.3.tgz#a6042d3634c2b27e9328f837b965fac83808db85" @@ -2483,52 +2127,36 @@ cross-spawn@^7.0.2: resolved "https://registry.yarnpkg.com/crypt/-/crypt-0.0.2.tgz#88d7ff7ec0dfb86f713dc87bbb42d044d3e6c41b" integrity sha512-mCxBlsHFYh9C+HVpiEacem8FEBnMXgU9gy4zmNC+SXAZNB/1idgp/aulFJ4FgCi7GPEVbfyng092GqL2k2rmow== -dashdash@^1.12.0: - version "1.14.1" - resolved "https://registry.yarnpkg.com/dashdash/-/dashdash-1.14.1.tgz#853cfa0f7cbe2fed5de20326b8dd581035f6e2f0" - integrity sha512-jRFi8UDGo6j+odZiEpjazZaWqEal3w/basFjQHQEwVtZJGDpxbH1MeYluwCS8Xq5wmLJooDlMgvVarmWfGM44g== - dependencies: - assert-plus "^1.0.0" - death@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/death/-/death-1.1.0.tgz#01aa9c401edd92750514470b8266390c66c67318" integrity sha512-vsV6S4KVHvTGxbEcij7hkWRv0It+sGGWVOM67dQde/o5Xjnr+KmLjxWJii2uEObIrt1CcM9w0Yaovx+iOlIL+w== -debug@4, debug@4.3.4, debug@^4.1.1, debug@^4.3.1, debug@^4.3.2, debug@^4.3.3, debug@^4.3.4: +debug@4, debug@4.3.4, debug@^4.1.1, debug@^4.3.1, debug@^4.3.2, debug@^4.3.3: version "4.3.4" resolved "https://registry.yarnpkg.com/debug/-/debug-4.3.4.tgz#1319f6579357f2338d3337d2cdd4914bb5dcc865" integrity sha512-PRWFHuSU3eDtQJPvnNY7Jcket1j0t5OuOsFzPPzsekD52Zl8qUfFIPEiswXqIvHWGVHOgX+7G/vCNNhehwxfkQ== dependencies: ms "2.1.2" -debug@^2.2.0: - version "2.6.9" - resolved "https://registry.yarnpkg.com/debug/-/debug-2.6.9.tgz#5d128515df134ff327e90a4c93f4e077a536341f" - integrity sha512-bC7ElrdJaJnPbAP+1EotYvqZsb3ecl5wi6Bfi6BJTUcNowp6cvspg0jXznRTKDjm/E7AdgFBVeAPVMNcKGsHMA== - dependencies: - ms "2.0.0" - -debug@^3.1.0: - version "3.2.7" - resolved "https://registry.yarnpkg.com/debug/-/debug-3.2.7.tgz#72580b7e9145fb39b6676f9c5e5fb100b934179a" - integrity sha512-CFjzYYAi4ThfiQvizrFQevTTXHtnCqWfe7x1AhgEscTz6ZbLbfoLRLPugTQyBth6f8ZERVUSyWHFD/7Wu4t1XQ== - dependencies: - ms "^2.1.1" - decamelize@^4.0.0: version "4.0.0" resolved "https://registry.yarnpkg.com/decamelize/-/decamelize-4.0.0.tgz#aa472d7bf660eb15f3494efd531cab7f2a709837" integrity sha512-9iE1PgSik9HeIIw2JO94IidnE3eBoQrFJ3w7sFuzSX4DpmZ3v5sZpUiV5Swcf6mQEF+Y0ru8Neo+p+nyh2J+hQ== -deep-eql@^4.1.3: - version "4.1.3" - resolved "https://registry.yarnpkg.com/deep-eql/-/deep-eql-4.1.3.tgz#7c7775513092f7df98d8df9996dd085eb668cc6d" - integrity sha512-WaEtAOpRA1MQ0eohqZjpGD8zdI0Ovsm8mmFhaDN8dvDZzyoUMcYDnf5Y6iu7HTXxf8JDS23qWa4a+hKCDyOPzw== +decompress-response@^6.0.0: + version "6.0.0" + resolved "https://registry.yarnpkg.com/decompress-response/-/decompress-response-6.0.0.tgz#ca387612ddb7e104bd16d85aab00d5ecf09c66fc" + integrity sha512-aW35yZM6Bb/4oJlZncMH2LCoZtJXTRxES17vE3hoRiowU2kWHaJKFkSBDnDR+cm9J+9QhXmREyIfv0pji9ejCQ== dependencies: - type-detect "^4.0.0" + mimic-response "^3.1.0" + +deep-eql@^5.0.1: + version "5.0.1" + resolved "https://registry.yarnpkg.com/deep-eql/-/deep-eql-5.0.1.tgz#21ea2c0d561a4d08cdd99c417ac584e0fb121385" + integrity sha512-nwQCf6ne2gez3o1MxWifqkciwt0zhl0LO1/UwVu4uMBuPmflWM4oQ70XMqHqnBJA+nhzncaqL9HVL6KkHJ28lw== -deep-extend@~0.6.0: +deep-extend@^0.6.0, deep-extend@~0.6.0: version "0.6.0" resolved "https://registry.yarnpkg.com/deep-extend/-/deep-extend-0.6.0.tgz#c4fa7c95404a17a9c3e8ca7e1537312b736330ac" integrity sha512-LOHxIOaPYdHlJRtCQfDIVZtfw/ufM8+rVj649RIHzcm/vGwQRXFt6OPqIFWsm2XEMrNIEtWR64sY1LEKD2vAOA== @@ -2538,13 +2166,10 @@ deep-is@^0.1.3, deep-is@~0.1.3: resolved "https://registry.yarnpkg.com/deep-is/-/deep-is-0.1.4.tgz#a6f2dce612fadd2ef1f519b73551f17e85199831" integrity sha512-oIPzksmTg4/MriiaYGO+okXDT7ztn/w3Eptv/+gSIdMdKsJo0u4CfYNFJPy+4SKMuCqGw2wxnA+URMg3t8a/bQ== -deferred-leveldown@~5.3.0: - version "5.3.0" - resolved "https://registry.yarnpkg.com/deferred-leveldown/-/deferred-leveldown-5.3.0.tgz#27a997ad95408b61161aa69bd489b86c71b78058" - integrity sha512-a59VOT+oDy7vtAbLRCZwWgxu2BaCfd5Hk7wxJd48ei7I+nsg8Orlb9CLG0PMZienk9BSUKgeAqkO2+Lw+1+Ukw== - dependencies: - abstract-leveldown "~6.2.1" - inherits "^2.0.3" +defer-to-connect@^2.0.1: + version "2.0.1" + resolved "https://registry.yarnpkg.com/defer-to-connect/-/defer-to-connect-2.0.1.tgz#8016bdb4143e4632b77a3449c6236277de520587" + integrity sha512-4tvttepXG1VaYGrRibk5EwJd1t4udunSOVMdLSAL6mId1ix438oPwPZMALY41FCijukO1L0twNcGsdzS7dHgDg== define-data-property@^1.0.1, define-data-property@^1.1.2: version "1.1.2" @@ -2619,22 +2244,14 @@ doctrine@^3.0.0: dependencies: esutils "^2.0.2" -dotenv@^16.0.3: +dotenv@^16.4.1: version "16.4.1" resolved "https://registry.yarnpkg.com/dotenv/-/dotenv-16.4.1.tgz#1d9931f1d3e5d2959350d1250efab299561f7f11" integrity sha512-CjA3y+Dr3FyFDOAMnxZEGtnW9KBR2M0JvvUtXNW+dYJL5ROWxP9DUHCwgFqpMk0OXCc0ljhaNTr2w/kutYIcHQ== -"ds-test@github:dapphub/ds-test": +"ds-test@https://github.com/dapphub/ds-test": version "1.0.0" - resolved "https://codeload.github.com/dapphub/ds-test/tar.gz/e282159d5170298eb2455a6c05280ab5a73a4ef0" - -ecc-jsbn@~0.1.1: - version "0.1.2" - resolved "https://registry.yarnpkg.com/ecc-jsbn/-/ecc-jsbn-0.1.2.tgz#3a83a904e54353287874c564b7549386849a98c9" - integrity sha512-eh9O+hwRHNbG4BLTjEl3nw044CkGm5X6LoaCf7LPp7UU8Qrt47JYNi6nPX8xjW97TKGKm1ouctg0QSpZe9qrnw== - dependencies: - jsbn "~0.1.0" - safer-buffer "^2.1.0" + resolved "https://github.com/dapphub/ds-test#e282159d5170298eb2455a6c05280ab5a73a4ef0" elliptic@6.5.4, elliptic@^6.5.2, elliptic@^6.5.4: version "6.5.4" @@ -2649,11 +2266,6 @@ elliptic@6.5.4, elliptic@^6.5.2, elliptic@^6.5.4: minimalistic-assert "^1.0.1" minimalistic-crypto-utils "^1.0.1" -emittery@0.10.0: - version "0.10.0" - resolved "https://registry.yarnpkg.com/emittery/-/emittery-0.10.0.tgz#bb373c660a9d421bb44706ec4967ed50c02a8026" - integrity sha512-AGvFfs+d0JKCJQ4o01ASQLGPmSCxgfU9RFXvzPvZdjKK8oscynksuJhWrSTSw7j7Ep/sZct5b5ZhYCi8S/t0HQ== - emoji-regex@^8.0.0: version "8.0.0" resolved "https://registry.yarnpkg.com/emoji-regex/-/emoji-regex-8.0.0.tgz#e818fd69ce5ccfcb404594f842963bf53164cc37" @@ -2664,16 +2276,6 @@ encode-utf8@^1.0.2: resolved "https://registry.yarnpkg.com/encode-utf8/-/encode-utf8-1.0.3.tgz#f30fdd31da07fb596f281beb2f6b027851994cda" integrity sha512-ucAnuBEhUK4boH2HjVYG5Q2mQyPorvv0u/ocS+zhdw0S8AlHYY+GOFhP1Gio5z4icpP2ivFSvhtFjQi8+T9ppw== -encoding-down@^6.3.0: - version "6.3.0" - resolved "https://registry.yarnpkg.com/encoding-down/-/encoding-down-6.3.0.tgz#b1c4eb0e1728c146ecaef8e32963c549e76d082b" - integrity sha512-QKrV0iKR6MZVJV08QY0wp1e7vF6QbhnbQhb07bwpEyuz4uZiZgPlEGdkCROuFkUwdxlFaiPIhjyarH1ee/3vhw== - dependencies: - abstract-leveldown "^6.2.1" - inherits "^2.0.3" - level-codec "^9.0.0" - level-errors "^2.0.0" - enquirer@^2.3.0, enquirer@^2.3.6: version "2.4.1" resolved "https://registry.yarnpkg.com/enquirer/-/enquirer-2.4.1.tgz#93334b3fbd74fc7097b224ab4a8fb7e40bf4ae56" @@ -2692,13 +2294,6 @@ erc6551@^0.3.1: resolved "https://registry.yarnpkg.com/erc6551/-/erc6551-0.3.1.tgz#f9ccc0901c210b0cc29c1c730398878319a1fd30" integrity sha512-4+O7CJ5gn3/s2Mum1QiJDJUbGE1P1m0t3do2nnFAKWEXLubWfZjS12HqraUJ6Y6su3WJ8EqdWm0270gC0bqpCA== -errno@~0.1.1: - version "0.1.8" - resolved "https://registry.yarnpkg.com/errno/-/errno-0.1.8.tgz#8bb3e9c7d463be4976ff888f76b4809ebc2e811f" - integrity sha512-dJ6oBr5SQ1VSd9qkk7ByRgb/1SH4JZjCHSW/mr63/QcXO9zLVxvJ6Oy13nio03rxpSnVDDjFor75SjVeZWPW/A== - dependencies: - prr "~1.0.1" - error-ex@^1.3.1: version "1.3.2" resolved "https://registry.yarnpkg.com/error-ex/-/error-ex-1.3.2.tgz#b4ac40648107fdcdcfae242f428bea8a14d4f1bf" @@ -2808,12 +2403,13 @@ escodegen@1.8.x: optionalDependencies: source-map "~0.2.0" -eslint-plugin-prettier@^4.2.1: - version "4.2.1" - resolved "https://registry.yarnpkg.com/eslint-plugin-prettier/-/eslint-plugin-prettier-4.2.1.tgz#651cbb88b1dab98bfd42f017a12fa6b2d993f94b" - integrity sha512-f/0rXLXUt0oFYs8ra4w49wYZBG5GKZpAYsJSm6rnYL5uVDjd+zowwMwVZHnAjf4edNrKpCDYfXDgmRE/Ak7QyQ== +eslint-plugin-prettier@^5.1.3: + version "5.1.3" + resolved "https://registry.yarnpkg.com/eslint-plugin-prettier/-/eslint-plugin-prettier-5.1.3.tgz#17cfade9e732cef32b5f5be53bd4e07afd8e67e1" + integrity sha512-C9GCVAs4Eq7ZC/XFQHITLiHJxQngdtraXaM+LoUFoFp/lHNl2Zn8f3WQbe9HvTBBQ9YnKFB0/2Ajdqwo5D1EAw== dependencies: prettier-linter-helpers "^1.0.0" + synckit "^0.8.6" eslint-scope@^7.2.2: version "7.2.2" @@ -2828,7 +2424,7 @@ eslint-visitor-keys@^3.3.0, eslint-visitor-keys@^3.4.1, eslint-visitor-keys@^3.4 resolved "https://registry.yarnpkg.com/eslint-visitor-keys/-/eslint-visitor-keys-3.4.3.tgz#0cd72fe8550e3c2eae156a96a4dddcd1c8ac5800" integrity sha512-wpc+LXeiyiisxPlEkUzU6svyS1frIO3Mgxj1fdy7Pm8Ygzguax2N3Fa/D/ag1WqbOprdI+uY6wMUl8/a2G+iag== -eslint@^8.38.0: +eslint@^8.56.0: version "8.56.0" resolved "https://registry.yarnpkg.com/eslint/-/eslint-8.56.0.tgz#4957ce8da409dc0809f99ab07a1b94832ab74b15" integrity sha512-Go19xM6T9puCOWntie1/P997aXxFsOi37JIHRWI514Hc6ZnaHGKY9xFhrU65RT6CcBEzZoGG1e6Nq+DT04ZtZQ== @@ -2987,19 +2583,7 @@ ethereum-cryptography@^2.0.0, ethereum-cryptography@^2.1.2: "@scure/bip32" "1.3.3" "@scure/bip39" "1.2.2" -ethereum-waffle@^4.0.10: - version "4.0.10" - resolved "https://registry.yarnpkg.com/ethereum-waffle/-/ethereum-waffle-4.0.10.tgz#f1ef1564c0155236f1a66c6eae362a5d67c9f64c" - integrity sha512-iw9z1otq7qNkGDNcMoeNeLIATF9yKl1M8AIeu42ElfNBplq0e+5PeasQmm8ybY/elkZ1XyRO0JBQxQdVRb8bqQ== - dependencies: - "@ethereum-waffle/chai" "4.0.10" - "@ethereum-waffle/compiler" "4.0.3" - "@ethereum-waffle/mock-contract" "4.0.4" - "@ethereum-waffle/provider" "4.0.5" - solc "0.8.15" - typechain "^8.0.0" - -ethereumjs-abi@0.6.8, ethereumjs-abi@^0.6.8: +ethereumjs-abi@^0.6.8: version "0.6.8" resolved "https://registry.yarnpkg.com/ethereumjs-abi/-/ethereumjs-abi-0.6.8.tgz#71bc152db099f70e62f108b7cdfca1b362c6fcae" integrity sha512-Tx0r/iXI6r+lRsdvkFDlut0N08jWMnKRZ6Gkq+Nmw75lZe4e6o3EkSnkaBP5NF6+m5PTGAr9JP43N3LyeoglsA== @@ -3007,17 +2591,6 @@ ethereumjs-abi@0.6.8, ethereumjs-abi@^0.6.8: bn.js "^4.11.8" ethereumjs-util "^6.0.0" -ethereumjs-util@7.1.3: - version "7.1.3" - resolved "https://registry.yarnpkg.com/ethereumjs-util/-/ethereumjs-util-7.1.3.tgz#b55d7b64dde3e3e45749e4c41288238edec32d23" - integrity sha512-y+82tEbyASO0K0X1/SRhbJJoAlfcvq8JbrG4a5cjrOks7HS/36efU/0j2flxCPOUM++HFahk33kr/ZxyC4vNuw== - dependencies: - "@types/bn.js" "^5.1.0" - bn.js "^5.1.2" - create-hash "^1.1.2" - ethereum-cryptography "^0.1.3" - rlp "^2.2.4" - ethereumjs-util@^6.0.0, ethereumjs-util@^6.2.1: version "6.2.1" resolved "https://registry.yarnpkg.com/ethereumjs-util/-/ethereumjs-util-6.2.1.tgz#fcb4e4dd5ceacb9d2305426ab1a5cd93e3163b69" @@ -3031,7 +2604,7 @@ ethereumjs-util@^6.0.0, ethereumjs-util@^6.2.1: ethjs-util "0.1.6" rlp "^2.2.3" -ethereumjs-util@^7.0.3, ethereumjs-util@^7.1.1, ethereumjs-util@^7.1.3, ethereumjs-util@^7.1.4, ethereumjs-util@^7.1.5: +ethereumjs-util@^7.0.3, ethereumjs-util@^7.1.5: version "7.1.5" resolved "https://registry.yarnpkg.com/ethereumjs-util/-/ethereumjs-util-7.1.5.tgz#9ecf04861e4fbbeed7465ece5f23317ad1129181" integrity sha512-SDl5kKrQAudFBUe5OJM9Ac6WmMyYmXX/6sTmLZ3ffG2eY6ZIGBes3pEDxNN6V72WyOw4CPD5RomKdsa8DAAwLg== @@ -3042,7 +2615,7 @@ ethereumjs-util@^7.0.3, ethereumjs-util@^7.1.1, ethereumjs-util@^7.1.3, ethereum ethereum-cryptography "^0.1.3" rlp "^2.2.4" -ethers@^5, ethers@^5.7.0, ethers@^5.7.1, ethers@^5.7.2: +ethers@^5.7.0, ethers@^5.7.1, ethers@^5.7.2: version "5.7.2" resolved "https://registry.yarnpkg.com/ethers/-/ethers-5.7.2.tgz#3a7deeabbb8c030d4126b24f84e525466145872e" integrity sha512-wswUsmWo1aOK8rR7DIKiWSw9DbLWe6x98Jrn8wcTflTVvaXhAMaB5zGAXy0GYQEQp9iO1iSHWVyARQm11zUtyg== @@ -3078,7 +2651,7 @@ ethers@^5, ethers@^5.7.0, ethers@^5.7.1, ethers@^5.7.2: "@ethersproject/web" "5.7.1" "@ethersproject/wordlists" "5.7.0" -ethers@^6.8.1: +ethers@^6, ethers@^6.8.1: version "6.10.0" resolved "https://registry.yarnpkg.com/ethers/-/ethers-6.10.0.tgz#20f3c63c60d59a993f8090ad423d8a3854b3b1cd" integrity sha512-nMNwYHzs6V1FR3Y4cdfxSQmNgZsRj1RiTU25JwvnJLmyzw9z3SKxNc2XKDuiXXo/v9ds5Mp9m6HBabgYQQ26tA== @@ -3115,21 +2688,6 @@ evp_bytestokey@^1.0.3: md5.js "^1.3.4" safe-buffer "^5.1.1" -extend@~3.0.2: - version "3.0.2" - resolved "https://registry.yarnpkg.com/extend/-/extend-3.0.2.tgz#f8b1136b4071fbd8eb140aff858b1019ec2915fa" - integrity sha512-fjquC59cD7CyW6urNXK0FBufkZcoiGG80wTuPujX590cB5Ttln20E2UB4S/WARVqhXffZl2LNgS+gQdPIIim/g== - -extsprintf@1.3.0: - version "1.3.0" - resolved "https://registry.yarnpkg.com/extsprintf/-/extsprintf-1.3.0.tgz#96918440e3041a7a414f8c52e3c574eb3c3e1e05" - integrity sha512-11Ndz7Nv+mvAC1j0ktTa7fAb0vLyGGX+rMHNBYQviQDGU0Hw7lhctJANqbPhu9nV9/izT/IntTgZ7Im/9LJs9g== - -extsprintf@^1.2.0: - version "1.4.1" - resolved "https://registry.yarnpkg.com/extsprintf/-/extsprintf-1.4.1.tgz#8d172c064867f235c0c84a596806d279bf4bcc07" - integrity sha512-Wrk35e8ydCKDj/ArClo1VrPVmN8zph5V4AtHwIuHhvMXsKf73UT3BOD+azBIW+3wOJ4FhEH7zyaJCFvChjYvMA== - fast-base64-decode@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/fast-base64-decode/-/fast-base64-decode-1.0.0.tgz#b434a0dd7d92b12b43f26819300d2dafb83ee418" @@ -3247,15 +2805,15 @@ for-each@^0.3.3: dependencies: is-callable "^1.1.3" -forever-agent@~0.6.1: - version "0.6.1" - resolved "https://registry.yarnpkg.com/forever-agent/-/forever-agent-0.6.1.tgz#fbc71f0c41adeb37f96c577ad1ed42d8fdacca91" - integrity sha512-j0KLYPhm6zeac4lz3oJ3o65qvgQCcPubiyotZrXqEaG4hNagNYO8qdlUrX5vwqv9ohqeT/Z3j6+yW067yWWdUw== - "forge-std@github:foundry-rs/forge-std#v1.7.6": version "1.7.6" resolved "https://codeload.github.com/foundry-rs/forge-std/tar.gz/ae570fec082bfe1c1f45b0acca4a2b4f84d345ce" +form-data-encoder@^2.1.2: + version "2.1.4" + resolved "https://registry.yarnpkg.com/form-data-encoder/-/form-data-encoder-2.1.4.tgz#261ea35d2a70d48d30ec7a9603130fa5515e9cd5" + integrity sha512-yDYSgNMraqvnxiEXO4hi88+YZxaHC6QKzb5N84iRCTDeRO7ZALpir/lVmf/uXUhnwUr2O4HU8s/n6x+yNjQkHw== + form-data@^2.2.0: version "2.5.1" resolved "https://registry.yarnpkg.com/form-data/-/form-data-2.5.1.tgz#f2cbec57b5e59e23716e128fe44d4e5dd23895f4" @@ -3274,15 +2832,6 @@ form-data@^4.0.0: combined-stream "^1.0.8" mime-types "^2.1.12" -form-data@~2.3.2: - version "2.3.3" - resolved "https://registry.yarnpkg.com/form-data/-/form-data-2.3.3.tgz#dcce52c05f644f298c6a7ab936bd724ceffbf3a6" - integrity sha512-1lLKB2Mu3aGP1Q/2eCOx0fNbRMe7XdwktwOruhfqqd0rIJWwN4Dh+E3hrPSlDCXnSR7UtZ1N38rVXm+6+MEhJQ== - dependencies: - asynckit "^0.4.0" - combined-stream "^1.0.6" - mime-types "^2.1.12" - fp-ts@1.19.3: version "1.19.3" resolved "https://registry.yarnpkg.com/fp-ts/-/fp-ts-1.19.3.tgz#261a60d1088fbff01f91256f91d21d0caaaaa96f" @@ -3371,7 +2920,7 @@ function.prototype.name@^1.1.6: es-abstract "^1.22.1" functions-have-names "^1.2.3" -functional-red-black-tree@^1.0.1, functional-red-black-tree@~1.0.1: +functional-red-black-tree@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/functional-red-black-tree/-/functional-red-black-tree-1.0.1.tgz#1b0ab3bd553b2a0d6399d29c0e3ea0b252078327" integrity sha512-dsKNQNdj6xA3T+QlADDA7mOSlX0qiMINjn0cgr+eGHGsbSHzTabcIogz2+p/iqP1Xs6EP/sS2SbqH+brGTbq0g== @@ -3381,29 +2930,12 @@ functions-have-names@^1.2.3: resolved "https://registry.yarnpkg.com/functions-have-names/-/functions-have-names-1.2.3.tgz#0404fe4ee2ba2f607f0e0ec3c80bae994133b834" integrity sha512-xckBUXyTIqT97tq2x2AMb+g163b5JFysYk0x4qxNFwbfQkmNZoiRHb6sPzI9/QV33WeuvVYBUIiD4NzNIyqaRQ== -ganache@7.4.3: - version "7.4.3" - resolved "https://registry.yarnpkg.com/ganache/-/ganache-7.4.3.tgz#e995f1250697264efbb34d4241c374a2b0271415" - integrity sha512-RpEDUiCkqbouyE7+NMXG26ynZ+7sGiODU84Kz+FVoXUnQ4qQM4M8wif3Y4qUCt+D/eM1RVeGq0my62FPD6Y1KA== - dependencies: - "@trufflesuite/bigint-buffer" "1.1.10" - "@types/bn.js" "^5.1.0" - "@types/lru-cache" "5.1.1" - "@types/seedrandom" "3.0.1" - emittery "0.10.0" - keccak "3.0.2" - leveldown "6.1.0" - secp256k1 "4.0.3" - optionalDependencies: - bufferutil "4.0.5" - utf-8-validate "5.0.7" - get-caller-file@^2.0.5: version "2.0.5" resolved "https://registry.yarnpkg.com/get-caller-file/-/get-caller-file-2.0.5.tgz#4f94412a82db32f36e3b0b9741f8a97feb031f7e" integrity sha512-DyFP3BM/3YHTQOCUL/w0OZHR0lpKeGrxotcHWcqNEdnltqFwXVfhEBQ94eIo34AfQpo0rGki4cyIiftY06h2Fg== -get-func-name@^2.0.1, get-func-name@^2.0.2: +get-func-name@^2.0.1: version "2.0.2" resolved "https://registry.yarnpkg.com/get-func-name/-/get-func-name-2.0.2.tgz#0d7cf20cd13fda808669ffa88f4ffc7a3943fc41" integrity sha512-8vXOvuE167CtIc3OyItco7N/dpRtBbYOsPsXCz7X/PMnlGjYjSGuZJgM1Y7mmew7BKf9BqvLX2tnOVy1BBUsxQ== @@ -3424,20 +2956,19 @@ get-port@^3.1.0: resolved "https://registry.yarnpkg.com/get-port/-/get-port-3.2.0.tgz#dd7ce7de187c06c8bf353796ac71e099f0980ebc" integrity sha512-x5UJKlgeUiNT8nyo/AcnwLnZuZNcSjSw0kogRB+Whd1fjjFq4B1hySFxSFWWSn4mIBzg3sRNUDFYc4g5gjPoLg== +get-stream@^6.0.1: + version "6.0.1" + resolved "https://registry.yarnpkg.com/get-stream/-/get-stream-6.0.1.tgz#a262d8eef67aced57c2852ad6167526a43cbf7b7" + integrity sha512-ts6Wi+2j3jQjqi70w5AlN8DFnkSwC+MqmxEzdEALB2qXZYV3X/b1CTfgPLGJNMeAWxdPfU8FO1ms3NUfaHCPYg== + get-symbol-description@^1.0.0: - version "1.0.1" - resolved "https://registry.yarnpkg.com/get-symbol-description/-/get-symbol-description-1.0.1.tgz#c0de911bfaa9ea8da52b5e702d2b3b51b8791ec4" - integrity sha512-KmuibvwbWaM4BHcBRYwJfZ1JxyJeBwB8ct9YYu67SvYdbEIlcQ2e56dHxfbobqW38GXo8/zDFqJeGtHiVbWyQw== + version "1.0.2" + resolved "https://registry.yarnpkg.com/get-symbol-description/-/get-symbol-description-1.0.2.tgz#533744d5aa20aca4e079c8e5daf7fd44202821f5" + integrity sha512-g0QYk1dZBxGwk+Ngc+ltRH2IBp2f7zBkBMBJZCDerh6EhlhSR6+9irMCuT/09zD6qkarHUSn529sK/yL4S27mg== dependencies: call-bind "^1.0.5" es-errors "^1.3.0" - -getpass@^0.1.1: - version "0.1.7" - resolved "https://registry.yarnpkg.com/getpass/-/getpass-0.1.7.tgz#5eff8e3e684d569ae4cb2b1282604e8ba62149fa" - integrity sha512-0fzj9JxOLfJ+XGLhR8ze3unN0KZCgZwiSSDz168VERjK8Wl8kVSdcu2kspd4s4wtAa1y/qrVRiAA0WclVsu0ng== - dependencies: - assert-plus "^1.0.0" + get-intrinsic "^1.2.4" ghost-testrpc@^0.0.2: version "0.0.2" @@ -3570,6 +3101,28 @@ gopd@^1.0.1: dependencies: get-intrinsic "^1.1.3" +got@^12.1.0: + version "12.6.1" + resolved "https://registry.yarnpkg.com/got/-/got-12.6.1.tgz#8869560d1383353204b5a9435f782df9c091f549" + integrity sha512-mThBblvlAF1d4O5oqyvN+ZxLAYwIJK7bpMxgYqPD9okW0C3qm5FFn7k811QrcuEBwaogR3ngOFoCfs6mRv7teQ== + dependencies: + "@sindresorhus/is" "^5.2.0" + "@szmarczak/http-timer" "^5.0.1" + cacheable-lookup "^7.0.0" + cacheable-request "^10.2.8" + decompress-response "^6.0.0" + form-data-encoder "^2.1.2" + get-stream "^6.0.1" + http2-wrapper "^2.1.10" + lowercase-keys "^3.0.0" + p-cancelable "^3.0.0" + responselike "^3.0.0" + +graceful-fs@4.2.10: + version "4.2.10" + resolved "https://registry.yarnpkg.com/graceful-fs/-/graceful-fs-4.2.10.tgz#147d3a006da4ca3ce14728c7aefc287c367d7a6c" + integrity sha512-9ByhssR2fPVsNZj478qUUbKfmL0+t5BDVyjShtyZZLiK7ZDAArFFfopyOTj0M05wE2tJPisA4iTnnXl2YoPvOA== + graceful-fs@^4.1.2, graceful-fs@^4.1.6, graceful-fs@^4.1.9, graceful-fs@^4.2.0, graceful-fs@^4.2.4: version "4.2.11" resolved "https://registry.yarnpkg.com/graceful-fs/-/graceful-fs-4.2.11.tgz#4183e4e8bf08bb6e05bbb2f7d2e0c8f712ca40e3" @@ -3592,19 +3145,6 @@ handlebars@^4.0.1: optionalDependencies: uglify-js "^3.1.4" -har-schema@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/har-schema/-/har-schema-2.0.0.tgz#a94c2224ebcac04782a0d9035521f24735b7ec92" - integrity sha512-Oqluz6zhGX8cyRaTQlFMPw80bSJVG2x/cFb8ZPhUILGgHka9SsokCCOQgpveePerqidZOrT14ipqfJb7ILcW5Q== - -har-validator@~5.1.3: - version "5.1.5" - resolved "https://registry.yarnpkg.com/har-validator/-/har-validator-5.1.5.tgz#1f0803b9f8cb20c0fa13822df1ecddb36bde1efd" - integrity sha512-nmT2T0lljbxdQZfspsno9hgrG3Uir6Ks5afism62poxqBM6sDnMEuPmzTq8XN0OEwqKLLdh1jQI3qyE66Nzb3w== - dependencies: - ajv "^6.12.3" - har-schema "^2.0.0" - hardhat-contract-sizer@^2.10.0: version "2.10.0" resolved "https://registry.yarnpkg.com/hardhat-contract-sizer/-/hardhat-contract-sizer-2.10.0.tgz#72646f43bfe50e9a5702c9720c9bc3e77d93a2c9" @@ -3649,7 +3189,7 @@ hardhat-deploy@^0.11.43, hardhat-deploy@^0.11.45: qs "^6.9.4" zksync-web3 "^0.14.3" -hardhat-gas-reporter@^1.0.9: +hardhat-gas-reporter@^1.0.10: version "1.0.10" resolved "https://registry.yarnpkg.com/hardhat-gas-reporter/-/hardhat-gas-reporter-1.0.10.tgz#ebe5bda5334b5def312747580cd923c2b09aef1b" integrity sha512-02N4+So/fZrzJ88ci54GqwVA3Zrf0C9duuTyGt0CFRIh/CdNwbnTgkXkRfojOMLBQ+6t+lBIkgbsOtqMvNwikA== @@ -3800,11 +3340,6 @@ hmac-drbg@^1.0.1: minimalistic-assert "^1.0.0" minimalistic-crypto-utils "^1.0.1" -hosted-git-info@^2.6.0: - version "2.8.9" - resolved "https://registry.yarnpkg.com/hosted-git-info/-/hosted-git-info-2.8.9.tgz#dffc0bf9a21c02209090f2aa69429e1414daf3f9" - integrity sha512-mxIDAb9Lsm6DoOJ7xH+5+X4y1LU/4Hi50L9C5sIswK3JzULS4bwk1FvjdBgvYR4bzT4tuUQiC15FE2f5HbLvYw== - http-basic@^8.1.1: version "8.1.3" resolved "https://registry.yarnpkg.com/http-basic/-/http-basic-8.1.3.tgz#a7cabee7526869b9b710136970805b1004261bbf" @@ -3815,6 +3350,11 @@ http-basic@^8.1.1: http-response-object "^3.0.1" parse-cache-control "^1.0.1" +http-cache-semantics@^4.1.1: + version "4.1.1" + resolved "https://registry.yarnpkg.com/http-cache-semantics/-/http-cache-semantics-4.1.1.tgz#abe02fcb2985460bf0323be664436ec3476a6d5a" + integrity sha512-er295DKPVsV82j5kw1Gjt+ADA/XYHsajl82cGNQG2eyoPkvgUhX+nDIyelzhIWbbsXP39EHcI6l5tYs2FYqYXQ== + http-errors@2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/http-errors/-/http-errors-2.0.0.tgz#b7774a1486ef73cf7667ac9ae0858c012c57b9d3" @@ -3833,14 +3373,13 @@ http-response-object@^3.0.1: dependencies: "@types/node" "^10.0.3" -http-signature@~1.2.0: - version "1.2.0" - resolved "https://registry.yarnpkg.com/http-signature/-/http-signature-1.2.0.tgz#9aecd925114772f3d95b65a60abb8f7c18fbace1" - integrity sha512-CAbnr6Rz4CYQkLYUtSNXxQPUH2gK8f3iWexVlsnMeD+GjlsQ0Xsy1cOX+mN3dtxYomRy21CiOzU8Uhw6OwncEQ== +http2-wrapper@^2.1.10: + version "2.2.1" + resolved "https://registry.yarnpkg.com/http2-wrapper/-/http2-wrapper-2.2.1.tgz#310968153dcdedb160d8b72114363ef5fce1f64a" + integrity sha512-V5nVw1PAOgfI3Lmeaj2Exmeg7fenjhRUgz1lPSezy1CuhPYbgQtbQj4jZfEAEMlaL+vupsvhjqCyjzob0yxsmQ== dependencies: - assert-plus "^1.0.0" - jsprim "^1.2.2" - sshpk "^1.7.0" + quick-lru "^5.1.1" + resolve-alpn "^1.2.0" https-proxy-agent@^5.0.0: version "5.0.1" @@ -3850,6 +3389,11 @@ https-proxy-agent@^5.0.0: agent-base "6" debug "4" +husky@^8.0.0: + version "8.0.3" + resolved "https://registry.yarnpkg.com/husky/-/husky-8.0.3.tgz#4936d7212e46d1dea28fef29bb3a108872cd9184" + integrity sha512-+dQSyqPh4x1hlO1swXBiNb2HzTDN1I2IGLQx1GrBuiqFJfoMrnZWwVmatvSiO+Iz8fBUnf+lekwNo4c2LlXItg== + iconv-lite@0.4.24: version "0.4.24" resolved "https://registry.yarnpkg.com/iconv-lite/-/iconv-lite-0.4.24.tgz#2022b4b25fbddc21d2f524974a474aafe733908b" @@ -3857,7 +3401,7 @@ iconv-lite@0.4.24: dependencies: safer-buffer ">= 2.1.2 < 3" -ieee754@^1.1.13, ieee754@^1.1.4, ieee754@^1.2.1: +ieee754@^1.1.4, ieee754@^1.2.1: version "1.2.1" resolved "https://registry.yarnpkg.com/ieee754/-/ieee754-1.2.1.tgz#8eb7a10a63fff25d15a57b001586d177d1b0d352" integrity sha512-dcyqhDvX1C46lXZcVqCpK+FtMRQVdIMN6/Df5js2zouUsqG7I6sFxitIC+7KYK29KdXOLHdu9zL4sFnoVQnqaA== @@ -3867,16 +3411,6 @@ ignore@^5.1.1, ignore@^5.2.0, ignore@^5.2.4: resolved "https://registry.yarnpkg.com/ignore/-/ignore-5.3.1.tgz#5073e554cd42c5b33b394375f538b8593e34d4ef" integrity sha512-5Fytz/IraMjqpwfd34ke28PTVMjZjJG2MPn5t7OE4eUCUNf8BAa7b5WUS9/Qvr6mwOQS7Mk6vdsMno5he+T8Xw== -immediate@^3.2.3: - version "3.3.0" - resolved "https://registry.yarnpkg.com/immediate/-/immediate-3.3.0.tgz#1aef225517836bcdf7f2a2de2600c79ff0269266" - integrity sha512-HR7EVodfFUdQCTIeySw+WDRFJlPcLOJbXfwwZ7Oom6tjsvZ3bOkCDJHehQC3nxJrv7+f9XecwazynjU8e4Vw3Q== - -immediate@~3.2.3: - version "3.2.3" - resolved "https://registry.yarnpkg.com/immediate/-/immediate-3.2.3.tgz#d140fa8f614659bd6541233097ddaac25cdd991c" - integrity sha512-RrGCXRm/fRVqMIhqXrGEX9rRADavPiDFSoMb/k64i9XMk8uH4r/Omi5Ctierj6XzNecwDbO4WuFbDD1zmpl3Tg== - immutable@^4.0.0-rc.12: version "4.3.5" resolved "https://registry.yarnpkg.com/immutable/-/immutable-4.3.5.tgz#f8b436e66d59f99760dc577f5c99a4fd2a5cc5a0" @@ -3913,12 +3447,12 @@ inflight@^1.0.4: once "^1.3.0" wrappy "1" -inherits@2, inherits@2.0.4, inherits@^2.0.1, inherits@^2.0.3, inherits@^2.0.4, inherits@~2.0.1, inherits@~2.0.3: +inherits@2, inherits@2.0.4, inherits@^2.0.1, inherits@^2.0.3, inherits@^2.0.4, inherits@~2.0.3: version "2.0.4" resolved "https://registry.yarnpkg.com/inherits/-/inherits-2.0.4.tgz#0fa2c64f932917c3433a0ded55363aae37416b7c" integrity sha512-k/vGaX4/Yla3WzyMCvTQOXYeIHvqOKtnqBduzTHpzpQZzAskKMhZ2K+EnBiSM9zGSoIFeMpXKxa4dYeZIQqewQ== -ini@^1.3.5: +ini@^1.3.4, ini@^1.3.5, ini@~1.3.0: version "1.3.8" resolved "https://registry.yarnpkg.com/ini/-/ini-1.3.8.tgz#a29da425b48806f34767a4efce397269af28432c" integrity sha512-JV/yugV2uzW5iMRSiZAyDtQd+nxtUnjeLt0acNdw98kKLrvuRVyB80tsREOE7yvGVgalhZ6RNXCmEHkUKBKxew== @@ -4098,21 +3632,11 @@ is-typed-array@^1.1.10, is-typed-array@^1.1.12, is-typed-array@^1.1.13, is-typed dependencies: which-typed-array "^1.1.14" -is-typedarray@~1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/is-typedarray/-/is-typedarray-1.0.0.tgz#e479c80858df0c1b11ddda6940f96011fcda4a9a" - integrity sha512-cyA56iCMHAh5CdzjJIa4aohJyeO1YbwLi3Jc35MmRU6poroFjIGZzUzupGiRPOjgHg9TLu43xbpwXk523fMxKA== - is-unicode-supported@^0.1.0: version "0.1.0" resolved "https://registry.yarnpkg.com/is-unicode-supported/-/is-unicode-supported-0.1.0.tgz#3f26c76a809593b52bfa2ecb5710ed2779b522a7" integrity sha512-knxG2q4UC3u8stRGyAVJCOdxFmv5DZiRcdlIaAQXAbSfJya+OhopNotLQrstBhququ4ZpuKbDc/8S6mgXgPFPw== -is-url@^1.2.4: - version "1.2.4" - resolved "https://registry.yarnpkg.com/is-url/-/is-url-1.2.4.tgz#04a4df46d28c4cff3d73d01ff06abeb318a1aa52" - integrity sha512-ITvGim8FhRiYe4IQ5uHSkj7pVaPDrCTkNd3yq3cV7iZAcJdHTUMPMEHcqSOy9xZ9qFenQCvi+2wjH9a1nXqHww== - is-weakref@^1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/is-weakref/-/is-weakref-1.0.2.tgz#9529f383a9338205e89765e0392efc2f100f06f2" @@ -4150,11 +3674,6 @@ isomorphic-unfetch@^3.0.0: node-fetch "^2.6.1" unfetch "^4.2.0" -isstream@~0.1.2: - version "0.1.2" - resolved "https://registry.yarnpkg.com/isstream/-/isstream-0.1.2.tgz#47e63f7af55afa6f92e1500e690eb8b8529c099a" - integrity sha512-Yljz7ffyPbrLpLngrMtZ7NduUgVvi6wG9RJ9IUcyCd59YQ911PBJphODUcbOVbqYfxe1wuYf/LJ8PauMRwsM/g== - js-cookie@^2.2.1: version "2.2.1" resolved "https://registry.yarnpkg.com/js-cookie/-/js-cookie-2.2.1.tgz#69e106dc5d5806894562902aa5baec3744e9b2b8" @@ -4190,18 +3709,6 @@ js-yaml@4.1.0, js-yaml@^4.1.0: dependencies: argparse "^2.0.1" -jsbn@~0.1.0: - version "0.1.1" - resolved "https://registry.yarnpkg.com/jsbn/-/jsbn-0.1.1.tgz#a5e654c2e5a2deb5f201d96cefbca80c0ef2f513" - integrity sha512-UVU9dibq2JcFWxQPA6KCqj5O42VOmAY3zQUfEKxU0KpTGXwNoCjkX1e13eHNvw/xPynt6pU0rZ1htjWTNTSXsg== - -json-bigint@^1.0.0: - version "1.0.0" - resolved "https://registry.yarnpkg.com/json-bigint/-/json-bigint-1.0.0.tgz#ae547823ac0cad8398667f8cd9ef4730f5b01ff1" - integrity sha512-SiPv/8VpZuWbvLSMtTDU8hEfrZWg/mH/nV/b4o0CYbSxu1UIQPLdwKOCIyLQX+VIPO5vrLX3i8qtqFyhdPSUSQ== - dependencies: - bignumber.js "^9.0.0" - json-buffer@3.0.1: version "3.0.1" resolved "https://registry.yarnpkg.com/json-buffer/-/json-buffer-3.0.1.tgz#9338802a30d3b6605fbe0613e094008ca8c05a13" @@ -4222,21 +3729,11 @@ json-schema-traverse@^1.0.0: resolved "https://registry.yarnpkg.com/json-schema-traverse/-/json-schema-traverse-1.0.0.tgz#ae7bcb3656ab77a73ba5c49bf654f38e6b6860e2" integrity sha512-NM8/P9n3XjXhIZn1lLhkFaACTOURQXjWhV4BA/RnOv8xvgqtqpAX9IO4mRQxSx1Rlo4tqzeqb0sOlruaOy3dug== -json-schema@0.4.0: - version "0.4.0" - resolved "https://registry.yarnpkg.com/json-schema/-/json-schema-0.4.0.tgz#f7de4cf6efab838ebaeb3236474cbba5a1930ab5" - integrity sha512-es94M3nTIfsEPisRafak+HDLfHXnKBhV3vU5eqPcS3flIWqcxJWgXHXiey3YrpaNsanY5ei1VoYEbOzijuq9BA== - json-stable-stringify-without-jsonify@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/json-stable-stringify-without-jsonify/-/json-stable-stringify-without-jsonify-1.0.1.tgz#9db7b59496ad3f3cfef30a75142d2d930ad72651" integrity sha512-Bdboy+l7tA3OGW6FjyFHWkP5LuByj1Tk33Ljyq0axyzdk9//JSi2u3fP1QSmd1KNwq6VOKYGlAu87CisVir6Pw== -json-stringify-safe@~5.0.1: - version "5.0.1" - resolved "https://registry.yarnpkg.com/json-stringify-safe/-/json-stringify-safe-5.0.1.tgz#1296a2d58fd45f19a0f6ce01d65701e2c735b6eb" - integrity sha512-ZClg6AaYvamvYEE82d3Iyd3vSSIjQ+odgjaTzRuO3s7toCdFKczob2i0zCh7JE8kWn17yvAWhUVxvqGwUalsRA== - jsonfile@^2.1.0: version "2.4.0" resolved "https://registry.yarnpkg.com/jsonfile/-/jsonfile-2.4.0.tgz#3736a2b428b87bbda0cc83b53fa3d633a35c2ae8" @@ -4265,33 +3762,6 @@ jsonschema@^1.2.4: resolved "https://registry.yarnpkg.com/jsonschema/-/jsonschema-1.4.1.tgz#cc4c3f0077fb4542982973d8a083b6b34f482dab" integrity sha512-S6cATIPVv1z0IlxdN+zUk5EPjkGCdnhN4wVSBlvoUO1tOLJootbo9CquNJmbIh4yikWHiUedhRYrNPn1arpEmQ== -jsprim@^1.2.2: - version "1.4.2" - resolved "https://registry.yarnpkg.com/jsprim/-/jsprim-1.4.2.tgz#712c65533a15c878ba59e9ed5f0e26d5b77c5feb" - integrity sha512-P2bSOMAc/ciLz6DzgjVlGJP9+BrJWu5UDGK70C2iweC5QBIeFf0ZXRvGjEj2uYgrY2MkAAhsSWHDWlFtEroZWw== - dependencies: - assert-plus "1.0.0" - extsprintf "1.3.0" - json-schema "0.4.0" - verror "1.10.0" - -keccak@3.0.1: - version "3.0.1" - resolved "https://registry.yarnpkg.com/keccak/-/keccak-3.0.1.tgz#ae30a0e94dbe43414f741375cff6d64c8bea0bff" - integrity sha512-epq90L9jlFWCW7+pQa6JOnKn2Xgl2mtI664seYR6MHskvI9agt7AnDqmAlp9TqU4/caMYbA08Hi5DMZAl5zdkA== - dependencies: - node-addon-api "^2.0.0" - node-gyp-build "^4.2.0" - -keccak@3.0.2: - version "3.0.2" - resolved "https://registry.yarnpkg.com/keccak/-/keccak-3.0.2.tgz#4c2c6e8c54e04f2670ee49fa734eb9da152206e0" - integrity sha512-PyKKjkH53wDMLGrvmRGSNWgmSxZOUqbnXwKL9tmgbFYA1iAYqW21kfR7mZXV0MlESiefxQQE9X9fTa3X+2MPDQ== - dependencies: - node-addon-api "^2.0.0" - node-gyp-build "^4.2.0" - readable-stream "^3.6.0" - keccak@^3.0.0, keccak@^3.0.2: version "3.0.4" resolved "https://registry.yarnpkg.com/keccak/-/keccak-3.0.4.tgz#edc09b89e633c0549da444432ecf062ffadee86d" @@ -4325,74 +3795,18 @@ kleur@^3.0.3: resolved "https://registry.yarnpkg.com/kleur/-/kleur-3.0.3.tgz#a79c9ecc86ee1ce3fa6206d1216c501f147fc07e" integrity sha512-eTIzlVOSUR+JxdDFepEYcBMtZ9Qqdef+rnzWdRZuMbOywu5tO2w2N7rqjoANZ5k9vywhL6Br1VRjUIgTQx4E8w== -level-codec@^9.0.0: - version "9.0.2" - resolved "https://registry.yarnpkg.com/level-codec/-/level-codec-9.0.2.tgz#fd60df8c64786a80d44e63423096ffead63d8cbc" - integrity sha512-UyIwNb1lJBChJnGfjmO0OR+ezh2iVu1Kas3nvBS/BzGnx79dv6g7unpKIDNPMhfdTEGoc7mC8uAu51XEtX+FHQ== - dependencies: - buffer "^5.6.0" - -level-concat-iterator@^3.0.0: - version "3.1.0" - resolved "https://registry.yarnpkg.com/level-concat-iterator/-/level-concat-iterator-3.1.0.tgz#5235b1f744bc34847ed65a50548aa88d22e881cf" - integrity sha512-BWRCMHBxbIqPxJ8vHOvKUsaO0v1sLYZtjN3K2iZJsRBYtp+ONsY6Jfi6hy9K3+zolgQRryhIn2NRZjZnWJ9NmQ== - dependencies: - catering "^2.1.0" - -level-concat-iterator@~2.0.0: - version "2.0.1" - resolved "https://registry.yarnpkg.com/level-concat-iterator/-/level-concat-iterator-2.0.1.tgz#1d1009cf108340252cb38c51f9727311193e6263" - integrity sha512-OTKKOqeav2QWcERMJR7IS9CUo1sHnke2C0gkSmcR7QuEtFNLLzHQAvnMw8ykvEcv0Qtkg0p7FOwP1v9e5Smdcw== - -level-errors@^2.0.0, level-errors@~2.0.0: - version "2.0.1" - resolved "https://registry.yarnpkg.com/level-errors/-/level-errors-2.0.1.tgz#2132a677bf4e679ce029f517c2f17432800c05c8" - integrity sha512-UVprBJXite4gPS+3VznfgDSU8PTRuVX0NXwoWW50KLxd2yw4Y1t2JUR5In1itQnudZqRMT9DlAM3Q//9NCjCFw== - dependencies: - errno "~0.1.1" - -level-iterator-stream@~4.0.0: - version "4.0.2" - resolved "https://registry.yarnpkg.com/level-iterator-stream/-/level-iterator-stream-4.0.2.tgz#7ceba69b713b0d7e22fcc0d1f128ccdc8a24f79c" - integrity sha512-ZSthfEqzGSOMWoUGhTXdX9jv26d32XJuHz/5YnuHZzH6wldfWMOVwI9TBtKcya4BKTyTt3XVA0A3cF3q5CY30Q== - dependencies: - inherits "^2.0.4" - readable-stream "^3.4.0" - xtend "^4.0.2" - -level-mem@^5.0.1: - version "5.0.1" - resolved "https://registry.yarnpkg.com/level-mem/-/level-mem-5.0.1.tgz#c345126b74f5b8aa376dc77d36813a177ef8251d" - integrity sha512-qd+qUJHXsGSFoHTziptAKXoLX87QjR7v2KMbqncDXPxQuCdsQlzmyX+gwrEHhlzn08vkf8TyipYyMmiC6Gobzg== - dependencies: - level-packager "^5.0.3" - memdown "^5.0.0" - -level-packager@^5.0.3: - version "5.1.1" - resolved "https://registry.yarnpkg.com/level-packager/-/level-packager-5.1.1.tgz#323ec842d6babe7336f70299c14df2e329c18939" - integrity sha512-HMwMaQPlTC1IlcwT3+swhqf/NUO+ZhXVz6TY1zZIIZlIR0YSn8GtAAWmIvKjNY16ZkEg/JcpAuQskxsXqC0yOQ== +latest-version@^7.0.0: + version "7.0.0" + resolved "https://registry.yarnpkg.com/latest-version/-/latest-version-7.0.0.tgz#843201591ea81a4d404932eeb61240fe04e9e5da" + integrity sha512-KvNT4XqAMzdcL6ka6Tl3i2lYeFDgXNCuIX+xNx6ZMVR1dFq+idXd9FLKNMOIx0t9mJ9/HudyX4oZWXZQ0UJHeg== dependencies: - encoding-down "^6.3.0" - levelup "^4.3.2" - -level-supports@^2.0.1: - version "2.1.0" - resolved "https://registry.yarnpkg.com/level-supports/-/level-supports-2.1.0.tgz#9af908d853597ecd592293b2fad124375be79c5f" - integrity sha512-E486g1NCjW5cF78KGPrMDRBYzPuueMZ6VBXHT6gC7A8UYWGiM14fGgp+s/L1oFfDWSPV/+SFkYCmZ0SiESkRKA== + package-json "^8.1.0" level-supports@^4.0.0: version "4.0.1" resolved "https://registry.yarnpkg.com/level-supports/-/level-supports-4.0.1.tgz#431546f9d81f10ff0fea0e74533a0e875c08c66a" integrity sha512-PbXpve8rKeNcZ9C1mUicC9auIYFyGpkV9/i6g76tLgANwWhtG2v7I4xNBUlkn3lE2/dZF3Pi0ygYGtLc4RXXdA== -level-supports@~1.0.0: - version "1.0.1" - resolved "https://registry.yarnpkg.com/level-supports/-/level-supports-1.0.1.tgz#2f530a596834c7301622521988e2c36bb77d122d" - integrity sha512-rXM7GYnW8gsl1vedTJIbzOrRv85c/2uCMpiiCzO2fndd06U/kUXEEU9evYn4zFggBOg36IsBW8LzqIpETwwQzg== - dependencies: - xtend "^4.0.2" - level-transcoder@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/level-transcoder/-/level-transcoder-1.0.1.tgz#f8cef5990c4f1283d4c86d949e73631b0bc8ba9c" @@ -4401,15 +3815,6 @@ level-transcoder@^1.0.1: buffer "^6.0.3" module-error "^1.0.1" -level-ws@^2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/level-ws/-/level-ws-2.0.0.tgz#207a07bcd0164a0ec5d62c304b4615c54436d339" - integrity sha512-1iv7VXx0G9ec1isqQZ7y5LmoZo/ewAsyDHNA8EFDW5hqH2Kqovm33nSFkSdnLLAK+I5FlT+lo5Cw9itGe+CpQA== - dependencies: - inherits "^2.0.3" - readable-stream "^3.1.0" - xtend "^4.0.1" - level@^8.0.0: version "8.0.1" resolved "https://registry.yarnpkg.com/level/-/level-8.0.1.tgz#737161db1bc317193aca4e7b6f436e7e1df64379" @@ -4419,26 +3824,6 @@ level@^8.0.0: browser-level "^1.0.1" classic-level "^1.2.0" -leveldown@6.1.0: - version "6.1.0" - resolved "https://registry.yarnpkg.com/leveldown/-/leveldown-6.1.0.tgz#7ab1297706f70c657d1a72b31b40323aa612b9ee" - integrity sha512-8C7oJDT44JXxh04aSSsfcMI8YiaGRhOFI9/pMEL7nWJLVsWajDPTRxsSHTM2WcTVY5nXM+SuRHzPPi0GbnDX+w== - dependencies: - abstract-leveldown "^7.2.0" - napi-macros "~2.0.0" - node-gyp-build "^4.3.0" - -levelup@^4.3.2: - version "4.4.0" - resolved "https://registry.yarnpkg.com/levelup/-/levelup-4.4.0.tgz#f89da3a228c38deb49c48f88a70fb71f01cafed6" - integrity sha512-94++VFO3qN95cM/d6eBXvd894oJE0w3cInq9USsyQzzoJxmiYzPAocNcuGCPGGjoXqDVJcr3C1jzt1TSjyaiLQ== - dependencies: - deferred-leveldown "~5.3.0" - level-errors "~2.0.0" - level-iterator-stream "~4.0.0" - level-supports "~1.0.0" - xtend "~4.0.0" - levn@^0.4.1: version "0.4.1" resolved "https://registry.yarnpkg.com/levn/-/levn-0.4.1.tgz#ae4562c007473b932a6200d403268dd2fffc6ade" @@ -4513,13 +3898,18 @@ log-symbols@4.1.0: chalk "^4.1.0" is-unicode-supported "^0.1.0" -loupe@^2.3.6: - version "2.3.7" - resolved "https://registry.yarnpkg.com/loupe/-/loupe-2.3.7.tgz#6e69b7d4db7d3ab436328013d37d1c8c3540c697" - integrity sha512-zSMINGVYkdpYSOBmLi0D1Uo7JU9nVdQKrHxC8eYlV+9YKK9WePqAlL7lSlorG/U2Fw1w0hTBmaa/jrQ3UbPHtA== +loupe@^3.1.0: + version "3.1.0" + resolved "https://registry.yarnpkg.com/loupe/-/loupe-3.1.0.tgz#46ef1a4ffee73145f5c0a627536d754787c1ea2a" + integrity sha512-qKl+FrLXUhFuHUoDJG7f8P8gEMHq9NFS0c6ghXG1J0rldmZFQZoNVv/vyirE9qwCIhWZDsvEFd1sbFu3GvRQFg== dependencies: get-func-name "^2.0.1" +lowercase-keys@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/lowercase-keys/-/lowercase-keys-3.0.0.tgz#c5e7d442e37ead247ae9db117a9d0a467c89d4f2" + integrity sha512-ozCC6gdQ+glXOQsveKD0YsDy8DSQFjDTz4zyzEHNV5+JP5D62LmfDZ6o1cycFx9ouG940M5dE8C8CTewdj2YWQ== + lru-cache@^5.1.1: version "5.1.1" resolved "https://registry.yarnpkg.com/lru-cache/-/lru-cache-5.1.1.tgz#1da27e6710271947695daf6848e847f01d84b920" @@ -4539,11 +3929,6 @@ lru_map@^0.3.3: resolved "https://registry.yarnpkg.com/lru_map/-/lru_map-0.3.3.tgz#b5c8351b9464cbd750335a79650a0ec0e56118dd" integrity sha512-Pn9cox5CsMYngeDbmChANltQl+5pi6XmTrraMSzhPmMBbmgcxmqWry0U3PGapCU1yB4/LqCcom7qhHZiF/jGfQ== -ltgt@~2.2.0: - version "2.2.1" - resolved "https://registry.yarnpkg.com/ltgt/-/ltgt-2.2.1.tgz#f35ca91c493f7b73da0e07495304f17b31f87ee5" - integrity sha512-AI2r85+4MquTw9ZYqabu4nMwy9Oftlfa/e/52t9IjtfG+mGBbTNdAoZ3RQKLHR6r0wQnwZnPIEh/Ya6XTWAKNA== - make-error@^1.1.1: version "1.3.6" resolved "https://registry.yarnpkg.com/make-error/-/make-error-1.3.6.tgz#2eb2e37ea9b67c4891f684a1394799af484cf7a2" @@ -4573,18 +3958,6 @@ md5.js@^1.3.4: inherits "^2.0.1" safe-buffer "^5.1.2" -memdown@^5.0.0: - version "5.1.0" - resolved "https://registry.yarnpkg.com/memdown/-/memdown-5.1.0.tgz#608e91a9f10f37f5b5fe767667a8674129a833cb" - integrity sha512-B3J+UizMRAlEArDjWHTMmadet+UKwHd3UjMgGBkZcKAxAYVPS9o0Yeiha4qvz7iGiL2Sb3igUft6p7nbFWctpw== - dependencies: - abstract-leveldown "~6.2.1" - functional-red-black-tree "~1.0.1" - immediate "~3.2.3" - inherits "~2.0.1" - ltgt "~2.2.0" - safe-buffer "~5.2.0" - memory-level@^1.0.0: version "1.0.0" resolved "https://registry.yarnpkg.com/memory-level/-/memory-level-1.0.0.tgz#7323c3fd368f9af2f71c3cd76ba403a17ac41692" @@ -4604,18 +3977,6 @@ merge2@^1.2.3, merge2@^1.3.0: resolved "https://registry.yarnpkg.com/merge2/-/merge2-1.4.1.tgz#4368892f885e907455a6fd7dc55c0c9d404990ae" integrity sha512-8q7VEgMJW4J8tcfVPy8g09NcQwZdbwFEqhe/WZkoIzjn/3TGDwtOCYtXGxA3O8tPzpczCCDgv+P2P5y00ZJOOg== -merkle-patricia-tree@^4.2.2, merkle-patricia-tree@^4.2.4: - version "4.2.4" - resolved "https://registry.yarnpkg.com/merkle-patricia-tree/-/merkle-patricia-tree-4.2.4.tgz#ff988d045e2bf3dfa2239f7fabe2d59618d57413" - integrity sha512-eHbf/BG6eGNsqqfbLED9rIqbsF4+sykEaBn6OLNs71tjclbMcMOk1tEPmJKcNcNCLkvbpY/lwyOlizWsqPNo8w== - dependencies: - "@types/levelup" "^4.3.0" - ethereumjs-util "^7.1.4" - level-mem "^5.0.1" - level-ws "^2.0.0" - readable-stream "^3.6.0" - semaphore-async-await "^1.5.1" - micro-ftch@^0.3.1: version "0.3.1" resolved "https://registry.yarnpkg.com/micro-ftch/-/micro-ftch-0.3.1.tgz#6cb83388de4c1f279a034fb0cf96dfc050853c5f" @@ -4629,26 +3990,28 @@ micromatch@^4.0.4: braces "^3.0.2" picomatch "^2.3.1" -miller-rabin@^4.0.0: - version "4.0.1" - resolved "https://registry.yarnpkg.com/miller-rabin/-/miller-rabin-4.0.1.tgz#f080351c865b0dc562a8462966daa53543c78a4d" - integrity sha512-115fLhvZVqWwHPbClyntxEVfVDfl9DLLTuJvq3g2O/Oxi8AiNouAHvDSzHS0viUJc+V5vm3eq91Xwqn9dp4jRA== - dependencies: - bn.js "^4.0.0" - brorand "^1.0.1" - mime-db@1.52.0: version "1.52.0" resolved "https://registry.yarnpkg.com/mime-db/-/mime-db-1.52.0.tgz#bbabcdc02859f4987301c856e3387ce5ec43bf70" integrity sha512-sPU4uV7dYlvtWJxwwxHD0PuihVNiE7TyAbQ5SWxDCB9mUYvOgroQOwYQQOKPJ8CIbE+1ETVlOoK1UC2nU3gYvg== -mime-types@^2.1.12, mime-types@~2.1.19: +mime-types@^2.1.12: version "2.1.35" resolved "https://registry.yarnpkg.com/mime-types/-/mime-types-2.1.35.tgz#381a871b62a734450660ae3deee44813f70d959a" integrity sha512-ZDY+bPm5zTTF+YpCrAU9nK0UgICYPT0QtT1NZWFv4s++TNkcgVaT0g6+4R2uI4MjQjzysHB1zxuWL50hzaeXiw== dependencies: mime-db "1.52.0" +mimic-response@^3.1.0: + version "3.1.0" + resolved "https://registry.yarnpkg.com/mimic-response/-/mimic-response-3.1.0.tgz#2d1d59af9c1b129815accc2c46a022a5ce1fa3c9" + integrity sha512-z0yWI+4FDrrweS8Zmt4Ej5HdJmky15+L2e6Wgn3+iK5fWzb6T3fhNFq2+MeTRb064c6Wr4N/wv0DzQTjNzHNGQ== + +mimic-response@^4.0.0: + version "4.0.0" + resolved "https://registry.yarnpkg.com/mimic-response/-/mimic-response-4.0.0.tgz#35468b19e7c75d10f5165ea25e75a5ceea7cf70f" + integrity sha512-e5ISH9xMYU0DzrT+jl8q2ze9D6eWBto+I8CNpe+VI+K2J/F/k3PdkdTdz4wvGVH4NTpo+NRYTVIuMQEMMcsLqg== + minimalistic-assert@^1.0.0, minimalistic-assert@^1.0.1: version "1.0.1" resolved "https://registry.yarnpkg.com/minimalistic-assert/-/minimalistic-assert-1.0.1.tgz#2e194de044626d4a10e7f7fbc00ce73e83e4d5c7" @@ -4680,12 +4043,19 @@ minimatch@^5.0.1: dependencies: brace-expansion "^2.0.1" -minimist@^1.2.5, minimist@^1.2.6, minimist@^1.2.7: +minimatch@^9.0.3: + version "9.0.3" + resolved "https://registry.yarnpkg.com/minimatch/-/minimatch-9.0.3.tgz#a6e00c3de44c3a542bfaae70abfc22420a6da825" + integrity sha512-RHiac9mvaRw0x3AYRgDC1CxAP7HTcNrrECeA8YYJeWnpo+2Q5CegtZjaotWTWxDG3UeGA1coE05iH1mPjT/2mg== + dependencies: + brace-expansion "^2.0.1" + +minimist@^1.2.0, minimist@^1.2.5, minimist@^1.2.6, minimist@^1.2.7: version "1.2.8" resolved "https://registry.yarnpkg.com/minimist/-/minimist-1.2.8.tgz#c1a464e7693302e082a075cee0c057741ac4772c" integrity sha512-2yyAR8qBkN3YuheJanUpWC5U3bb5osDywNB8RzDVlDwDHbocAJveqqj1u8+SVD7jkWT4yvsHCpWqqWqAxb0zCA== -mkdirp@0.5.x, mkdirp@^0.5.1: +mkdirp@0.5.x: version "0.5.6" resolved "https://registry.yarnpkg.com/mkdirp/-/mkdirp-0.5.6.tgz#7def03d2432dcae4ba1d611445c48396062255f6" integrity sha512-FP+p8RB8OWpF3YZBCrP5gtADmtXApB5AMLn+vdyA+PyxCjrCs00mjyUozssO33cwDeT3wNGdLxJ5M//YqtHAJw== @@ -4736,17 +4106,12 @@ module-error@^1.0.1, module-error@^1.0.2: resolved "https://registry.yarnpkg.com/module-error/-/module-error-1.0.2.tgz#8d1a48897ca883f47a45816d4fb3e3c6ba404d86" integrity sha512-0yuvsqSCv8LbaOKhnsQ/T5JhyFlCYLPXK3U2sgV10zoKQwzs/MyfuQUOZQ1V/6OCOJsK/TRgNVrPuPDqtdMFtA== -ms@2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/ms/-/ms-2.0.0.tgz#5608aeadfc00be6c2901df5f9861788de0d597c8" - integrity sha512-Tpp60P6IUJDTuOq/5Z8cdskzJujfwqfOTkrwIwj7IRISpnkJnT6SyJ4PCPnGMoFjC9ddhal5KVIYtAt97ix05A== - ms@2.1.2: version "2.1.2" resolved "https://registry.yarnpkg.com/ms/-/ms-2.1.2.tgz#d09d1f357b443f493382a8eb3ccd183872ae6009" integrity sha512-sGkPx+VjMtmA6MX27oA4FBFELFCZZ4S4XqeGOXCv68tT+jb3vk/RyaKWP0PTKyWtmLSM0b+adUTEvbs1PEaH2w== -ms@2.1.3, ms@^2.1.1: +ms@2.1.3: version "2.1.3" resolved "https://registry.yarnpkg.com/ms/-/ms-2.1.3.tgz#574c8138ce1d2b5861f0b44579dbadd60c6615b2" integrity sha512-6FlzubTLZG3J2a/NVCAleEhjzq5oxgHyaCU9yYXvcLsvoVaHJq/s5xXI6/XXP6tz7R9xAOtHnSO/tXtF3WRTlA== @@ -4770,11 +4135,6 @@ napi-macros@^2.2.2: resolved "https://registry.yarnpkg.com/napi-macros/-/napi-macros-2.2.2.tgz#817fef20c3e0e40a963fbf7b37d1600bd0201044" integrity sha512-hmEVtAGYzVQpCKdbQea4skABsdXW4RUh5t5mJ2zzqowJS2OyXZTU1KhDVFhx+NlWZ4ap9mqR9TcDO3LTTttd+g== -napi-macros@~2.0.0: - version "2.0.0" - resolved "https://registry.yarnpkg.com/napi-macros/-/napi-macros-2.0.0.tgz#2b6bae421e7b96eb687aa6c77a7858640670001b" - integrity sha512-A0xLykHtARfueITVDernsAWdtIMbOJgKgcluwENp3AlsKN/PloyO10HtmoqnFAQAcxPkgZN7wdfPfEd0zNGxbg== - natural-compare@^1.4.0: version "1.4.0" resolved "https://registry.yarnpkg.com/natural-compare/-/natural-compare-1.4.0.tgz#4abebfeed7541f2c27acfb29bdbbd15c8d5ba4f7" @@ -4797,23 +4157,13 @@ node-emoji@^1.10.0: dependencies: lodash "^4.17.21" -node-fetch@^2.6.0, node-fetch@^2.6.1, node-fetch@^2.6.7: +node-fetch@^2.6.0, node-fetch@^2.6.1: version "2.7.0" resolved "https://registry.yarnpkg.com/node-fetch/-/node-fetch-2.7.0.tgz#d0f0fa6e3e2dc1d27efcd8ad99d550bda94d187d" integrity sha512-c4FRfUm/dbcWZ7U+1Wq0AwCyFL+3nt2bEw05wfxSz+DWpWsitgmSgYmy2dQdWyKC1694ELPqMs/YzUSNozLt8A== dependencies: whatwg-url "^5.0.0" -node-gyp-build@4.3.0: - version "4.3.0" - resolved "https://registry.yarnpkg.com/node-gyp-build/-/node-gyp-build-4.3.0.tgz#9f256b03e5826150be39c764bf51e993946d71a3" - integrity sha512-iWjXZvmboq0ja1pUGULQBexmxq8CV4xBhX7VDOTbL7ZR4FOowwY/VOtRxBN/yKxmdGoIp4j5ysNT4u3S2pDQ3Q== - -node-gyp-build@4.4.0: - version "4.4.0" - resolved "https://registry.yarnpkg.com/node-gyp-build/-/node-gyp-build-4.4.0.tgz#42e99687ce87ddeaf3a10b99dc06abc11021f3f4" - integrity sha512-amJnQCcgtRVw9SvoebO3BKGESClrfXGCUTX9hSn1OuGQTQBOZmVd0Z0OlecpuRksKvbsUqALE8jls/ErClAPuQ== - node-gyp-build@^4.2.0, node-gyp-build@^4.3.0: version "4.8.0" resolved "https://registry.yarnpkg.com/node-gyp-build/-/node-gyp-build-4.8.0.tgz#3fee9c1731df4581a3f9ead74664369ff00d26dd" @@ -4836,6 +4186,11 @@ normalize-path@^3.0.0, normalize-path@~3.0.0: resolved "https://registry.yarnpkg.com/normalize-path/-/normalize-path-3.0.0.tgz#0dcd69ff23a1c9b11fd0978316644a0388216a65" integrity sha512-6eZs5Ls3WtCisHWp9S2GUy8dqkpGi4BVSz3GaqiE6ezub0512ESztXUwUB6C6IKbQkY2Pnb/mD4WYojCRwcwLA== +normalize-url@^8.0.0: + version "8.0.0" + resolved "https://registry.yarnpkg.com/normalize-url/-/normalize-url-8.0.0.tgz#593dbd284f743e8dcf6a5ddf8fadff149c82701a" + integrity sha512-uVFpKhj5MheNBJRTiMZ9pE/7hD1QTeEvugSJW/OmLzAp78PB5O6adfMNTvmfKhXBkvCzC+rqifWcVYpGFwTjnw== + number-to-bn@1.7.0: version "1.7.0" resolved "https://registry.yarnpkg.com/number-to-bn/-/number-to-bn-1.7.0.tgz#bb3623592f7e5f9e0030b1977bd41a0c53fe1ea0" @@ -4844,11 +4199,6 @@ number-to-bn@1.7.0: bn.js "4.11.6" strip-hex-prefix "1.0.0" -oauth-sign@~0.9.0: - version "0.9.0" - resolved "https://registry.yarnpkg.com/oauth-sign/-/oauth-sign-0.9.0.tgz#47a7b016baa68b5fa0ecf3dee08a85c679ac6455" - integrity sha512-fexhUFFPTGV8ybAtSIGbV6gOkSv8UtRbDBnAyLQw4QPKkgNlsH2ByPGtMUqdWkos6YCRmAqViwgZrJc/mRDzZQ== - object-assign@^4.1.0: version "4.1.1" resolved "https://registry.yarnpkg.com/object-assign/-/object-assign-4.1.1.tgz#2109adc7965887cfc05cbbd442cac8bfbb360863" @@ -4924,6 +4274,11 @@ os-tmpdir@~1.0.2: resolved "https://registry.yarnpkg.com/os-tmpdir/-/os-tmpdir-1.0.2.tgz#bbe67406c79aa85c5cfec766fe5734555dfa1274" integrity sha512-D2FR03Vir7FIu45XBY20mTb+/ZSWB00sjU9jdQXt83gDrI4Ztz5Fs7/yy74g2N5SVQY4xY1qDr4rNddwYRVX0g== +p-cancelable@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/p-cancelable/-/p-cancelable-3.0.0.tgz#63826694b54d61ca1c20ebcb6d3ecf5e14cd8050" + integrity sha512-mlVgR3PGuzlo0MmTdk4cXqXWlwQDLnONTAg6sm62XkMJEiRxN3GL3SffkYvqwonbkJBcrI7Uvv5Zh9yjvn2iUw== + p-limit@^1.1.0: version "1.3.0" resolved "https://registry.yarnpkg.com/p-limit/-/p-limit-1.3.0.tgz#b86bd5f0c25690911c7590fcbfc2010d54b3ccb8" @@ -4964,6 +4319,16 @@ p-try@^1.0.0: resolved "https://registry.yarnpkg.com/p-try/-/p-try-1.0.0.tgz#cbc79cdbaf8fd4228e13f621f2b1a237c1b207b3" integrity sha512-U1etNYuMJoIz3ZXSrrySFjsXQTWOx2/jdi86L+2pRvph/qMKL6sbcCYdH23fqsbm8TH2Gn0OybpT4eSFlCVHww== +package-json@^8.1.0: + version "8.1.1" + resolved "https://registry.yarnpkg.com/package-json/-/package-json-8.1.1.tgz#3e9948e43df40d1e8e78a85485f1070bf8f03dc8" + integrity sha512-cbH9IAIJHNj9uXi196JVsRlt7cHKak6u/e6AkL/bkRelZ7rlL3X1YKxsZwa36xipOEKAsdtmaG6aAJoM1fx2zA== + dependencies: + got "^12.1.0" + registry-auth-token "^5.0.1" + registry-url "^6.0.0" + semver "^7.3.7" + parent-module@^1.0.0: version "1.0.1" resolved "https://registry.yarnpkg.com/parent-module/-/parent-module-1.0.1.tgz#691d2709e78c79fae3a156622452d00762caaaa2" @@ -4986,11 +4351,6 @@ parse-json@^5.2.0: json-parse-even-better-errors "^2.3.0" lines-and-columns "^1.1.6" -path-browserify@^1.0.0: - version "1.0.1" - resolved "https://registry.yarnpkg.com/path-browserify/-/path-browserify-1.0.1.tgz#d98454a9c3753d5790860f16f68867b9e46be1fd" - integrity sha512-b7uo2UCUOYZcnF/3ID0lulOJi/bafxa1xPe7ZPsammBSpjSWQkjNxlt635YGS2MiR9GjvuXCtz2emr3jbsz98g== - path-exists@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/path-exists/-/path-exists-3.0.0.tgz#ce0ebeaa5f78cb18925ea7d810d7b59b010fd515" @@ -5021,12 +4381,12 @@ path-type@^4.0.0: resolved "https://registry.yarnpkg.com/path-type/-/path-type-4.0.0.tgz#84ed01c0a7ba380afe09d90a8c180dcd9d03043b" integrity sha512-gDKb8aZMDeD/tZWs9P6+q0J9Mwkdl6xMV8TjnGP3qJVJ06bdMgkbBlLU8IdfOsIsFz2BW1rNVT3XuNEl8zPAvw== -pathval@^1.1.1: - version "1.1.1" - resolved "https://registry.yarnpkg.com/pathval/-/pathval-1.1.1.tgz#8534e77a77ce7ac5a2512ea21e0fdb8fcf6c3d8d" - integrity sha512-Dp6zGqpTdETdR63lehJYPeIOqpiNBNtc7BpWSLrOje7UaIsE5aY92r/AunQA7rsXvet3lrJ3JnZX29UPTKXyKQ== +pathval@^2.0.0: + version "2.0.0" + resolved "https://registry.yarnpkg.com/pathval/-/pathval-2.0.0.tgz#7e2550b422601d4f6b8e26f1301bc8f15a741a25" + integrity sha512-vE7JKRyES09KiunauX7nd2Q9/L7lhok4smP9RZTDeD4MVs72Dp2qNFVz39Nz5a0FVEW0BJR6C0DYrq6unoziZA== -pbkdf2@^3.0.17, pbkdf2@^3.0.9: +pbkdf2@^3.0.17: version "3.1.2" resolved "https://registry.yarnpkg.com/pbkdf2/-/pbkdf2-3.1.2.tgz#dd822aa0887580e52f1a039dc3eda108efae3075" integrity sha512-iuh7L6jA7JEGu2WxDwtQP1ddOpaJNC4KlDEFfdQajSGgGPNi4OyDc2R7QnbY2bR9QjBVGwgvTdNJZoE7RaxUMA== @@ -5037,11 +4397,6 @@ pbkdf2@^3.0.17, pbkdf2@^3.0.9: safe-buffer "^5.0.1" sha.js "^2.4.8" -performance-now@^2.1.0: - version "2.1.0" - resolved "https://registry.yarnpkg.com/performance-now/-/performance-now-2.1.0.tgz#6309f4e0e5fa913ec1c69307ae364b4b377c9e7b" - integrity sha512-7EAHlyLHI56VEIdK57uwHdHKIaAGbnXPiw0yWbarQZOKaKpvUIgW0jWRVLiatnM+XXlSwsanIBH/hzGMJulMow== - picomatch@^2.0.4, picomatch@^2.2.1, picomatch@^2.3.1: version "2.3.1" resolved "https://registry.yarnpkg.com/picomatch/-/picomatch-2.3.1.tgz#3ba3833733646d9d3e4995946c1365a67fb07a42" @@ -5074,7 +4429,7 @@ prettier-linter-helpers@^1.0.0: dependencies: fast-diff "^1.1.2" -prettier-plugin-solidity@^1.1.3: +prettier-plugin-solidity@^1.1.0: version "1.3.1" resolved "https://registry.yarnpkg.com/prettier-plugin-solidity/-/prettier-plugin-solidity-1.3.1.tgz#59944d3155b249f7f234dee29f433524b9a4abcf" integrity sha512-MN4OP5I2gHAzHZG1wcuJl0FsLS3c4Cc5494bbg+6oQWBPuEamjwDvmGfFMZ6NFzsh3Efd9UUxeT7ImgjNH4ozA== @@ -5083,16 +4438,16 @@ prettier-plugin-solidity@^1.1.3: semver "^7.5.4" solidity-comments-extractor "^0.0.8" -prettier@2.8.7: - version "2.8.7" - resolved "https://registry.yarnpkg.com/prettier/-/prettier-2.8.7.tgz#bb79fc8729308549d28fe3a98fce73d2c0656450" - integrity sha512-yPngTo3aXUUmyuTjeTUT75txrf+aMh9FiD7q9ZE/i6r0bPb22g4FsE6Y338PQX1bmfy08i9QQCB7/rcUAVntfw== - prettier@^2.3.1, prettier@^2.8.3: version "2.8.8" resolved "https://registry.yarnpkg.com/prettier/-/prettier-2.8.8.tgz#e8c5d7e98a4305ffe3de2e1fc4aca1a71c28b1da" integrity sha512-tdN8qQGvNjw4CHbY+XXk0JgCXn9QiF21a55rBe5LJAU+kDyC4WQn4+awm2Xfk2lQMk5fKup9XgzTZtGkjBdP9Q== +prettier@^3.0.0: + version "3.2.5" + resolved "https://registry.yarnpkg.com/prettier/-/prettier-3.2.5.tgz#e52bc3090586e824964a8813b09aba6233b28368" + integrity sha512-3/GWa9aOC0YeD7LUfvOG2NiDyhOWRvt1k+rcKhOuYnMY24iiCphgneUfJDyFXd6rZCAnuLBv6UeAULtrhT/F4A== + process-nextick-args@~2.0.0: version "2.0.1" resolved "https://registry.yarnpkg.com/process-nextick-args/-/process-nextick-args-2.0.1.tgz#7820d9b16120cc55ca9ae7792680ae7dba6d7fe2" @@ -5122,49 +4477,39 @@ proper-lockfile@^4.1.1: retry "^0.12.0" signal-exit "^3.0.2" +proto-list@~1.2.1: + version "1.2.4" + resolved "https://registry.yarnpkg.com/proto-list/-/proto-list-1.2.4.tgz#212d5bfe1318306a420f6402b8e26ff39647a849" + integrity sha512-vtK/94akxsTMhe0/cbfpR+syPuszcuwhqVjJq26CuNDgFGj682oRBXOP5MJpv2r7JtE8MsiepGIqvvOTBwn2vA== + proxy-from-env@^1.1.0: version "1.1.0" resolved "https://registry.yarnpkg.com/proxy-from-env/-/proxy-from-env-1.1.0.tgz#e102f16ca355424865755d2c9e8ea4f24d58c3e2" integrity sha512-D+zkORCbA9f1tdWRK0RaCR3GPv50cMxcrz4X8k5LTSUD1Dkw47mKJEZQNunItRTkWwgtaUSo1RVFRIG9ZXiFYg== -prr@~1.0.1: - version "1.0.1" - resolved "https://registry.yarnpkg.com/prr/-/prr-1.0.1.tgz#d3fc114ba06995a45ec6893f484ceb1d78f5f476" - integrity sha512-yPw4Sng1gWghHQWj0B3ZggWUm4qVbPwPFcRG8KyxiU7J2OHFSoEHKS+EZ3fv5l1t9CyCiop6l/ZYeWbrgoQejw== - -psl@^1.1.28: - version "1.9.0" - resolved "https://registry.yarnpkg.com/psl/-/psl-1.9.0.tgz#d0df2a137f00794565fcaf3b2c00cd09f8d5a5a7" - integrity sha512-E/ZsdU4HLs/68gYzgGTkMicWTLPdAftJLfJFlLUAAKZGkStNU72sZjT66SnMDVOfOWY/YAoiD7Jxa9iHvngcag== - -punycode@^1.4.1: - version "1.4.1" - resolved "https://registry.yarnpkg.com/punycode/-/punycode-1.4.1.tgz#c0d5a63b2718800ad8e1eb0fa5269c84dd41845e" - integrity sha512-jmYNElW7yvO7TV33CjSmvSiE2yco3bV2czu/OzDKdMNVZQWfxCblURLhf+47syQRBntjfLdd/H0egrzIG+oaFQ== - -punycode@^2.1.0, punycode@^2.1.1: +punycode@^2.1.0: version "2.3.1" resolved "https://registry.yarnpkg.com/punycode/-/punycode-2.3.1.tgz#027422e2faec0b25e1549c3e1bd8309b9133b6e5" integrity sha512-vYt7UD1U9Wg6138shLtLOvdAu+8DsC/ilFtEVHcH+wydcSpNE20AfSOduf6MkRFahL5FY7X1oU7nKVZFtfq8Fg== -qs@^6.11.2, qs@^6.4.0, qs@^6.9.4: +qs@^6.4.0, qs@^6.9.4: version "6.11.2" resolved "https://registry.yarnpkg.com/qs/-/qs-6.11.2.tgz#64bea51f12c1f5da1bc01496f48ffcff7c69d7d9" integrity sha512-tDNIz22aBzCDxLtVH++VnTfzxlfeK5CbqohpSqpJgj1Wg/cQbStNAz3NuqCs5vV+pjBsK4x4pN9HlVh7rcYRiA== dependencies: side-channel "^1.0.4" -qs@~6.5.2: - version "6.5.3" - resolved "https://registry.yarnpkg.com/qs/-/qs-6.5.3.tgz#3aeeffc91967ef6e35c0e488ef46fb296ab76aad" - integrity sha512-qxXIEh4pCGfHICj1mAJQ2/2XVZkjCDTcEgfoSQxc/fYivUZxTkk7L3bDBJSoNrEzXI17oUO5Dp07ktqE5KzczA== - queue-microtask@^1.2.2, queue-microtask@^1.2.3: version "1.2.3" resolved "https://registry.yarnpkg.com/queue-microtask/-/queue-microtask-1.2.3.tgz#4929228bbc724dfac43e0efb058caf7b6cfb6243" integrity sha512-NuaNSa6flKT5JaSYQzJok04JzTL1CA6aGhv5rfLW3PgqA+M2ChpZQnAC8h8i4ZFkBS8X5RqkDBHA7r4hej3K9A== -randombytes@^2.0.1, randombytes@^2.1.0: +quick-lru@^5.1.1: + version "5.1.1" + resolved "https://registry.yarnpkg.com/quick-lru/-/quick-lru-5.1.1.tgz#366493e6b3e42a3a6885e2e99d18f80fb7a8c932" + integrity sha512-WuyALRjWPDGtt/wzJiadO5AXY+8hZ80hVpe6MyivgraREW751X3SbhRvG3eLKOYN+8VEvqLcf3wdnt44Z4S4SA== + +randombytes@^2.1.0: version "2.1.0" resolved "https://registry.yarnpkg.com/randombytes/-/randombytes-2.1.0.tgz#df6f84372f0270dc65cdf6291349ab7a473d4f2a" integrity sha512-vYl3iOX+4CKUWuxGi9Ukhie6fsqXqS9FE2Zaic4tNFD2N2QQaXOMFbuKK4QmDHC0JO6B1Zp41J0LpT0oR68amQ== @@ -5181,6 +4526,16 @@ raw-body@^2.4.1: iconv-lite "0.4.24" unpipe "1.0.0" +rc@1.2.8: + version "1.2.8" + resolved "https://registry.yarnpkg.com/rc/-/rc-1.2.8.tgz#cd924bf5200a075b83c188cd6b9e211b7fc0d3ed" + integrity sha512-y3bGgqKj3QBdxLbLkomlohkvsA8gdAiUQlSBJnBhfn+BPxg4bc62d8TcBW15wavDfgexCgccckhcZvywyQYPOw== + dependencies: + deep-extend "^0.6.0" + ini "~1.3.0" + minimist "^1.2.0" + strip-json-comments "~2.0.1" + readable-stream@^2.2.2: version "2.3.8" resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-2.3.8.tgz#91125e8042bba1b9887f49345f6277027ce8be9b" @@ -5194,7 +4549,7 @@ readable-stream@^2.2.2: string_decoder "~1.1.1" util-deprecate "~1.0.1" -readable-stream@^3.1.0, readable-stream@^3.4.0, readable-stream@^3.6.0: +readable-stream@^3.6.0: version "3.6.2" resolved "https://registry.yarnpkg.com/readable-stream/-/readable-stream-3.6.2.tgz#56a9b36ea965c00c5a93ef31eb111a0f11056967" integrity sha512-9u/sniCrY3D5WdsERHzHE4G2YCXqoG5FTHUiCC4SIbr6XcLZBY05ya9EKjYek9O5xOAwjGq+1JdGBAS7Q9ScoA== @@ -5238,6 +4593,20 @@ regexp.prototype.flags@^1.5.1: define-properties "^1.2.0" set-function-name "^2.0.0" +registry-auth-token@^5.0.1: + version "5.0.2" + resolved "https://registry.yarnpkg.com/registry-auth-token/-/registry-auth-token-5.0.2.tgz#8b026cc507c8552ebbe06724136267e63302f756" + integrity sha512-o/3ikDxtXaA59BmZuZrJZDJv8NMDGSj+6j6XaeBmHw8eY1i1qd9+6H+LjVvQXx3HN6aRCGa1cUdJ9RaJZUugnQ== + dependencies: + "@pnpm/npm-conf" "^2.1.0" + +registry-url@^6.0.0: + version "6.0.1" + resolved "https://registry.yarnpkg.com/registry-url/-/registry-url-6.0.1.tgz#056d9343680f2f64400032b1e199faa692286c58" + integrity sha512-+crtS5QjFRqFCoQmvGduwYWEBng99ZvmFvF+cUJkGYF1L1BfU8C6Zp9T7f5vPAwyLkUExpvK+ANVZmGU49qi4Q== + dependencies: + rc "1.2.8" + req-cwd@^2.0.0: version "2.0.0" resolved "https://registry.yarnpkg.com/req-cwd/-/req-cwd-2.0.0.tgz#d4082b4d44598036640fb73ddea01ed53db49ebc" @@ -5252,32 +4621,6 @@ req-from@^2.0.0: dependencies: resolve-from "^3.0.0" -request@^2.85.0: - version "2.88.2" - resolved "https://registry.yarnpkg.com/request/-/request-2.88.2.tgz#d73c918731cb5a87da047e207234146f664d12b3" - integrity sha512-MsvtOrfG9ZcrOwAW+Qi+F6HbD0CWXEh9ou77uOb7FM2WPhwT7smM833PzanhJLsgXjN89Ir6V2PczXNnMpwKhw== - dependencies: - aws-sign2 "~0.7.0" - aws4 "^1.8.0" - caseless "~0.12.0" - combined-stream "~1.0.6" - extend "~3.0.2" - forever-agent "~0.6.1" - form-data "~2.3.2" - har-validator "~5.1.3" - http-signature "~1.2.0" - is-typedarray "~1.0.0" - isstream "~0.1.2" - json-stringify-safe "~5.0.1" - mime-types "~2.1.19" - oauth-sign "~0.9.0" - performance-now "^2.1.0" - qs "~6.5.2" - safe-buffer "^5.1.2" - tough-cookie "~2.5.0" - tunnel-agent "^0.6.0" - uuid "^3.3.2" - require-directory@^2.1.1: version "2.1.1" resolved "https://registry.yarnpkg.com/require-directory/-/require-directory-2.1.1.tgz#8c64ad5fd30dab1c976e2344ffe7f792a6a6df42" @@ -5288,6 +4631,11 @@ require-from-string@^2.0.0, require-from-string@^2.0.2: resolved "https://registry.yarnpkg.com/require-from-string/-/require-from-string-2.0.2.tgz#89a7fdd938261267318eafe14f9c32e598c36909" integrity sha512-Xf0nWe6RseziFMu+Ap9biiUbmplq6S9/p+7w7YXP/JBHhrUDDUhwa+vANyubuqfZWTveU//DYVGsDG7RKL/vEw== +resolve-alpn@^1.2.0: + version "1.2.1" + resolved "https://registry.yarnpkg.com/resolve-alpn/-/resolve-alpn-1.2.1.tgz#b7adbdac3546aaaec20b45e7d8265927072726f9" + integrity sha512-0a1F4l73/ZFZOakJnQ3FvkJ2+gSTQWz/r2KE5OdDY0TxPm5h4GkqkWWfM47T7HsbnOtcJVEF4epCVy6u7Q3K+g== + resolve-from@^3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/resolve-from/-/resolve-from-3.0.0.tgz#b22c7af7d9d6881bc8b6e653335eebcb0a188748" @@ -5319,6 +4667,13 @@ resolve@^1.1.6: path-parse "^1.0.7" supports-preserve-symlinks-flag "^1.0.0" +responselike@^3.0.0: + version "3.0.0" + resolved "https://registry.yarnpkg.com/responselike/-/responselike-3.0.0.tgz#20decb6c298aff0dbee1c355ca95461d42823626" + integrity sha512-40yHxbNcl2+rzXvZuVkrYohathsSJlMTXKryG5y8uciHv1+xDLHQpgjG64JUO9nrEq2jGLH6IZ8BcZyw3wrweg== + dependencies: + lowercase-keys "^3.0.0" + retry@0.13.1: version "0.13.1" resolved "https://registry.yarnpkg.com/retry/-/retry-0.13.1.tgz#185b1587acf67919d63b357349e03537b2484658" @@ -5356,13 +4711,6 @@ ripemd160@^2.0.0, ripemd160@^2.0.1: hash-base "^3.0.0" inherits "^2.0.1" -rlp@2.2.6: - version "2.2.6" - resolved "https://registry.yarnpkg.com/rlp/-/rlp-2.2.6.tgz#c80ba6266ac7a483ef1e69e8e2f056656de2fb2c" - integrity sha512-HAfAmL6SDYNWPUOJNrM500x4Thn4PZsEy5pijPh40U9WfNk0z15hUYzO9xVIMAdIHdFtD8CBDHd75Td1g36Mjg== - dependencies: - bn.js "^4.11.1" - rlp@^2.2.3, rlp@^2.2.4: version "2.2.7" resolved "https://registry.yarnpkg.com/rlp/-/rlp-2.2.7.tgz#33f31c4afac81124ac4b283e2bd4d9720b30beaf" @@ -5418,7 +4766,7 @@ safe-regex-test@^1.0.0: es-errors "^1.3.0" is-regex "^1.1.4" -"safer-buffer@>= 2.1.2 < 3", safer-buffer@^2.0.2, safer-buffer@^2.1.0, safer-buffer@~2.1.0: +"safer-buffer@>= 2.1.2 < 3": version "2.1.2" resolved "https://registry.yarnpkg.com/safer-buffer/-/safer-buffer-2.1.2.tgz#44fa161b0187b9549dd84bb91802f9bd8385cd6a" integrity sha512-YZo3K82SD7Riyi0E1EQPojLz7kpepnSQI9IyPbHHg1XXXevb5dJI7tpyN2ADxGcQbHG7vcyRHk0cbwqcQriUtg== @@ -5448,7 +4796,7 @@ scrypt-js@3.0.1, scrypt-js@^3.0.0: resolved "https://registry.yarnpkg.com/scrypt-js/-/scrypt-js-3.0.1.tgz#d314a57c2aef69d1ad98a138a21fe9eafa9ee312" integrity sha512-cdwTTnqPu0Hyvf5in5asVdZocVDTNRmR7XEcJuIzMjJeSHybHl7vpB66AzwTaIg6CLSbtjcxc8fqcySfnTkccA== -secp256k1@4.0.3, secp256k1@^4.0.1: +secp256k1@^4.0.1: version "4.0.3" resolved "https://registry.yarnpkg.com/secp256k1/-/secp256k1-4.0.3.tgz#c4559ecd1b8d3c1827ed2d1b94190d69ce267303" integrity sha512-NLZVf+ROMxwtEj3Xa562qgv2BK5e2WNmXPiOdVIPLgs6lyTzMvBq0aWTYMI5XCP9jZMVKOcqZLw/Wc4vDkuxhA== @@ -5457,16 +4805,6 @@ secp256k1@4.0.3, secp256k1@^4.0.1: node-addon-api "^2.0.0" node-gyp-build "^4.2.0" -seedrandom@3.0.5: - version "3.0.5" - resolved "https://registry.yarnpkg.com/seedrandom/-/seedrandom-3.0.5.tgz#54edc85c95222525b0c7a6f6b3543d8e0b3aa0a7" - integrity sha512-8OwmbklUNzwezjGInmZ+2clQmExQPvomqjL7LFqOYqtmuxRgQYqOD3mHaU+MvZn5FLUeVxVfQjwLZW/n/JFuqg== - -semaphore-async-await@^1.5.1: - version "1.5.1" - resolved "https://registry.yarnpkg.com/semaphore-async-await/-/semaphore-async-await-1.5.1.tgz#857bef5e3644601ca4b9570b87e9df5ca12974fa" - integrity sha512-b/ptP11hETwYWpeilHXXQiV5UJNJl7ZWWooKRE5eBIYWoom6dZ0SluCIdCtKycsMtZgKWE01/qAw6jblw1YVhg== - semver@^5.5.0: version "5.7.2" resolved "https://registry.yarnpkg.com/semver/-/semver-5.7.2.tgz#48d55db737c3287cd4835e17fa13feace1c41ef8" @@ -5477,7 +4815,7 @@ semver@^6.3.0: resolved "https://registry.yarnpkg.com/semver/-/semver-6.3.1.tgz#556d2ef8689146e46dcea4bfdd095f3434dffcb4" integrity sha512-BR7VvDCVHO+q2xBEWskxS6DJE1qRnb7DxzUrogb71CWoSficBxYsiAGd+Kl0mmq/MprG9yArRkyrQxTO6XjMzA== -semver@^7.3.4, semver@^7.5.2, semver@^7.5.4: +semver@^7.3.4, semver@^7.3.7, semver@^7.5.2, semver@^7.5.4: version "7.6.0" resolved "https://registry.yarnpkg.com/semver/-/semver-7.6.0.tgz#1a46a4db4bffcccd97b743b5005c8325f23d4e2d" integrity sha512-EnwXhrlwXMk9gKu5/flx5sv/an57AkRplG3hTK68W7FRDN+k+OWBj65M7719OkA82XLBxrcX0KSHj+X5COhOVg== @@ -5608,30 +4946,43 @@ solc@0.7.3: semver "^5.5.0" tmp "0.0.33" -solc@0.8.15: - version "0.8.15" - resolved "https://registry.yarnpkg.com/solc/-/solc-0.8.15.tgz#d274dca4d5a8b7d3c9295d4cbdc9291ee1c52152" - integrity sha512-Riv0GNHNk/SddN/JyEuFKwbcWcEeho15iyupTSHw5Np6WuXA5D8kEHbyzDHi6sqmvLzu2l+8b1YmL8Ytple+8w== +solhint-community@^3.7.0: + version "3.7.0" + resolved "https://registry.yarnpkg.com/solhint-community/-/solhint-community-3.7.0.tgz#5d8bd4a2137d44dd636272edce93cb754184c09b" + integrity sha512-8nfdaxVll+IIaEBHFz3CzagIZNNTGp4Mrr+6O4m7c9Bs/L8OcgR/xzZJFwROkGAhV8Nbiv4gqJ42nEXZPYl3Qw== dependencies: - command-exists "^1.2.8" - commander "^8.1.0" - follow-redirects "^1.12.1" - js-sha3 "0.8.0" - memorystream "^0.3.1" - semver "^5.5.0" - tmp "0.0.33" + "@solidity-parser/parser" "^0.16.0" + ajv "^6.12.6" + antlr4 "^4.11.0" + ast-parents "^0.0.1" + chalk "^4.1.2" + commander "^11.1.0" + cosmiconfig "^8.0.0" + fast-diff "^1.2.0" + glob "^8.0.3" + ignore "^5.2.4" + js-yaml "^4.1.0" + lodash "^4.17.21" + pluralize "^8.0.0" + semver "^6.3.0" + strip-ansi "^6.0.1" + table "^6.8.1" + text-table "^0.2.0" + optionalDependencies: + prettier "^2.8.3" -solhint-plugin-prettier@^0.0.5: - version "0.0.5" - resolved "https://registry.yarnpkg.com/solhint-plugin-prettier/-/solhint-plugin-prettier-0.0.5.tgz#e3b22800ba435cd640a9eca805a7f8bc3e3e6a6b" - integrity sha512-7jmWcnVshIrO2FFinIvDQmhQpfpS2rRRn3RejiYgnjIE68xO2bvrYvjqVNfrio4xH9ghOqn83tKuTzLjEbmGIA== +solhint-plugin-prettier@^0.1.0: + version "0.1.0" + resolved "https://registry.yarnpkg.com/solhint-plugin-prettier/-/solhint-plugin-prettier-0.1.0.tgz#2f46999e26d6c6bc80281c22a7a21e381175bef7" + integrity sha512-SDOTSM6tZxZ6hamrzl3GUgzF77FM6jZplgL2plFBclj/OjKP8Z3eIPojKU73gRr0MvOS8ACZILn8a5g0VTz/Gw== dependencies: + "@prettier/sync" "^0.3.0" prettier-linter-helpers "^1.0.0" -solhint@^3.4.1: - version "3.6.2" - resolved "https://registry.yarnpkg.com/solhint/-/solhint-3.6.2.tgz#2b2acbec8fdc37b2c68206a71ba89c7f519943fe" - integrity sha512-85EeLbmkcPwD+3JR7aEMKsVC9YrRSxd4qkXuMzrlf7+z2Eqdfm1wHWq1ffTuo5aDhoZxp2I9yF3QkxZOxOL7aQ== +solhint@^4.1.1: + version "4.1.1" + resolved "https://registry.yarnpkg.com/solhint/-/solhint-4.1.1.tgz#137c935ef028f01ba13687a1f237288d94dae1bf" + integrity sha512-7G4iF8H5hKHc0tR+/uyZesSKtfppFIMvPSW+Ku6MSL25oVRuyFeqNhOsXHfkex64wYJyXs4fe+pvhB069I19Tw== dependencies: "@solidity-parser/parser" "^0.16.0" ajv "^6.12.6" @@ -5644,6 +4995,7 @@ solhint@^3.4.1: glob "^8.0.3" ignore "^5.2.4" js-yaml "^4.1.0" + latest-version "^7.0.0" lodash "^4.17.21" pluralize "^8.0.0" semver "^7.5.2" @@ -5665,7 +5017,7 @@ solidity-comments-extractor@^0.0.8: resolved "https://registry.yarnpkg.com/solidity-comments-extractor/-/solidity-comments-extractor-0.0.8.tgz#f6e148ab0c49f30c1abcbecb8b8df01ed8e879f8" integrity sha512-htM7Vn6LhHreR+EglVMd2s+sZhcXAirB1Zlyrv5zBuTxieCvjfnRpd7iZk75m/u6NOlEyQ94C6TWbBn2cY7w8g== -solidity-coverage@^0.8.2: +solidity-coverage@^0.8.6: version "0.8.6" resolved "https://registry.yarnpkg.com/solidity-coverage/-/solidity-coverage-0.8.6.tgz#c7b18dc9edfeba11064726c37d96265f689c9478" integrity sha512-vV03mA/0nNMskOdVwNarUcqk0N/aYdelxAbf6RZ5l84FcYHbqDTr2JXyeYMp4bT48qHtAQjnKrygW1FrECyWNw== @@ -5716,21 +5068,6 @@ sprintf-js@~1.0.2: resolved "https://registry.yarnpkg.com/sprintf-js/-/sprintf-js-1.0.3.tgz#04e6926f662895354f3dd015203633b857297e2c" integrity sha512-D9cPgkvLlV3t3IzL0D0YLvGA9Ahk4PcvVwUbN0dSGr1aP0Nrt4AEnTUbuGvquEC0mA64Gqt1fzirlRs5ibXx8g== -sshpk@^1.7.0: - version "1.18.0" - resolved "https://registry.yarnpkg.com/sshpk/-/sshpk-1.18.0.tgz#1663e55cddf4d688b86a46b77f0d5fe363aba028" - integrity sha512-2p2KJZTSqQ/I3+HX42EpYOa2l3f8Erv8MWKsy2I9uf4wA7yFIkXRffYdsx86y6z4vHtV8u7g+pPlr8/4ouAxsQ== - dependencies: - asn1 "~0.2.3" - assert-plus "^1.0.0" - bcrypt-pbkdf "^1.0.0" - dashdash "^1.12.0" - ecc-jsbn "~0.1.1" - getpass "^0.1.1" - jsbn "~0.1.0" - safer-buffer "^2.0.2" - tweetnacl "~0.14.0" - stacktrace-parser@^0.1.10: version "0.1.10" resolved "https://registry.yarnpkg.com/stacktrace-parser/-/stacktrace-parser-0.1.10.tgz#29fb0cae4e0d0b85155879402857a1639eb6051a" @@ -5832,6 +5169,11 @@ strip-json-comments@3.1.1, strip-json-comments@^3.1.1: resolved "https://registry.yarnpkg.com/strip-json-comments/-/strip-json-comments-3.1.1.tgz#31f1281b3832630434831c310c01cccda8cbe006" integrity sha512-6fPc+R4ihwqP6N/aIv2f1gMH8lOVtWQHoqC4yK6oSDVVocumAsfCqjkXnqiYMhmMwS/mEHLp7Vehlt3ql6lEig== +strip-json-comments@~2.0.1: + version "2.0.1" + resolved "https://registry.yarnpkg.com/strip-json-comments/-/strip-json-comments-2.0.1.tgz#3c531942e908c2697c0ec344858c286c7ca0a60a" + integrity sha512-4gB8na07fecVVkOI6Rs4e7T6NOTki5EmL7TUduTs6bu3EdnSycntVJ4re8kgZA+wx9IueI2Y11bfbgwtzuE0KQ== + supports-color@8.1.1: version "8.1.1" resolved "https://registry.yarnpkg.com/supports-color/-/supports-color-8.1.1.tgz#cd6fc17e28500cff56c1b86c0a7fd4a54a73005c" @@ -5881,6 +5223,14 @@ sync-rpc@^1.2.1: dependencies: get-port "^3.1.0" +synckit@^0.8.6: + version "0.8.8" + resolved "https://registry.yarnpkg.com/synckit/-/synckit-0.8.8.tgz#fe7fe446518e3d3d49f5e429f443cf08b6edfcd7" + integrity sha512-HwOKAP7Wc5aRGYdKH+dw0PRRpbO841v2DENBtjnR5HFWoiNByAl7vrx3p0G/rCyYXQsrxqtX48TImFtPcIHSpQ== + dependencies: + "@pkgr/core" "^0.1.0" + tslib "^2.6.2" + table-layout@^1.0.2: version "1.0.2" resolved "https://registry.yarnpkg.com/table-layout/-/table-layout-1.0.2.tgz#c4038a1853b0136d63365a734b6931cf4fad4a04" @@ -5956,14 +5306,6 @@ toidentifier@1.0.1: resolved "https://registry.yarnpkg.com/toidentifier/-/toidentifier-1.0.1.tgz#3be34321a88a820ed1bd80dfaa33e479fbb8dd35" integrity sha512-o5sSPKEkg/DIQNmH43V0/uerLrpzVedkUh8tGNvaeXpfpuwjKenlSox/2O/BTlZUtEe+JG7s5YhEz608PlAHRA== -tough-cookie@~2.5.0: - version "2.5.0" - resolved "https://registry.yarnpkg.com/tough-cookie/-/tough-cookie-2.5.0.tgz#cd9fb2a0aa1d5a12b473bd9fb96fa3dcff65ade2" - integrity sha512-nlLsUzgm1kfLXSXfRZMc1KLAugd4hqJHDTvc2hDIwS3mZAfMEuMbc03SujMF+GEcpaX/qboeycw6iO8JwVv2+g== - dependencies: - psl "^1.1.28" - punycode "^2.1.1" - tr46@~0.0.3: version "0.0.3" resolved "https://registry.yarnpkg.com/tr46/-/tr46-0.0.3.tgz#8184fd347dac9cdc185992f3a6622e14b9d9ab6a" @@ -6013,7 +5355,7 @@ tslib@^1.11.1, tslib@^1.9.3: resolved "https://registry.yarnpkg.com/tslib/-/tslib-1.14.1.tgz#cf2d38bdc34a134bcaf1091c41f6619e2f672d00" integrity sha512-Xni35NKzjgMrwevysHTCArtLDpPvye8zV/0E4EyYn43P7/7qvQwPh9BGkHewbMulVntbigmcT7rdX3BNo9wRJg== -tslib@^2.3.1, tslib@^2.5.0: +tslib@^2.3.1, tslib@^2.5.0, tslib@^2.6.2: version "2.6.2" resolved "https://registry.yarnpkg.com/tslib/-/tslib-2.6.2.tgz#703ac29425e7b37cd6fd456e92404d46d1f3e4ae" integrity sha512-AEYxH93jGFPn/a2iVAwW87VuUIkR1FVUKB77NwMF7nBTDkDrrT/Hpt/IrCJ0QXhW27jTBDcf5ZY7w6RiqTMw2Q== @@ -6028,23 +5370,11 @@ tsort@0.0.1: resolved "https://registry.yarnpkg.com/tsort/-/tsort-0.0.1.tgz#e2280f5e817f8bf4275657fd0f9aebd44f5a2786" integrity sha512-Tyrf5mxF8Ofs1tNoxA13lFeZ2Zrbd6cKbuH3V+MQ5sb6DtBj5FjrXVsRWT8YvNAQTqNoz66dz1WsbigI22aEnw== -tunnel-agent@^0.6.0: - version "0.6.0" - resolved "https://registry.yarnpkg.com/tunnel-agent/-/tunnel-agent-0.6.0.tgz#27a5dea06b36b04a0a9966774b290868f0fc40fd" - integrity sha512-McnNiV1l8RYeY8tBgEpuodCC1mLUdbSN+CYBL7kJsJNInOP8UjDDEwdk6Mw60vdLLrr5NHKZhMAOSrR2NZuQ+w== - dependencies: - safe-buffer "^5.0.1" - tweetnacl-util@^0.15.1: version "0.15.1" resolved "https://registry.yarnpkg.com/tweetnacl-util/-/tweetnacl-util-0.15.1.tgz#b80fcdb5c97bcc508be18c44a4be50f022eea00b" integrity sha512-RKJBIj8lySrShN4w6i/BonWp2Z/uxwC3h4y7xsRrpP59ZboCd0GpEVsOnMDYLMmKBpYhb5TgHzZXy7wTfYFBRw== -tweetnacl@^0.14.3, tweetnacl@~0.14.0: - version "0.14.5" - resolved "https://registry.yarnpkg.com/tweetnacl/-/tweetnacl-0.14.5.tgz#5ae68177f192d4456269d108afa93ff8743f4f64" - integrity sha512-KXXFFdAbFXY4geFIwoyNK+f5Z1b7swfXABfL7HXCmoIWMKU3dmS26672A4EeQtDzLKy7SXmfBu51JolvEKwtGA== - tweetnacl@^1.0.3: version "1.0.3" resolved "https://registry.yarnpkg.com/tweetnacl/-/tweetnacl-1.0.3.tgz#ac0af71680458d8a6378d0d0d050ab1407d35596" @@ -6064,11 +5394,6 @@ type-check@~0.3.2: dependencies: prelude-ls "~1.1.2" -type-detect@^4.0.0, type-detect@^4.0.8: - version "4.0.8" - resolved "https://registry.yarnpkg.com/type-detect/-/type-detect-4.0.8.tgz#7646fb5f18871cfbb7749e69bd39a6388eb7450c" - integrity sha512-0fr/mIH1dlO+x7TlcMy+bIDqKPsw/70tVyeHW787goQjhmqaZe10uwLujubK9q9Lg6Fiho1KUKDYz0Z7k7g5/g== - type-fest@^0.20.2: version "0.20.2" resolved "https://registry.yarnpkg.com/type-fest/-/type-fest-0.20.2.tgz#1bf207f4b28f91583666cb5fbd327887301cd5f4" @@ -6084,7 +5409,7 @@ type-fest@^0.7.1: resolved "https://registry.yarnpkg.com/type-fest/-/type-fest-0.7.1.tgz#8dda65feaf03ed78f0a3f9678f1869147f7c5c48" integrity sha512-Ne2YiiGN8bmrmJJEuTWTLJR32nh/JdL1+PSicowtNb0WFpn59GK8/lfD61bVtzguz7b3PBt74nxpv/Pw5po5Rg== -typechain@^8.0.0, typechain@^8.3.2: +typechain@^8.3.2: version "8.3.2" resolved "https://registry.yarnpkg.com/typechain/-/typechain-8.3.2.tgz#1090dd8d9c57b6ef2aed3640a516bdbf01b00d73" integrity sha512-x/sQYr5w9K7yv3es7jo4KTX05CLxOf7TRWwoHlrjRh8H82G64g+k7VuWPJlgMo6qrjfCulOdfBjiaDtmhFYD/Q== @@ -6213,21 +5538,6 @@ uri-js@^4.2.2: dependencies: punycode "^2.1.0" -url@^0.11.0: - version "0.11.3" - resolved "https://registry.yarnpkg.com/url/-/url-0.11.3.tgz#6f495f4b935de40ce4a0a52faee8954244f3d3ad" - integrity sha512-6hxOLGfZASQK/cijlZnZJTq8OXAkt/3YGfQX45vvMYXpZoo8NdWZcY73K108Jf759lS1Bv/8wXnHDTSz17dSRw== - dependencies: - punycode "^1.4.1" - qs "^6.11.2" - -utf-8-validate@5.0.7: - version "5.0.7" - resolved "https://registry.yarnpkg.com/utf-8-validate/-/utf-8-validate-5.0.7.tgz#c15a19a6af1f7ad9ec7ddc425747ca28c3644922" - integrity sha512-vLt1O5Pp+flcArHGIyKEQq883nBt8nN8tVBcoL0qUXj2XT1n7p70yGIq2VK98I5FdZ1YHc0wk/koOnHjnXWk1Q== - dependencies: - node-gyp-build "^4.3.0" - utf8@3.0.0: version "3.0.0" resolved "https://registry.yarnpkg.com/utf8/-/utf8-3.0.0.tgz#f052eed1364d696e769ef058b183df88c87f69d1" @@ -6238,11 +5548,6 @@ util-deprecate@^1.0.1, util-deprecate@~1.0.1: resolved "https://registry.yarnpkg.com/util-deprecate/-/util-deprecate-1.0.2.tgz#450d4dc9fa70de732762fbd2d4a28981419a0ccf" integrity sha512-EPD5q1uXyFxJpCrLnCc1nHnq3gOa6DZBocAIiI2TaSCA7VCJ1UJDMagCzIkXNsUYfD1daK//LTEQ8xiIbrHtcw== -uuid@^3.3.2: - version "3.4.0" - resolved "https://registry.yarnpkg.com/uuid/-/uuid-3.4.0.tgz#b23e4358afa8a202fe7a100af1f5f883f02007ee" - integrity sha512-HjSDRw6gZE5JMggctHBcjVak08+KEVhSIiDzFnT9S9aegmp85S/bReBVTb4QTFaRNptJ9kuYaNhnbNEOkbKb/A== - uuid@^8.3.2: version "8.3.2" resolved "https://registry.yarnpkg.com/uuid/-/uuid-8.3.2.tgz#80d5b5ced271bb9af6c445f21a1a04c606cefbe2" @@ -6253,15 +5558,6 @@ v8-compile-cache-lib@^3.0.1: resolved "https://registry.yarnpkg.com/v8-compile-cache-lib/-/v8-compile-cache-lib-3.0.1.tgz#6336e8d71965cb3d35a1bbb7868445a7c05264bf" integrity sha512-wa7YjyUGfNZngI/vtK0UHAN+lgDCxBPCylVXGp0zu59Fz5aiGtNXaq3DhIov063MorB+VfufLh3JlF2KdTK3xg== -verror@1.10.0: - version "1.10.0" - resolved "https://registry.yarnpkg.com/verror/-/verror-1.10.0.tgz#3a105ca17053af55d6e270c1f8288682e18da400" - integrity sha512-ZZKSmDAEFOijERBLkmYfJ+vmk3w+7hOLYDNkRCuRuMJGEmqYNCNLyBBFwWKVMhfwaEF3WOd0Zlw86U/WC/+nYw== - dependencies: - assert-plus "^1.0.0" - core-util-is "1.0.2" - extsprintf "^1.2.0" - web3-utils@^1.3.6: version "1.10.4" resolved "https://registry.yarnpkg.com/web3-utils/-/web3-utils-1.10.4.tgz#0daee7d6841641655d8b3726baf33b08eda1cbec" @@ -6384,11 +5680,6 @@ ws@^7.4.6: resolved "https://registry.yarnpkg.com/ws/-/ws-7.5.9.tgz#54fa7db29f4c7cec68b1ddd3a89de099942bb591" integrity sha512-F+P9Jil7UiSKSkppIiD94dN07AwvFixvLIj1Og1Rl9GGMuNipJnV9JzjD6XuqmAeiswGvUmNLjr5cFuXwNS77Q== -xtend@^4.0.1, xtend@^4.0.2, xtend@~4.0.0: - version "4.0.2" - resolved "https://registry.yarnpkg.com/xtend/-/xtend-4.0.2.tgz#bb72779f5fa465186b1f438f674fa347fdb5db54" - integrity sha512-LKYU1iAXJXUgAXn9URjiu+MWhyUXHsvfp7mcuYm9dSUKK0/CjtrUwFAxD82/mCWbtLsGjFIad0wIsod4zrTAEQ== - y18n@^5.0.5: version "5.0.8" resolved "https://registry.yarnpkg.com/y18n/-/y18n-5.0.8.tgz#7f4934d0f7ca8c56f95314939ddcd2dd91ce1d55"