diff --git a/abis-supplemental/MinPriceLib.json b/abis-supplemental/MinPriceLib.json new file mode 100644 index 00000000..2aa27cc7 --- /dev/null +++ b/abis-supplemental/MinPriceLib.json @@ -0,0 +1,24 @@ +{ + "_format": "hh-sol-artifact-1", + "contractName": "MinPriceLib", + "sourceName": "contracts/libs/v0.8.x/minter-libs/MinPriceLib.sol", + "abi": [ + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "uint256", + "name": "minMintFee", + "type": "uint256" + } + ], + "name": "MinMintFeeUpdated", + "type": "event" + } + ], + "bytecode": "0x60566037600b82828239805160001a607314602a57634e487b7160e01b600052600060045260246000fd5b30600052607381538281f3fe73000000000000000000000000000000000000000030146080604052600080fdfea2646970667358221220fd94d5ad7380cbc6b28763797313de44be00d82998064d18e865734e3de0af9e64736f6c63430008160033", + "deployedBytecode": "0x73000000000000000000000000000000000000000030146080604052600080fdfea2646970667358221220fd94d5ad7380cbc6b28763797313de44be00d82998064d18e865734e3de0af9e64736f6c63430008160033", + "linkReferences": {}, + "deployedLinkReferences": {} +} diff --git a/config/generic.json b/config/generic.json index e247f9d5..84b425b0 100644 --- a/config/generic.json +++ b/config/generic.json @@ -75,6 +75,11 @@ "address": "" } ], + "minPriceLibContracts": [ + { + "address": "" + } + ], "maxInvocationsLibContracts": [ { "address": "" diff --git a/src/min-price-lib-mapping.ts b/src/min-price-lib-mapping.ts new file mode 100644 index 00000000..6911882f --- /dev/null +++ b/src/min-price-lib-mapping.ts @@ -0,0 +1,33 @@ +import { MinMintFeeUpdated } from "../generated/MinPriceLib/MinPriceLib"; +import { loadOrCreateMinter } from "./helpers"; +import { setMinterExtraMinterDetailsValue } from "./extra-minter-details-helpers"; + +/////////////////////////////////////////////////////////////////////////////// +// EVENT HANDLERS start here +/////////////////////////////////////////////////////////////////////////////// + +/** + * Handles the update of contract-level min mint fee. + * Loads or creates the minter, updates the minter's extra minter details with + * the updated value, and induces a sync of the minter entity. + * @param event The event carrying new min mint fee value. + */ +export function handleMinMintFeeUpdated(event: MinMintFeeUpdated): void { + // load minter + const minter = loadOrCreateMinter(event.address, event.block.timestamp); + + // update minter entity + setMinterExtraMinterDetailsValue( + "minMintFee", + event.params.minMintFee.toString(), + minter + ); + + // update minter's updatedAt timestamp to induce a sync, and save + minter.updatedAt = event.block.timestamp; + minter.save(); +} + +/////////////////////////////////////////////////////////////////////////////// +// EVENT HANDLERS end here +/////////////////////////////////////////////////////////////////////////////// diff --git a/subgraph.template.yaml b/subgraph.template.yaml index f6ed7d04..420b3e2b 100644 --- a/subgraph.template.yaml +++ b/subgraph.template.yaml @@ -1204,6 +1204,57 @@ dataSources: handler: handlePricePerTokenReset file: ./src/set-price-lib-mapping.ts {{/setPriceLibContracts}} + {{#minPriceLibContracts}} + - kind: ethereum/contract + name: 'MinPriceLib{{#address}}-{{address}}{{/address}}' + network: {{network}} + source: + address: "{{#address}}{{address}}{{/address}}{{^address}}0x0000000000000000000000000000000000000000{{/address}}" + abi: MinPriceLib + {{#startBlock}}startBlock: {{startBlock}}{{/startBlock}} + mapping: + kind: ethereum/events + apiVersion: 0.0.5 + language: wasm/assemblyscript + entities: + - Project + - ProjectScript + - Token + - Contract + - Account + - AccountProject + - Whitelisting + - MinterFilter + - Minter + - ProjectMinterConfiguration + abis: + - name: MinPriceLib + file: ./abis/MinPriceLib.json + - name: ISharedMinterV0 + file: ./abis/ISharedMinterV0.json + - name: IFilteredMinterV2 + file: ./abis/IFilteredMinterV2.json + - name: IFilteredMinterDALinV1 + file: ./abis/IFilteredMinterDALinV1.json + - name: IFilteredMinterDAExpV1 + file: ./abis/IFilteredMinterDAExpV1.json + - name: IFilteredMinterDAExpSettlementV1 + file: ./abis/IFilteredMinterDAExpSettlementV1.json + - name: IFilteredMinterV2 + file: ./abis/IFilteredMinterV2.json + - name: IFilteredMinterHolderV2 + file: ./abis/IFilteredMinterHolderV2.json + - name: IFilteredMinterMerkleV2 + file: ./abis/IFilteredMinterMerkleV2.json + - name: IFilteredMinterSEAV0 + file: ./abis/IFilteredMinterSEAV0.json + - name: ERC20 + file: ./abis/ERC20.json + eventHandlers: + - event: MinMintFeeUpdated(uint256) + handler: handleMinMintFeeUpdated + file: ./src/min-price-lib-mapping.ts + {{/minPriceLibContracts}} {{#maxInvocationsLibContracts}} - kind: ethereum/contract name: 'MaxInvocationsLib{{#address}}-{{address}}{{/address}}' diff --git a/tests/e2e/runner/__tests__/minter-suite-v2/min-price-lib.test.ts b/tests/e2e/runner/__tests__/minter-suite-v2/min-price-lib.test.ts new file mode 100644 index 00000000..54ad5ffe --- /dev/null +++ b/tests/e2e/runner/__tests__/minter-suite-v2/min-price-lib.test.ts @@ -0,0 +1,62 @@ +import { describe, test, expect } from "@jest/globals"; +import { + getSubgraphConfig, + createSubgraphClient, + getAccounts, + waitUntilSubgraphIsSynced, + getMinterDetails, +} from "../utils/helpers"; + +import { MinterMinPriceV0__factory } from "../../contracts/factories/MinterMinPriceV0__factory"; +// hide nuisance logs about event overloading +import { Logger } from "@ethersproject/logger"; +Logger.setLogLevel(Logger.levels.ERROR); + +// waiting for subgraph to sync can take longer than the default 5s timeout +// @dev For this file specifically, one test takes >60s due to hard-coded minimum +// auction duration on SEA minter +jest.setTimeout(100 * 1000); + +const config = getSubgraphConfig(); + +const client = createSubgraphClient(); +const { deployer } = getAccounts(); + +// get min price lib contract from the subgraph config +if (!config.minPriceLibContracts) { + throw new Error("No minPriceLibContracts in config"); +} +const minterMinPriceV0Address = config.minPriceLibContracts[0].address; +const minterMinPriceV0Contract = new MinterMinPriceV0__factory(deployer).attach( + minterMinPriceV0Address +); + +describe("MinPriceLib event handling", () => { + beforeAll(async () => { + await waitUntilSubgraphIsSynced(client); + }); + + describe("Indexed after setup", () => { + test("created new Minter during deployment and allowlisting", async () => { + const targetId = minterMinPriceV0Address.toLowerCase(); + const minterRes = await getMinterDetails(client, targetId); + expect(minterRes.id).toBe(targetId); + }); + }); + + describe("MinMintFeeUpdated", () => { + // this is a minter-level, value set in the constructor and other function(s), + // so we can inspect it by checking the Minter entity in the subgraph + // that was created during deployment + test("value was populated during deployment", async () => { + // query public constant for the expected value (>0) + const expectedValue = await minterMinPriceV0Contract.minMintFee(); + expect(expectedValue.gt(0)).toBe(true); + // validate minter's extraMinterDetails in subgraph + const targetId = minterMinPriceV0Address.toLowerCase(); + const minterRes = await getMinterDetails(client, targetId); + const extraMinterDetails = JSON.parse(minterRes.extraMinterDetails); + expect(extraMinterDetails.minMintFee).toBe(expectedValue.toString()); + }); + }); +}); diff --git a/tests/e2e/runner/__tests__/subgraph-config.d.ts b/tests/e2e/runner/__tests__/subgraph-config.d.ts index 701f105e..6a3606fe 100644 --- a/tests/e2e/runner/__tests__/subgraph-config.d.ts +++ b/tests/e2e/runner/__tests__/subgraph-config.d.ts @@ -30,6 +30,7 @@ export type SubgraphConfig = Partial<{ maxInvocationsLibContracts: { address: string }[]; merkleLibContracts: { address: string }[]; holderLibContracts: { address: string }[]; + minPriceLibContracts: { address: string }[]; SEALibContracts: { address: string }[]; RAMLibContracts: { address: string }[]; DALibContracts: { address: string }[]; diff --git a/tests/e2e/runner/supplemental_abis/MinterMinPriceV0.json b/tests/e2e/runner/supplemental_abis/MinterMinPriceV0.json new file mode 100644 index 00000000..bef8e4e7 --- /dev/null +++ b/tests/e2e/runner/supplemental_abis/MinterMinPriceV0.json @@ -0,0 +1,387 @@ +{ + "_format": "hh-sol-artifact-1", + "contractName": "MinterMinPriceV0", + "sourceName": "contracts/minter-suite/Minters/MinterMinPriceV0.sol", + "abi": [ + { + "inputs": [ + { + "internalType": "address", + "name": "minterFilter", + "type": "address" + }, + { + "internalType": "uint256", + "name": "minMintFee_", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "projectId", + "type": "uint256" + }, + { + "internalType": "address", + "name": "coreContract", + "type": "address" + } + ], + "name": "getPriceInfo", + "outputs": [ + { + "internalType": "bool", + "name": "isConfigured", + "type": "bool" + }, + { + "internalType": "uint256", + "name": "tokenPriceInWei", + "type": "uint256" + }, + { + "internalType": "string", + "name": "currencySymbol", + "type": "string" + }, + { + "internalType": "address", + "name": "currencyAddress", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "coreContract", + "type": "address" + } + ], + "name": "isEngineView", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "projectId", + "type": "uint256" + }, + { + "internalType": "address", + "name": "coreContract", + "type": "address" + }, + { + "internalType": "uint24", + "name": "maxInvocations", + "type": "uint24" + } + ], + "name": "manuallyLimitProjectMaxInvocations", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "projectId", + "type": "uint256" + }, + { + "internalType": "address", + "name": "coreContract", + "type": "address" + } + ], + "name": "maxInvocationsProjectConfig", + "outputs": [ + { + "components": [ + { + "internalType": "bool", + "name": "maxHasBeenInvoked", + "type": "bool" + }, + { + "internalType": "uint24", + "name": "maxInvocations", + "type": "uint24" + } + ], + "internalType": "struct MaxInvocationsLib.MaxInvocationsProjectConfig", + "name": "", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "minMintFee", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "minterFilterAddress", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "minterType", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "minterVersion", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "projectId", + "type": "uint256" + }, + { + "internalType": "address", + "name": "coreContract", + "type": "address" + } + ], + "name": "projectMaxHasBeenInvoked", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "projectId", + "type": "uint256" + }, + { + "internalType": "address", + "name": "coreContract", + "type": "address" + } + ], + "name": "projectMaxInvocations", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "projectId", + "type": "uint256" + }, + { + "internalType": "address", + "name": "coreContract", + "type": "address" + } + ], + "name": "purchase", + "outputs": [ + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + } + ], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "internalType": "uint256", + "name": "projectId", + "type": "uint256" + }, + { + "internalType": "address", + "name": "coreContract", + "type": "address" + } + ], + "name": "purchaseTo", + "outputs": [ + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + } + ], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "projectId", + "type": "uint256" + }, + { + "internalType": "address", + "name": "coreContract", + "type": "address" + } + ], + "name": "setPriceProjectConfig", + "outputs": [ + { + "components": [ + { + "internalType": "uint248", + "name": "pricePerToken", + "type": "uint248" + }, + { + "internalType": "bool", + "name": "priceIsConfigured", + "type": "bool" + } + ], + "internalType": "struct SetPriceLib.SetPriceProjectConfig", + "name": "", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "projectId", + "type": "uint256" + }, + { + "internalType": "address", + "name": "coreContract", + "type": "address" + } + ], + "name": "syncProjectMaxInvocationsToCore", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "newMinMintFee", + "type": "uint256" + } + ], + "name": "updateMinMintFee", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "projectId", + "type": "uint256" + }, + { + "internalType": "address", + "name": "coreContract", + "type": "address" + }, + { + "internalType": "uint248", + "name": "pricePerTokenInWei", + "type": "uint248" + } + ], + "name": "updatePricePerTokenInWei", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } + ], + "bytecode": "0x60c060405234801561001057600080fd5b506040516118ae3803806118ae83398101604081905261002f916100b1565b60016000556001600160a01b038216608081905260a05261004f81610056565b50506100eb565b7f6aab9ffc5cd1e167fd16093ec2dc9fad33c2d2de62ce5b9a1df3152d598e2f938181556040805183815290517fe3595da100053125f59ccb164c0aadf2b9ad08a2ec6de1e706e0c7ca160416779181900360200190a15050565b600080604083850312156100c457600080fd5b82516001600160a01b03811681146100db57600080fd5b6020939093015192949293505050565b60805160a05161179761011760003960006104c5015260008181610311015261069301526117976000f3fe6080604052600436106100c35760003560e01c806301000da7146100c85780634869f3df146100fd5780634e8d87871461012b578063542afda31461013e5780637e947f24146101535780639a94488a146101755780639b24c3c0146101b7578063a14f10ca146101fd578063ae77c2371461021d578063b000e33414610230578063cce7c90914610250578063d3ddabe614610270578063d9bffbce146102af578063d9eb16db146102cf578063dd85582f146102ff578063e9d1e8ac1461034b575b600080fd5b3480156100d457600080fd5b506100e86100e3366004611323565b610387565b60405190151581526020015b60405180910390f35b34801561010957600080fd5b5061011d610118366004611340565b6103bf565b6040519081526020016100f4565b61011d610139366004611370565b6103d4565b34801561014a57600080fd5b5061011d610554565b34801561015f57600080fd5b5061017361016e3660046113b2565b610563565b005b34801561018157600080fd5b50610195610190366004611340565b6105f8565b6040805182511515815260209283015162ffffff1692810192909252016100f4565b3480156101c357600080fd5b506101d76101d2366004611340565b610640565b6040805182516001600160f81b03168152602092830151151592810192909252016100f4565b34801561020957600080fd5b506101736102183660046113f5565b61068e565b61011d61022b366004611340565b6106cd565b34801561023c57600080fd5b5061017361024b36600461140e565b6106da565b34801561025c57600080fd5b506100e861026b366004611340565b6106f0565b34801561027c57600080fd5b506102a260405180604001604052806006815260200165076302e302e360d41b81525081565b6040516100f4919061149d565b3480156102bb57600080fd5b506101736102ca366004611340565b6106fc565b3480156102db57600080fd5b506102ef6102ea366004611340565b610715565b6040516100f494939291906114b0565b34801561030b57600080fd5b506103337f000000000000000000000000000000000000000000000000000000000000000081565b6040516001600160a01b0390911681526020016100f4565b34801561035757600080fd5b506102a26040518060400160405280601081526020016f04d696e7465724d696e507269636556360841b81525081565b60008061039383610767565b8054909150610100900460ff16156103af575460ff1692915050565b6103b8836107a0565b9392505050565b60006103cb8383610916565b90505b92915050565b600060026000540361042d5760405162461bcd60e51b815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c0060448201526064015b60405180910390fd5b600260005561043c8383610936565b60006104488484610967565b9050803410156104935760405162461bcd60e51b815260206004820152601660248201527526b4b7103b30b63ab2903a379036b4b73a103932b89760511b6044820152606401610424565b6040516117cd60e21b81526001600160a01b0386811660048301526024820186905284811660448301523360648301527f00000000000000000000000000000000000000000000000000000000000000001690615f34906084016020604051808303816000875af115801561050c573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061053091906114ea565b915061053c82846109d7565b610547848285610a44565b5060016000559392505050565b600061055e610af9565b905090565b61056e838333610b09565b610576610af9565b816001600160f81b031610156105c65760405162461bcd60e51b81526020600482015260156024820152744f6e6c7920677465206d696e206d696e742066656560581b6044820152606401610424565b6105da8383836001600160f81b0316610b4e565b6105e48383610bad565b156105f3576105f38383610be0565b505050565b60408051808201909152600080825260208201526106168383610c7b565b60408051808201909152905460ff811615158252610100900462ffffff1660208201529392505050565b604080518082019091526000808252602082015261065e8383610cc6565b6040805180820190915290546001600160f81b0381168252600160f81b900460ff16151560208201529392505050565b6106c17f000000000000000000000000000000000000000000000000000000000000000033306350a7886560e11b610ced565b6106ca81610d42565b50565b60006103cb3384846103d4565b6106e5838333610b09565b6105f3838383610d89565b60006103cb8383610e5f565b610707828233610b09565b6107118282610be0565b5050565b60008060606000806107278787610cc6565b5460408051808201909152600381526208aa8960eb1b602082015260ff600160f81b830416996001600160f81b0390921698509650600095509350505050565b6001600160a01b031660009081527f69f22dd730b53ff235fa96b4306a31bef5dad48fe4bac28b1ceebbce14401b396020526040902090565b6040516000602482018190526044820181905290819060640160408051601f198184030181529181526020820180516001600160e01b0316638639415b60e01b1790525190915060009081906001600160a01b03861690610802908590611503565b600060405180830381855afa9150503d806000811461083d576040519150601f19603f3d011682016040523d82523d6000602084013e610842565b606091505b5091509150816108a25760405162461bcd60e51b815260206004820152602560248201527f6765745072696d617279526576656e756553706c69747328292063616c6c2066604482015264185a5b195960da1b6064820152608401610424565b805160c08190036108b95750600095945050505050565b80610100036108ce5750600195945050505050565b60405162461bcd60e51b815260206004820152601e60248201527f556e657870656374656420726576656e75652073706c697420627974657300006044820152606401610424565b6000806109238484610c7b565b54610100900462ffffff16949350505050565b60006109428383610c7b565b805490915060ff16156105f35760405162461bcd60e51b81526004016104249061151f565b6000806109748484610cc6565b8054909150600160f81b900460ff166109c65760405162461bcd60e51b8152602060048201526014602482015273141c9a58d9481b9bdd0818dbdb999a59dd5c995960621b6044820152606401610424565b546001600160f81b03169392505050565b60006109e283610e78565b905060006109f08284610c7b565b8054909150620f4240850660010190610100900462ffffff1680821115610a295760405162461bcd60e51b81526004016104249061151f565b808203610a3c57825460ff191660011783555b505050505050565b34156105f3576000610a568334611550565b90508015610ae857604051600090339083908381818185875af1925050503d8060008114610aa0576040519150601f19603f3d011682016040523d82523d6000602084013e610aa5565b606091505b5050905080610ae65760405162461bcd60e51b815260206004820152600d60248201526c1499599d5b990819985a5b1959609a1b6044820152606401610424565b505b610af3848484610e87565b50505050565b6000610b0361109c565b54919050565b610b148383836110c0565b6105f35760405162461bcd60e51b815260206004820152600b60248201526a13db9b1e48105c9d1a5cdd60aa1b6044820152606401610424565b6000610b5a8484610cc6565b600160f81b6001600160f81b03841617815560405190915082906001600160a01b0385169086907f98e99eae7ab1c56b5b882e049df69b522affbaa1a93afd3be411447a1606027890600090a450505050565b600080610bba8484610c7b565b8054909150610100900462ffffff16158015610bd85750805460ff16155b949350505050565b600080610bed8484611149565b915091506000610bfd8585610c7b565b9050610c08826111c7565b815460ff1962ffffff92909216610100029190911663ffffffff19909116178383141781556040516001600160a01b0385169086907f1c3e74a6c6fefbaeee166b031cd2016349c6c863d5188b67c9bbd0b0dcb2e23790610c6c9086815260200190565b60405180910390a35050505050565b60007f73e3af67f35f30fb72bbaaf6cc07b987364ed643c93ba201702e213464e877ee5b6001600160a01b039290921660009081526020928352604080822094825293909252502090565b60007efc986db700c71340c673de619c46ee721167fc4ea17804bb535c4c196aa7d7610c9f565b610cf98484848461122f565b610af35760405162461bcd60e51b815260206004820152601a60248201527913db9b1e48135a5b9d195c919a5b1d195c8810591b5a5b9050d360321b6044820152606401610424565b6000610d4c61109c565b8281556040518381529091507fe3595da100053125f59ccb164c0aadf2b9ad08a2ec6de1e706e0c7ca160416779060200160405180910390a15050565b600080610d968585611149565b91509150808362ffffff161115610dbf5760405162461bcd60e51b815260040161042490611571565b818362ffffff161015610de45760405162461bcd60e51b815260040161042490611571565b6000610df08686610c7b565b805462ffffff861685811463ffffffff19909216610100820260ff1916179190911782556040519081529091506001600160a01b0386169087907f1c3e74a6c6fefbaeee166b031cd2016349c6c863d5188b67c9bbd0b0dcb2e2379060200160405180910390a3505050505050565b600080610e6c8484610c7b565b5460ff16949350505050565b60006103ce620f4240836115a2565b81600003610e9457505050565b6000610e9f826112c0565b905060008115610f2a57604051638639415b60e01b815260048101869052602481018590526001600160a01b03841690638639415b9060440161010060405180830381865afa158015610ef6573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610f1a91906115c4565b50949650610fa395505050505050565b604051638639415b60e01b815260048101869052602481018590526001600160a01b03841690638639415b9060440160c060405180830381865afa158015610f76573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610f9a919061164c565b50929450505050505b6001600160a01b038116610ff95760405162461bcd60e51b815260206004820152601f60248201527f52656e6465722050726f76696465722061646472657373206e6f7420736574006044820152606401610424565b6000816001600160a01b03168560405160006040518083038185875af1925050503d8060008114611046576040519150601f19603f3d011682016040523d82523d6000602084013e61104b565b606091505b5050905080610a3c5760405162461bcd60e51b815260206004820152601e60248201527f52656e6465722050726f7669646572207061796d656e74206661696c656400006044820152606401610424565b7f6aab9ffc5cd1e167fd16093ec2dc9fad33c2d2de62ce5b9a1df3152d598e2f9390565b60405163a47d29cb60e01b8152600481018490526000906001600160a01b0384169063a47d29cb90602401602060405180830381865afa158015611108573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061112c91906116b5565b6001600160a01b0316826001600160a01b03161490509392505050565b604051630ea5613f60e01b81526004810183905260009081906001600160a01b03841690630ea5613f9060240160c060405180830381865afa158015611193573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906111b791906116e7565b5093989297509195505050505050565b600062ffffff82111561122b5760405162461bcd60e51b815260206004820152602660248201527f53616665436173743a2076616c756520646f65736e27742066697420696e203260448201526534206269747360d01b6064820152608401610424565b5090565b60405163230448b160e01b81526001600160a01b03848116600483015283811660248301526001600160e01b0319831660448301526000919086169063230448b1906064016020604051808303816000875af1158015611293573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906112b79190611746565b95945050505050565b6000806112cc83610767565b8054909150610100900460ff16156112e8575460ff1692915050565b60006112f3846107a0565b825481151561ffff1990911617610100179092555092915050565b6001600160a01b03811681146106ca57600080fd5b60006020828403121561133557600080fd5b81356103b88161130e565b6000806040838503121561135357600080fd5b8235915060208301356113658161130e565b809150509250929050565b60008060006060848603121561138557600080fd5b83356113908161130e565b92506020840135915060408401356113a78161130e565b809150509250925092565b6000806000606084860312156113c757600080fd5b8335925060208401356113d98161130e565b915060408401356001600160f81b03811681146113a757600080fd5b60006020828403121561140757600080fd5b5035919050565b60008060006060848603121561142357600080fd5b8335925060208401356114358161130e565b9150604084013562ffffff811681146113a757600080fd5b60005b83811015611468578181015183820152602001611450565b50506000910152565b6000815180845261148981602086016020860161144d565b601f01601f19169290920160200192915050565b6020815260006103cb6020830184611471565b84151581528360208201526080604082015260006114d16080830185611471565b905060018060a01b038316606083015295945050505050565b6000602082840312156114fc57600080fd5b5051919050565b6000825161151581846020870161144d565b9190910192915050565b60208082526017908201527613585e081a5b9d9bd8d85d1a5bdb9cc81c995858da1959604a1b604082015260600190565b818103818111156103ce57634e487b7160e01b600052601160045260246000fd5b602080825260179082015276496e76616c6964206d617820696e766f636174696f6e7360481b604082015260600190565b6000826115bf57634e487b7160e01b600052601260045260246000fd5b500490565b600080600080600080600080610100898b0312156115e157600080fd5b8851975060208901516115f38161130e565b60408a015160608b0151919850965061160b8161130e565b60808a015160a08b015191965094506116238161130e565b60c08a015160e08b0151919450925061163b8161130e565b809150509295985092959890939650565b60008060008060008060c0878903121561166557600080fd5b8651955060208701516116778161130e565b60408801516060890151919650945061168f8161130e565b608088015160a089015191945092506116a78161130e565b809150509295509295509295565b6000602082840312156116c757600080fd5b81516103b88161130e565b805180151581146116e257600080fd5b919050565b60008060008060008060c0878903121561170057600080fd5b8651955060208701519450611717604088016116d2565b9350611725606088016116d2565b92506080870151915061173a60a088016116d2565b90509295509295509295565b60006020828403121561175857600080fd5b6103cb826116d256fea2646970667358221220a3af31046c60b38ff997cffc95eeacf93ce3e0c2f31ae8f8c2787ccaa4a2f8ae64736f6c63430008130033", + "deployedBytecode": "0x6080604052600436106100c35760003560e01c806301000da7146100c85780634869f3df146100fd5780634e8d87871461012b578063542afda31461013e5780637e947f24146101535780639a94488a146101755780639b24c3c0146101b7578063a14f10ca146101fd578063ae77c2371461021d578063b000e33414610230578063cce7c90914610250578063d3ddabe614610270578063d9bffbce146102af578063d9eb16db146102cf578063dd85582f146102ff578063e9d1e8ac1461034b575b600080fd5b3480156100d457600080fd5b506100e86100e3366004611323565b610387565b60405190151581526020015b60405180910390f35b34801561010957600080fd5b5061011d610118366004611340565b6103bf565b6040519081526020016100f4565b61011d610139366004611370565b6103d4565b34801561014a57600080fd5b5061011d610554565b34801561015f57600080fd5b5061017361016e3660046113b2565b610563565b005b34801561018157600080fd5b50610195610190366004611340565b6105f8565b6040805182511515815260209283015162ffffff1692810192909252016100f4565b3480156101c357600080fd5b506101d76101d2366004611340565b610640565b6040805182516001600160f81b03168152602092830151151592810192909252016100f4565b34801561020957600080fd5b506101736102183660046113f5565b61068e565b61011d61022b366004611340565b6106cd565b34801561023c57600080fd5b5061017361024b36600461140e565b6106da565b34801561025c57600080fd5b506100e861026b366004611340565b6106f0565b34801561027c57600080fd5b506102a260405180604001604052806006815260200165076302e302e360d41b81525081565b6040516100f4919061149d565b3480156102bb57600080fd5b506101736102ca366004611340565b6106fc565b3480156102db57600080fd5b506102ef6102ea366004611340565b610715565b6040516100f494939291906114b0565b34801561030b57600080fd5b506103337f000000000000000000000000000000000000000000000000000000000000000081565b6040516001600160a01b0390911681526020016100f4565b34801561035757600080fd5b506102a26040518060400160405280601081526020016f04d696e7465724d696e507269636556360841b81525081565b60008061039383610767565b8054909150610100900460ff16156103af575460ff1692915050565b6103b8836107a0565b9392505050565b60006103cb8383610916565b90505b92915050565b600060026000540361042d5760405162461bcd60e51b815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c0060448201526064015b60405180910390fd5b600260005561043c8383610936565b60006104488484610967565b9050803410156104935760405162461bcd60e51b815260206004820152601660248201527526b4b7103b30b63ab2903a379036b4b73a103932b89760511b6044820152606401610424565b6040516117cd60e21b81526001600160a01b0386811660048301526024820186905284811660448301523360648301527f00000000000000000000000000000000000000000000000000000000000000001690615f34906084016020604051808303816000875af115801561050c573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061053091906114ea565b915061053c82846109d7565b610547848285610a44565b5060016000559392505050565b600061055e610af9565b905090565b61056e838333610b09565b610576610af9565b816001600160f81b031610156105c65760405162461bcd60e51b81526020600482015260156024820152744f6e6c7920677465206d696e206d696e742066656560581b6044820152606401610424565b6105da8383836001600160f81b0316610b4e565b6105e48383610bad565b156105f3576105f38383610be0565b505050565b60408051808201909152600080825260208201526106168383610c7b565b60408051808201909152905460ff811615158252610100900462ffffff1660208201529392505050565b604080518082019091526000808252602082015261065e8383610cc6565b6040805180820190915290546001600160f81b0381168252600160f81b900460ff16151560208201529392505050565b6106c17f000000000000000000000000000000000000000000000000000000000000000033306350a7886560e11b610ced565b6106ca81610d42565b50565b60006103cb3384846103d4565b6106e5838333610b09565b6105f3838383610d89565b60006103cb8383610e5f565b610707828233610b09565b6107118282610be0565b5050565b60008060606000806107278787610cc6565b5460408051808201909152600381526208aa8960eb1b602082015260ff600160f81b830416996001600160f81b0390921698509650600095509350505050565b6001600160a01b031660009081527f69f22dd730b53ff235fa96b4306a31bef5dad48fe4bac28b1ceebbce14401b396020526040902090565b6040516000602482018190526044820181905290819060640160408051601f198184030181529181526020820180516001600160e01b0316638639415b60e01b1790525190915060009081906001600160a01b03861690610802908590611503565b600060405180830381855afa9150503d806000811461083d576040519150601f19603f3d011682016040523d82523d6000602084013e610842565b606091505b5091509150816108a25760405162461bcd60e51b815260206004820152602560248201527f6765745072696d617279526576656e756553706c69747328292063616c6c2066604482015264185a5b195960da1b6064820152608401610424565b805160c08190036108b95750600095945050505050565b80610100036108ce5750600195945050505050565b60405162461bcd60e51b815260206004820152601e60248201527f556e657870656374656420726576656e75652073706c697420627974657300006044820152606401610424565b6000806109238484610c7b565b54610100900462ffffff16949350505050565b60006109428383610c7b565b805490915060ff16156105f35760405162461bcd60e51b81526004016104249061151f565b6000806109748484610cc6565b8054909150600160f81b900460ff166109c65760405162461bcd60e51b8152602060048201526014602482015273141c9a58d9481b9bdd0818dbdb999a59dd5c995960621b6044820152606401610424565b546001600160f81b03169392505050565b60006109e283610e78565b905060006109f08284610c7b565b8054909150620f4240850660010190610100900462ffffff1680821115610a295760405162461bcd60e51b81526004016104249061151f565b808203610a3c57825460ff191660011783555b505050505050565b34156105f3576000610a568334611550565b90508015610ae857604051600090339083908381818185875af1925050503d8060008114610aa0576040519150601f19603f3d011682016040523d82523d6000602084013e610aa5565b606091505b5050905080610ae65760405162461bcd60e51b815260206004820152600d60248201526c1499599d5b990819985a5b1959609a1b6044820152606401610424565b505b610af3848484610e87565b50505050565b6000610b0361109c565b54919050565b610b148383836110c0565b6105f35760405162461bcd60e51b815260206004820152600b60248201526a13db9b1e48105c9d1a5cdd60aa1b6044820152606401610424565b6000610b5a8484610cc6565b600160f81b6001600160f81b03841617815560405190915082906001600160a01b0385169086907f98e99eae7ab1c56b5b882e049df69b522affbaa1a93afd3be411447a1606027890600090a450505050565b600080610bba8484610c7b565b8054909150610100900462ffffff16158015610bd85750805460ff16155b949350505050565b600080610bed8484611149565b915091506000610bfd8585610c7b565b9050610c08826111c7565b815460ff1962ffffff92909216610100029190911663ffffffff19909116178383141781556040516001600160a01b0385169086907f1c3e74a6c6fefbaeee166b031cd2016349c6c863d5188b67c9bbd0b0dcb2e23790610c6c9086815260200190565b60405180910390a35050505050565b60007f73e3af67f35f30fb72bbaaf6cc07b987364ed643c93ba201702e213464e877ee5b6001600160a01b039290921660009081526020928352604080822094825293909252502090565b60007efc986db700c71340c673de619c46ee721167fc4ea17804bb535c4c196aa7d7610c9f565b610cf98484848461122f565b610af35760405162461bcd60e51b815260206004820152601a60248201527913db9b1e48135a5b9d195c919a5b1d195c8810591b5a5b9050d360321b6044820152606401610424565b6000610d4c61109c565b8281556040518381529091507fe3595da100053125f59ccb164c0aadf2b9ad08a2ec6de1e706e0c7ca160416779060200160405180910390a15050565b600080610d968585611149565b91509150808362ffffff161115610dbf5760405162461bcd60e51b815260040161042490611571565b818362ffffff161015610de45760405162461bcd60e51b815260040161042490611571565b6000610df08686610c7b565b805462ffffff861685811463ffffffff19909216610100820260ff1916179190911782556040519081529091506001600160a01b0386169087907f1c3e74a6c6fefbaeee166b031cd2016349c6c863d5188b67c9bbd0b0dcb2e2379060200160405180910390a3505050505050565b600080610e6c8484610c7b565b5460ff16949350505050565b60006103ce620f4240836115a2565b81600003610e9457505050565b6000610e9f826112c0565b905060008115610f2a57604051638639415b60e01b815260048101869052602481018590526001600160a01b03841690638639415b9060440161010060405180830381865afa158015610ef6573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610f1a91906115c4565b50949650610fa395505050505050565b604051638639415b60e01b815260048101869052602481018590526001600160a01b03841690638639415b9060440160c060405180830381865afa158015610f76573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610f9a919061164c565b50929450505050505b6001600160a01b038116610ff95760405162461bcd60e51b815260206004820152601f60248201527f52656e6465722050726f76696465722061646472657373206e6f7420736574006044820152606401610424565b6000816001600160a01b03168560405160006040518083038185875af1925050503d8060008114611046576040519150601f19603f3d011682016040523d82523d6000602084013e61104b565b606091505b5050905080610a3c5760405162461bcd60e51b815260206004820152601e60248201527f52656e6465722050726f7669646572207061796d656e74206661696c656400006044820152606401610424565b7f6aab9ffc5cd1e167fd16093ec2dc9fad33c2d2de62ce5b9a1df3152d598e2f9390565b60405163a47d29cb60e01b8152600481018490526000906001600160a01b0384169063a47d29cb90602401602060405180830381865afa158015611108573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061112c91906116b5565b6001600160a01b0316826001600160a01b03161490509392505050565b604051630ea5613f60e01b81526004810183905260009081906001600160a01b03841690630ea5613f9060240160c060405180830381865afa158015611193573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906111b791906116e7565b5093989297509195505050505050565b600062ffffff82111561122b5760405162461bcd60e51b815260206004820152602660248201527f53616665436173743a2076616c756520646f65736e27742066697420696e203260448201526534206269747360d01b6064820152608401610424565b5090565b60405163230448b160e01b81526001600160a01b03848116600483015283811660248301526001600160e01b0319831660448301526000919086169063230448b1906064016020604051808303816000875af1158015611293573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906112b79190611746565b95945050505050565b6000806112cc83610767565b8054909150610100900460ff16156112e8575460ff1692915050565b60006112f3846107a0565b825481151561ffff1990911617610100179092555092915050565b6001600160a01b03811681146106ca57600080fd5b60006020828403121561133557600080fd5b81356103b88161130e565b6000806040838503121561135357600080fd5b8235915060208301356113658161130e565b809150509250929050565b60008060006060848603121561138557600080fd5b83356113908161130e565b92506020840135915060408401356113a78161130e565b809150509250925092565b6000806000606084860312156113c757600080fd5b8335925060208401356113d98161130e565b915060408401356001600160f81b03811681146113a757600080fd5b60006020828403121561140757600080fd5b5035919050565b60008060006060848603121561142357600080fd5b8335925060208401356114358161130e565b9150604084013562ffffff811681146113a757600080fd5b60005b83811015611468578181015183820152602001611450565b50506000910152565b6000815180845261148981602086016020860161144d565b601f01601f19169290920160200192915050565b6020815260006103cb6020830184611471565b84151581528360208201526080604082015260006114d16080830185611471565b905060018060a01b038316606083015295945050505050565b6000602082840312156114fc57600080fd5b5051919050565b6000825161151581846020870161144d565b9190910192915050565b60208082526017908201527613585e081a5b9d9bd8d85d1a5bdb9cc81c995858da1959604a1b604082015260600190565b818103818111156103ce57634e487b7160e01b600052601160045260246000fd5b602080825260179082015276496e76616c6964206d617820696e766f636174696f6e7360481b604082015260600190565b6000826115bf57634e487b7160e01b600052601260045260246000fd5b500490565b600080600080600080600080610100898b0312156115e157600080fd5b8851975060208901516115f38161130e565b60408a015160608b0151919850965061160b8161130e565b60808a015160a08b015191965094506116238161130e565b60c08a015160e08b0151919450925061163b8161130e565b809150509295985092959890939650565b60008060008060008060c0878903121561166557600080fd5b8651955060208701516116778161130e565b60408801516060890151919650945061168f8161130e565b608088015160a089015191945092506116a78161130e565b809150509295509295509295565b6000602082840312156116c757600080fd5b81516103b88161130e565b805180151581146116e257600080fd5b919050565b60008060008060008060c0878903121561170057600080fd5b8651955060208701519450611717604088016116d2565b9350611725606088016116d2565b92506080870151915061173a60a088016116d2565b90509295509295509295565b60006020828403121561175857600080fd5b6103cb826116d256fea2646970667358221220a3af31046c60b38ff997cffc95eeacf93ce3e0c2f31ae8f8c2787ccaa4a2f8ae64736f6c63430008130033", + "linkReferences": {}, + "deployedLinkReferences": {} +} diff --git a/tests/e2e/seed/scripts/deploy.ts b/tests/e2e/seed/scripts/deploy.ts index 35fd46a1..e9ebe6a2 100644 --- a/tests/e2e/seed/scripts/deploy.ts +++ b/tests/e2e/seed/scripts/deploy.ts @@ -5,7 +5,7 @@ import { ethers } from "ethers"; // flagship import { GenArt721CoreV3__factory, - GenArt721CoreV3LibraryAddresses + GenArt721CoreV3LibraryAddresses, } from "../contracts/factories/GenArt721CoreV3__factory"; import { AdminACLV0__factory } from "../contracts/factories/AdminACLV0__factory"; import { PseudorandomAtomic__factory } from "../contracts/factories/PseudorandomAtomic__factory"; @@ -30,6 +30,7 @@ import { MinterRAMV0__factory } from "../contracts/factories/MinterRAMV0__factor import { MinterDAExpV5__factory } from "../contracts/factories/MinterDAExpV5__factory"; import { MinterDALinV5__factory } from "../contracts/factories/MinterDALinV5__factory"; import { MinterDAExpSettlementV3__factory } from "../contracts/factories/MinterDAExpSettlementV3__factory"; +import { MinterMinPriceV0__factory } from "../contracts/factories/MinterMinPriceV0__factory"; // splitter contracts import { SplitAtomicV0__factory } from "../contracts/factories/SplitAtomicV0__factory"; import { SplitAtomicFactoryV0__factory } from "../contracts/factories/SplitAtomicFactoryV0__factory"; @@ -84,7 +85,7 @@ async function main() { // fund artist wallet await deployer.sendTransaction({ to: artist.address, - value: ethers.utils.parseEther("50") + value: ethers.utils.parseEther("50"), }); ///////////////////////////////////////////////////////////////////////////// // SETUP ACCOUNTS ENDS HERE @@ -121,8 +122,8 @@ async function main() { subgraphConfig.adminACLV0Contracts = [ { - address: adminACLAddress - } + address: adminACLAddress, + }, ]; console.log(`Admin ACL deployed at ${adminACLAddress}`); @@ -137,10 +138,12 @@ async function main() { console.log( `BytecodeStorageReader deployed at ${bytecodeStorageReaderAddress}` ); - subgraphConfig.metadata.bytecodeStorageReaderAddress = bytecodeStorageReaderAddress; + subgraphConfig.metadata.bytecodeStorageReaderAddress = + bytecodeStorageReaderAddress; const linkLibraryAddresses: GenArt721CoreV3LibraryAddresses = { - "contracts/libs/v0.8.x/BytecodeStorageV1.sol:BytecodeStorageReader": bytecodeStorageReaderAddress + "contracts/libs/v0.8.x/BytecodeStorageV1.sol:BytecodeStorageReader": + bytecodeStorageReaderAddress, }; const genArt721CoreFactory = new GenArt721CoreV3__factory( @@ -157,10 +160,10 @@ async function main() { await genArt721Core.deployed(); const genArtV3SubgraphConfig = { - address: genArt721Core.address + address: genArt721Core.address, }; subgraphConfig.iGenArt721CoreContractV3_BaseContracts = [ - genArtV3SubgraphConfig + genArtV3SubgraphConfig, ]; subgraphConfig.ownableGenArt721CoreV3Contracts = [genArtV3SubgraphConfig]; subgraphConfig.iERC721GenArt721CoreV3Contracts = [genArtV3SubgraphConfig]; @@ -174,7 +177,8 @@ async function main() { await minterFilterAdminACL.deployed(); const minterFilterAdminACLAddress = minterFilterAdminACL.address; // record in metadata for future reference in tests - subgraphConfig.metadata.minterFilterAdminACLAddress = minterFilterAdminACLAddress.toString(); + subgraphConfig.metadata.minterFilterAdminACLAddress = + minterFilterAdminACLAddress.toString(); const coreRegistryFactory = new CoreRegistryV1__factory(deployer); const coreRegistry = await coreRegistryFactory.deploy(); @@ -186,8 +190,8 @@ async function main() { // @dev this key will be updated in a subsequent PR to be named engineRegistryContracts subgraphConfig.ICoreRegistryContracts = [ { - address: coreRegistryAddress - } + address: coreRegistryAddress, + }, ]; const minterFilterFactory = new MinterFilterV2__factory(deployer); @@ -200,8 +204,8 @@ async function main() { subgraphConfig.sharedMinterFilterContracts = [ { - address: minterFilter.address - } + address: minterFilter.address, + }, ]; // Deploy Minter Suite contracts. @@ -222,18 +226,18 @@ async function main() { console.log(`MinterSetPriceV5 deployed at ${minterSetPriceV5.address}`); subgraphConfig.genericMinterEventsLibContracts = [ { - address: minterSetPriceV5.address - } + address: minterSetPriceV5.address, + }, ]; subgraphConfig.setPriceLibContracts = [ { - address: minterSetPriceV5.address - } + address: minterSetPriceV5.address, + }, ]; subgraphConfig.maxInvocationsLibContracts = [ { - address: minterSetPriceV5.address - } + address: minterSetPriceV5.address, + }, ]; // @dev also deploy ERC20 set price minter @@ -248,18 +252,18 @@ async function main() { `MinterSetPriceERC20V5 deployed at ${minterSetPriceERC20V5.address}` ); subgraphConfig.genericMinterEventsLibContracts.push({ - address: minterSetPriceERC20V5.address + address: minterSetPriceERC20V5.address, }); subgraphConfig.splitFundsLibContracts = [ { - address: minterSetPriceERC20V5.address - } + address: minterSetPriceERC20V5.address, + }, ]; subgraphConfig.setPriceLibContracts.push({ - address: minterSetPriceERC20V5.address + address: minterSetPriceERC20V5.address, }); subgraphConfig.maxInvocationsLibContracts.push({ - address: minterSetPriceERC20V5.address + address: minterSetPriceERC20V5.address, }); // Merkle Minters @@ -273,18 +277,18 @@ async function main() { `MinterSetPriceMerkleV5 deployed at ${minterSetPriceMerkleV5.address}` ); subgraphConfig.genericMinterEventsLibContracts.push({ - address: minterSetPriceMerkleV5.address + address: minterSetPriceMerkleV5.address, }); subgraphConfig.setPriceLibContracts.push({ - address: minterSetPriceMerkleV5.address + address: minterSetPriceMerkleV5.address, }); subgraphConfig.maxInvocationsLibContracts.push({ - address: minterSetPriceMerkleV5.address + address: minterSetPriceMerkleV5.address, }); subgraphConfig.merkleLibContracts = [ { - address: minterSetPriceMerkleV5.address - } + address: minterSetPriceMerkleV5.address, + }, ]; // Holder Minters @@ -298,18 +302,18 @@ async function main() { `minterSetPriceHolderV5 deployed at ${minterSetPriceHolderV5.address}` ); subgraphConfig.genericMinterEventsLibContracts.push({ - address: minterSetPriceHolderV5.address + address: minterSetPriceHolderV5.address, }); subgraphConfig.setPriceLibContracts.push({ - address: minterSetPriceHolderV5.address + address: minterSetPriceHolderV5.address, }); subgraphConfig.maxInvocationsLibContracts.push({ - address: minterSetPriceHolderV5.address + address: minterSetPriceHolderV5.address, }); subgraphConfig.holderLibContracts = [ { - address: minterSetPriceHolderV5.address - } + address: minterSetPriceHolderV5.address, + }, ]; // SEA Minters @@ -318,15 +322,15 @@ async function main() { await minterSEAV1.deployed(); console.log(`minterSEAV1 deployed at ${minterSEAV1.address}`); subgraphConfig.genericMinterEventsLibContracts.push({ - address: minterSEAV1.address + address: minterSEAV1.address, }); subgraphConfig.maxInvocationsLibContracts.push({ - address: minterSEAV1.address + address: minterSEAV1.address, }); subgraphConfig.SEALibContracts = [ { - address: minterSEAV1.address - } + address: minterSEAV1.address, + }, ]; // RAM Minters @@ -335,15 +339,15 @@ async function main() { await minterRAMV0.deployed(); console.log(`minterRAMV0 deployed at ${minterRAMV0.address}`); subgraphConfig.genericMinterEventsLibContracts.push({ - address: minterRAMV0.address + address: minterRAMV0.address, }); subgraphConfig.maxInvocationsLibContracts.push({ - address: minterRAMV0.address + address: minterRAMV0.address, }); subgraphConfig.RAMLibContracts = [ { - address: minterRAMV0.address - } + address: minterRAMV0.address, + }, ]; // DA Exp Minters @@ -352,20 +356,20 @@ async function main() { await minterDAExpV5.deployed(); console.log(`minterDAExpV5 deployed at ${minterDAExpV5.address}`); subgraphConfig.genericMinterEventsLibContracts.push({ - address: minterDAExpV5.address + address: minterDAExpV5.address, }); subgraphConfig.maxInvocationsLibContracts.push({ - address: minterDAExpV5.address + address: minterDAExpV5.address, }); subgraphConfig.DALibContracts = [ { - address: minterDAExpV5.address - } + address: minterDAExpV5.address, + }, ]; subgraphConfig.DAExpLibContracts = [ { - address: minterDAExpV5.address - } + address: minterDAExpV5.address, + }, ]; // DA Lin Minters @@ -374,18 +378,18 @@ async function main() { await minterDALinV5.deployed(); console.log(`minterDALinV5 deployed at ${minterDALinV5.address}`); subgraphConfig.genericMinterEventsLibContracts.push({ - address: minterDALinV5.address + address: minterDALinV5.address, }); subgraphConfig.maxInvocationsLibContracts.push({ - address: minterDALinV5.address + address: minterDALinV5.address, }); subgraphConfig.DALibContracts.push({ - address: minterDALinV5.address + address: minterDALinV5.address, }); subgraphConfig.DALinLibContracts = [ { - address: minterDALinV5.address - } + address: minterDALinV5.address, + }, ]; // DA Exp Settlement Minters @@ -400,21 +404,45 @@ async function main() { `minterDAExpSettlementV3 deployed at ${minterDAExpSettlementV3.address}` ); subgraphConfig.genericMinterEventsLibContracts.push({ - address: minterDAExpSettlementV3.address + address: minterDAExpSettlementV3.address, }); subgraphConfig.maxInvocationsLibContracts.push({ - address: minterDAExpSettlementV3.address + address: minterDAExpSettlementV3.address, }); subgraphConfig.DALibContracts.push({ - address: minterDAExpSettlementV3.address + address: minterDAExpSettlementV3.address, }); subgraphConfig.DAExpLibContracts.push({ - address: minterDAExpSettlementV3.address + address: minterDAExpSettlementV3.address, }); subgraphConfig.settlementExpLibContracts = [ { - address: minterDAExpSettlementV3.address - } + address: minterDAExpSettlementV3.address, + }, + ]; + + // Min Price Minters + const MIN_MINT_FEE = ethers.utils.parseEther("0.1"); + const MinterMinPriceV0Factory = new MinterMinPriceV0__factory(deployer); + const minterMinPriceV0 = await MinterMinPriceV0Factory.deploy( + minterFilter.address, + MIN_MINT_FEE + ); + await minterMinPriceV0.deployed(); + console.log(`minterMinPriceV0 deployed at ${minterMinPriceV0.address}`); + subgraphConfig.genericMinterEventsLibContracts.push({ + address: minterMinPriceV0.address, + }); + subgraphConfig.maxInvocationsLibContracts.push({ + address: minterMinPriceV0.address, + }); + subgraphConfig.setPriceLibContracts.push({ + address: minterMinPriceV0.address, + }); + subgraphConfig.minPriceLibContracts = [ + { + address: minterMinPriceV0.address, + }, ]; // deploy splitAtomic system of contracts @@ -441,8 +469,8 @@ async function main() { // update subgraph config to index splitAtomicFactoryV0 subgraphConfig.iSplitAtomicFactoryV0Contracts = [ { - address: splitAtomicFactoryV0.address - } + address: splitAtomicFactoryV0.address, + }, ]; // update subgraph config metadata to include splitAtomic implementation address subgraphConfig.metadata.splitAtomicImplementationAddress = @@ -569,6 +597,12 @@ async function main() { console.log( `Allowlisted minterDAExpSettlementV3 ${minterDAExpSettlementV3.address} on minter filter.` ); + await minterFilter + .connect(deployer) + .approveMinterGlobally(minterMinPriceV0.address); + console.log( + `Allowlisted minterMinPriceV0 ${minterMinPriceV0.address} on minter filter.` + ); // add initial project to the core contract await genArt721Core @@ -608,7 +642,7 @@ async function main() { main() .then(() => process.exit(0)) - .catch(error => { + .catch((error) => { console.error(error); process.exit(1); }); diff --git a/tests/e2e/seed/supplemental_abis/MinterMinPriceV0.json b/tests/e2e/seed/supplemental_abis/MinterMinPriceV0.json new file mode 100644 index 00000000..bef8e4e7 --- /dev/null +++ b/tests/e2e/seed/supplemental_abis/MinterMinPriceV0.json @@ -0,0 +1,387 @@ +{ + "_format": "hh-sol-artifact-1", + "contractName": "MinterMinPriceV0", + "sourceName": "contracts/minter-suite/Minters/MinterMinPriceV0.sol", + "abi": [ + { + "inputs": [ + { + "internalType": "address", + "name": "minterFilter", + "type": "address" + }, + { + "internalType": "uint256", + "name": "minMintFee_", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "constructor" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "projectId", + "type": "uint256" + }, + { + "internalType": "address", + "name": "coreContract", + "type": "address" + } + ], + "name": "getPriceInfo", + "outputs": [ + { + "internalType": "bool", + "name": "isConfigured", + "type": "bool" + }, + { + "internalType": "uint256", + "name": "tokenPriceInWei", + "type": "uint256" + }, + { + "internalType": "string", + "name": "currencySymbol", + "type": "string" + }, + { + "internalType": "address", + "name": "currencyAddress", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "coreContract", + "type": "address" + } + ], + "name": "isEngineView", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "projectId", + "type": "uint256" + }, + { + "internalType": "address", + "name": "coreContract", + "type": "address" + }, + { + "internalType": "uint24", + "name": "maxInvocations", + "type": "uint24" + } + ], + "name": "manuallyLimitProjectMaxInvocations", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "projectId", + "type": "uint256" + }, + { + "internalType": "address", + "name": "coreContract", + "type": "address" + } + ], + "name": "maxInvocationsProjectConfig", + "outputs": [ + { + "components": [ + { + "internalType": "bool", + "name": "maxHasBeenInvoked", + "type": "bool" + }, + { + "internalType": "uint24", + "name": "maxInvocations", + "type": "uint24" + } + ], + "internalType": "struct MaxInvocationsLib.MaxInvocationsProjectConfig", + "name": "", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "minMintFee", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "minterFilterAddress", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "minterType", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "minterVersion", + "outputs": [ + { + "internalType": "string", + "name": "", + "type": "string" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "projectId", + "type": "uint256" + }, + { + "internalType": "address", + "name": "coreContract", + "type": "address" + } + ], + "name": "projectMaxHasBeenInvoked", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "projectId", + "type": "uint256" + }, + { + "internalType": "address", + "name": "coreContract", + "type": "address" + } + ], + "name": "projectMaxInvocations", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "projectId", + "type": "uint256" + }, + { + "internalType": "address", + "name": "coreContract", + "type": "address" + } + ], + "name": "purchase", + "outputs": [ + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + } + ], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "internalType": "uint256", + "name": "projectId", + "type": "uint256" + }, + { + "internalType": "address", + "name": "coreContract", + "type": "address" + } + ], + "name": "purchaseTo", + "outputs": [ + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + } + ], + "stateMutability": "payable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "projectId", + "type": "uint256" + }, + { + "internalType": "address", + "name": "coreContract", + "type": "address" + } + ], + "name": "setPriceProjectConfig", + "outputs": [ + { + "components": [ + { + "internalType": "uint248", + "name": "pricePerToken", + "type": "uint248" + }, + { + "internalType": "bool", + "name": "priceIsConfigured", + "type": "bool" + } + ], + "internalType": "struct SetPriceLib.SetPriceProjectConfig", + "name": "", + "type": "tuple" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "projectId", + "type": "uint256" + }, + { + "internalType": "address", + "name": "coreContract", + "type": "address" + } + ], + "name": "syncProjectMaxInvocationsToCore", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "newMinMintFee", + "type": "uint256" + } + ], + "name": "updateMinMintFee", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "projectId", + "type": "uint256" + }, + { + "internalType": "address", + "name": "coreContract", + "type": "address" + }, + { + "internalType": "uint248", + "name": "pricePerTokenInWei", + "type": "uint248" + } + ], + "name": "updatePricePerTokenInWei", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + } + ], + "bytecode": "0x60c060405234801561001057600080fd5b506040516118ae3803806118ae83398101604081905261002f916100b1565b60016000556001600160a01b038216608081905260a05261004f81610056565b50506100eb565b7f6aab9ffc5cd1e167fd16093ec2dc9fad33c2d2de62ce5b9a1df3152d598e2f938181556040805183815290517fe3595da100053125f59ccb164c0aadf2b9ad08a2ec6de1e706e0c7ca160416779181900360200190a15050565b600080604083850312156100c457600080fd5b82516001600160a01b03811681146100db57600080fd5b6020939093015192949293505050565b60805160a05161179761011760003960006104c5015260008181610311015261069301526117976000f3fe6080604052600436106100c35760003560e01c806301000da7146100c85780634869f3df146100fd5780634e8d87871461012b578063542afda31461013e5780637e947f24146101535780639a94488a146101755780639b24c3c0146101b7578063a14f10ca146101fd578063ae77c2371461021d578063b000e33414610230578063cce7c90914610250578063d3ddabe614610270578063d9bffbce146102af578063d9eb16db146102cf578063dd85582f146102ff578063e9d1e8ac1461034b575b600080fd5b3480156100d457600080fd5b506100e86100e3366004611323565b610387565b60405190151581526020015b60405180910390f35b34801561010957600080fd5b5061011d610118366004611340565b6103bf565b6040519081526020016100f4565b61011d610139366004611370565b6103d4565b34801561014a57600080fd5b5061011d610554565b34801561015f57600080fd5b5061017361016e3660046113b2565b610563565b005b34801561018157600080fd5b50610195610190366004611340565b6105f8565b6040805182511515815260209283015162ffffff1692810192909252016100f4565b3480156101c357600080fd5b506101d76101d2366004611340565b610640565b6040805182516001600160f81b03168152602092830151151592810192909252016100f4565b34801561020957600080fd5b506101736102183660046113f5565b61068e565b61011d61022b366004611340565b6106cd565b34801561023c57600080fd5b5061017361024b36600461140e565b6106da565b34801561025c57600080fd5b506100e861026b366004611340565b6106f0565b34801561027c57600080fd5b506102a260405180604001604052806006815260200165076302e302e360d41b81525081565b6040516100f4919061149d565b3480156102bb57600080fd5b506101736102ca366004611340565b6106fc565b3480156102db57600080fd5b506102ef6102ea366004611340565b610715565b6040516100f494939291906114b0565b34801561030b57600080fd5b506103337f000000000000000000000000000000000000000000000000000000000000000081565b6040516001600160a01b0390911681526020016100f4565b34801561035757600080fd5b506102a26040518060400160405280601081526020016f04d696e7465724d696e507269636556360841b81525081565b60008061039383610767565b8054909150610100900460ff16156103af575460ff1692915050565b6103b8836107a0565b9392505050565b60006103cb8383610916565b90505b92915050565b600060026000540361042d5760405162461bcd60e51b815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c0060448201526064015b60405180910390fd5b600260005561043c8383610936565b60006104488484610967565b9050803410156104935760405162461bcd60e51b815260206004820152601660248201527526b4b7103b30b63ab2903a379036b4b73a103932b89760511b6044820152606401610424565b6040516117cd60e21b81526001600160a01b0386811660048301526024820186905284811660448301523360648301527f00000000000000000000000000000000000000000000000000000000000000001690615f34906084016020604051808303816000875af115801561050c573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061053091906114ea565b915061053c82846109d7565b610547848285610a44565b5060016000559392505050565b600061055e610af9565b905090565b61056e838333610b09565b610576610af9565b816001600160f81b031610156105c65760405162461bcd60e51b81526020600482015260156024820152744f6e6c7920677465206d696e206d696e742066656560581b6044820152606401610424565b6105da8383836001600160f81b0316610b4e565b6105e48383610bad565b156105f3576105f38383610be0565b505050565b60408051808201909152600080825260208201526106168383610c7b565b60408051808201909152905460ff811615158252610100900462ffffff1660208201529392505050565b604080518082019091526000808252602082015261065e8383610cc6565b6040805180820190915290546001600160f81b0381168252600160f81b900460ff16151560208201529392505050565b6106c17f000000000000000000000000000000000000000000000000000000000000000033306350a7886560e11b610ced565b6106ca81610d42565b50565b60006103cb3384846103d4565b6106e5838333610b09565b6105f3838383610d89565b60006103cb8383610e5f565b610707828233610b09565b6107118282610be0565b5050565b60008060606000806107278787610cc6565b5460408051808201909152600381526208aa8960eb1b602082015260ff600160f81b830416996001600160f81b0390921698509650600095509350505050565b6001600160a01b031660009081527f69f22dd730b53ff235fa96b4306a31bef5dad48fe4bac28b1ceebbce14401b396020526040902090565b6040516000602482018190526044820181905290819060640160408051601f198184030181529181526020820180516001600160e01b0316638639415b60e01b1790525190915060009081906001600160a01b03861690610802908590611503565b600060405180830381855afa9150503d806000811461083d576040519150601f19603f3d011682016040523d82523d6000602084013e610842565b606091505b5091509150816108a25760405162461bcd60e51b815260206004820152602560248201527f6765745072696d617279526576656e756553706c69747328292063616c6c2066604482015264185a5b195960da1b6064820152608401610424565b805160c08190036108b95750600095945050505050565b80610100036108ce5750600195945050505050565b60405162461bcd60e51b815260206004820152601e60248201527f556e657870656374656420726576656e75652073706c697420627974657300006044820152606401610424565b6000806109238484610c7b565b54610100900462ffffff16949350505050565b60006109428383610c7b565b805490915060ff16156105f35760405162461bcd60e51b81526004016104249061151f565b6000806109748484610cc6565b8054909150600160f81b900460ff166109c65760405162461bcd60e51b8152602060048201526014602482015273141c9a58d9481b9bdd0818dbdb999a59dd5c995960621b6044820152606401610424565b546001600160f81b03169392505050565b60006109e283610e78565b905060006109f08284610c7b565b8054909150620f4240850660010190610100900462ffffff1680821115610a295760405162461bcd60e51b81526004016104249061151f565b808203610a3c57825460ff191660011783555b505050505050565b34156105f3576000610a568334611550565b90508015610ae857604051600090339083908381818185875af1925050503d8060008114610aa0576040519150601f19603f3d011682016040523d82523d6000602084013e610aa5565b606091505b5050905080610ae65760405162461bcd60e51b815260206004820152600d60248201526c1499599d5b990819985a5b1959609a1b6044820152606401610424565b505b610af3848484610e87565b50505050565b6000610b0361109c565b54919050565b610b148383836110c0565b6105f35760405162461bcd60e51b815260206004820152600b60248201526a13db9b1e48105c9d1a5cdd60aa1b6044820152606401610424565b6000610b5a8484610cc6565b600160f81b6001600160f81b03841617815560405190915082906001600160a01b0385169086907f98e99eae7ab1c56b5b882e049df69b522affbaa1a93afd3be411447a1606027890600090a450505050565b600080610bba8484610c7b565b8054909150610100900462ffffff16158015610bd85750805460ff16155b949350505050565b600080610bed8484611149565b915091506000610bfd8585610c7b565b9050610c08826111c7565b815460ff1962ffffff92909216610100029190911663ffffffff19909116178383141781556040516001600160a01b0385169086907f1c3e74a6c6fefbaeee166b031cd2016349c6c863d5188b67c9bbd0b0dcb2e23790610c6c9086815260200190565b60405180910390a35050505050565b60007f73e3af67f35f30fb72bbaaf6cc07b987364ed643c93ba201702e213464e877ee5b6001600160a01b039290921660009081526020928352604080822094825293909252502090565b60007efc986db700c71340c673de619c46ee721167fc4ea17804bb535c4c196aa7d7610c9f565b610cf98484848461122f565b610af35760405162461bcd60e51b815260206004820152601a60248201527913db9b1e48135a5b9d195c919a5b1d195c8810591b5a5b9050d360321b6044820152606401610424565b6000610d4c61109c565b8281556040518381529091507fe3595da100053125f59ccb164c0aadf2b9ad08a2ec6de1e706e0c7ca160416779060200160405180910390a15050565b600080610d968585611149565b91509150808362ffffff161115610dbf5760405162461bcd60e51b815260040161042490611571565b818362ffffff161015610de45760405162461bcd60e51b815260040161042490611571565b6000610df08686610c7b565b805462ffffff861685811463ffffffff19909216610100820260ff1916179190911782556040519081529091506001600160a01b0386169087907f1c3e74a6c6fefbaeee166b031cd2016349c6c863d5188b67c9bbd0b0dcb2e2379060200160405180910390a3505050505050565b600080610e6c8484610c7b565b5460ff16949350505050565b60006103ce620f4240836115a2565b81600003610e9457505050565b6000610e9f826112c0565b905060008115610f2a57604051638639415b60e01b815260048101869052602481018590526001600160a01b03841690638639415b9060440161010060405180830381865afa158015610ef6573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610f1a91906115c4565b50949650610fa395505050505050565b604051638639415b60e01b815260048101869052602481018590526001600160a01b03841690638639415b9060440160c060405180830381865afa158015610f76573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610f9a919061164c565b50929450505050505b6001600160a01b038116610ff95760405162461bcd60e51b815260206004820152601f60248201527f52656e6465722050726f76696465722061646472657373206e6f7420736574006044820152606401610424565b6000816001600160a01b03168560405160006040518083038185875af1925050503d8060008114611046576040519150601f19603f3d011682016040523d82523d6000602084013e61104b565b606091505b5050905080610a3c5760405162461bcd60e51b815260206004820152601e60248201527f52656e6465722050726f7669646572207061796d656e74206661696c656400006044820152606401610424565b7f6aab9ffc5cd1e167fd16093ec2dc9fad33c2d2de62ce5b9a1df3152d598e2f9390565b60405163a47d29cb60e01b8152600481018490526000906001600160a01b0384169063a47d29cb90602401602060405180830381865afa158015611108573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061112c91906116b5565b6001600160a01b0316826001600160a01b03161490509392505050565b604051630ea5613f60e01b81526004810183905260009081906001600160a01b03841690630ea5613f9060240160c060405180830381865afa158015611193573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906111b791906116e7565b5093989297509195505050505050565b600062ffffff82111561122b5760405162461bcd60e51b815260206004820152602660248201527f53616665436173743a2076616c756520646f65736e27742066697420696e203260448201526534206269747360d01b6064820152608401610424565b5090565b60405163230448b160e01b81526001600160a01b03848116600483015283811660248301526001600160e01b0319831660448301526000919086169063230448b1906064016020604051808303816000875af1158015611293573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906112b79190611746565b95945050505050565b6000806112cc83610767565b8054909150610100900460ff16156112e8575460ff1692915050565b60006112f3846107a0565b825481151561ffff1990911617610100179092555092915050565b6001600160a01b03811681146106ca57600080fd5b60006020828403121561133557600080fd5b81356103b88161130e565b6000806040838503121561135357600080fd5b8235915060208301356113658161130e565b809150509250929050565b60008060006060848603121561138557600080fd5b83356113908161130e565b92506020840135915060408401356113a78161130e565b809150509250925092565b6000806000606084860312156113c757600080fd5b8335925060208401356113d98161130e565b915060408401356001600160f81b03811681146113a757600080fd5b60006020828403121561140757600080fd5b5035919050565b60008060006060848603121561142357600080fd5b8335925060208401356114358161130e565b9150604084013562ffffff811681146113a757600080fd5b60005b83811015611468578181015183820152602001611450565b50506000910152565b6000815180845261148981602086016020860161144d565b601f01601f19169290920160200192915050565b6020815260006103cb6020830184611471565b84151581528360208201526080604082015260006114d16080830185611471565b905060018060a01b038316606083015295945050505050565b6000602082840312156114fc57600080fd5b5051919050565b6000825161151581846020870161144d565b9190910192915050565b60208082526017908201527613585e081a5b9d9bd8d85d1a5bdb9cc81c995858da1959604a1b604082015260600190565b818103818111156103ce57634e487b7160e01b600052601160045260246000fd5b602080825260179082015276496e76616c6964206d617820696e766f636174696f6e7360481b604082015260600190565b6000826115bf57634e487b7160e01b600052601260045260246000fd5b500490565b600080600080600080600080610100898b0312156115e157600080fd5b8851975060208901516115f38161130e565b60408a015160608b0151919850965061160b8161130e565b60808a015160a08b015191965094506116238161130e565b60c08a015160e08b0151919450925061163b8161130e565b809150509295985092959890939650565b60008060008060008060c0878903121561166557600080fd5b8651955060208701516116778161130e565b60408801516060890151919650945061168f8161130e565b608088015160a089015191945092506116a78161130e565b809150509295509295509295565b6000602082840312156116c757600080fd5b81516103b88161130e565b805180151581146116e257600080fd5b919050565b60008060008060008060c0878903121561170057600080fd5b8651955060208701519450611717604088016116d2565b9350611725606088016116d2565b92506080870151915061173a60a088016116d2565b90509295509295509295565b60006020828403121561175857600080fd5b6103cb826116d256fea2646970667358221220a3af31046c60b38ff997cffc95eeacf93ce3e0c2f31ae8f8c2787ccaa4a2f8ae64736f6c63430008130033", + "deployedBytecode": "0x6080604052600436106100c35760003560e01c806301000da7146100c85780634869f3df146100fd5780634e8d87871461012b578063542afda31461013e5780637e947f24146101535780639a94488a146101755780639b24c3c0146101b7578063a14f10ca146101fd578063ae77c2371461021d578063b000e33414610230578063cce7c90914610250578063d3ddabe614610270578063d9bffbce146102af578063d9eb16db146102cf578063dd85582f146102ff578063e9d1e8ac1461034b575b600080fd5b3480156100d457600080fd5b506100e86100e3366004611323565b610387565b60405190151581526020015b60405180910390f35b34801561010957600080fd5b5061011d610118366004611340565b6103bf565b6040519081526020016100f4565b61011d610139366004611370565b6103d4565b34801561014a57600080fd5b5061011d610554565b34801561015f57600080fd5b5061017361016e3660046113b2565b610563565b005b34801561018157600080fd5b50610195610190366004611340565b6105f8565b6040805182511515815260209283015162ffffff1692810192909252016100f4565b3480156101c357600080fd5b506101d76101d2366004611340565b610640565b6040805182516001600160f81b03168152602092830151151592810192909252016100f4565b34801561020957600080fd5b506101736102183660046113f5565b61068e565b61011d61022b366004611340565b6106cd565b34801561023c57600080fd5b5061017361024b36600461140e565b6106da565b34801561025c57600080fd5b506100e861026b366004611340565b6106f0565b34801561027c57600080fd5b506102a260405180604001604052806006815260200165076302e302e360d41b81525081565b6040516100f4919061149d565b3480156102bb57600080fd5b506101736102ca366004611340565b6106fc565b3480156102db57600080fd5b506102ef6102ea366004611340565b610715565b6040516100f494939291906114b0565b34801561030b57600080fd5b506103337f000000000000000000000000000000000000000000000000000000000000000081565b6040516001600160a01b0390911681526020016100f4565b34801561035757600080fd5b506102a26040518060400160405280601081526020016f04d696e7465724d696e507269636556360841b81525081565b60008061039383610767565b8054909150610100900460ff16156103af575460ff1692915050565b6103b8836107a0565b9392505050565b60006103cb8383610916565b90505b92915050565b600060026000540361042d5760405162461bcd60e51b815260206004820152601f60248201527f5265656e7472616e637947756172643a207265656e7472616e742063616c6c0060448201526064015b60405180910390fd5b600260005561043c8383610936565b60006104488484610967565b9050803410156104935760405162461bcd60e51b815260206004820152601660248201527526b4b7103b30b63ab2903a379036b4b73a103932b89760511b6044820152606401610424565b6040516117cd60e21b81526001600160a01b0386811660048301526024820186905284811660448301523360648301527f00000000000000000000000000000000000000000000000000000000000000001690615f34906084016020604051808303816000875af115801561050c573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061053091906114ea565b915061053c82846109d7565b610547848285610a44565b5060016000559392505050565b600061055e610af9565b905090565b61056e838333610b09565b610576610af9565b816001600160f81b031610156105c65760405162461bcd60e51b81526020600482015260156024820152744f6e6c7920677465206d696e206d696e742066656560581b6044820152606401610424565b6105da8383836001600160f81b0316610b4e565b6105e48383610bad565b156105f3576105f38383610be0565b505050565b60408051808201909152600080825260208201526106168383610c7b565b60408051808201909152905460ff811615158252610100900462ffffff1660208201529392505050565b604080518082019091526000808252602082015261065e8383610cc6565b6040805180820190915290546001600160f81b0381168252600160f81b900460ff16151560208201529392505050565b6106c17f000000000000000000000000000000000000000000000000000000000000000033306350a7886560e11b610ced565b6106ca81610d42565b50565b60006103cb3384846103d4565b6106e5838333610b09565b6105f3838383610d89565b60006103cb8383610e5f565b610707828233610b09565b6107118282610be0565b5050565b60008060606000806107278787610cc6565b5460408051808201909152600381526208aa8960eb1b602082015260ff600160f81b830416996001600160f81b0390921698509650600095509350505050565b6001600160a01b031660009081527f69f22dd730b53ff235fa96b4306a31bef5dad48fe4bac28b1ceebbce14401b396020526040902090565b6040516000602482018190526044820181905290819060640160408051601f198184030181529181526020820180516001600160e01b0316638639415b60e01b1790525190915060009081906001600160a01b03861690610802908590611503565b600060405180830381855afa9150503d806000811461083d576040519150601f19603f3d011682016040523d82523d6000602084013e610842565b606091505b5091509150816108a25760405162461bcd60e51b815260206004820152602560248201527f6765745072696d617279526576656e756553706c69747328292063616c6c2066604482015264185a5b195960da1b6064820152608401610424565b805160c08190036108b95750600095945050505050565b80610100036108ce5750600195945050505050565b60405162461bcd60e51b815260206004820152601e60248201527f556e657870656374656420726576656e75652073706c697420627974657300006044820152606401610424565b6000806109238484610c7b565b54610100900462ffffff16949350505050565b60006109428383610c7b565b805490915060ff16156105f35760405162461bcd60e51b81526004016104249061151f565b6000806109748484610cc6565b8054909150600160f81b900460ff166109c65760405162461bcd60e51b8152602060048201526014602482015273141c9a58d9481b9bdd0818dbdb999a59dd5c995960621b6044820152606401610424565b546001600160f81b03169392505050565b60006109e283610e78565b905060006109f08284610c7b565b8054909150620f4240850660010190610100900462ffffff1680821115610a295760405162461bcd60e51b81526004016104249061151f565b808203610a3c57825460ff191660011783555b505050505050565b34156105f3576000610a568334611550565b90508015610ae857604051600090339083908381818185875af1925050503d8060008114610aa0576040519150601f19603f3d011682016040523d82523d6000602084013e610aa5565b606091505b5050905080610ae65760405162461bcd60e51b815260206004820152600d60248201526c1499599d5b990819985a5b1959609a1b6044820152606401610424565b505b610af3848484610e87565b50505050565b6000610b0361109c565b54919050565b610b148383836110c0565b6105f35760405162461bcd60e51b815260206004820152600b60248201526a13db9b1e48105c9d1a5cdd60aa1b6044820152606401610424565b6000610b5a8484610cc6565b600160f81b6001600160f81b03841617815560405190915082906001600160a01b0385169086907f98e99eae7ab1c56b5b882e049df69b522affbaa1a93afd3be411447a1606027890600090a450505050565b600080610bba8484610c7b565b8054909150610100900462ffffff16158015610bd85750805460ff16155b949350505050565b600080610bed8484611149565b915091506000610bfd8585610c7b565b9050610c08826111c7565b815460ff1962ffffff92909216610100029190911663ffffffff19909116178383141781556040516001600160a01b0385169086907f1c3e74a6c6fefbaeee166b031cd2016349c6c863d5188b67c9bbd0b0dcb2e23790610c6c9086815260200190565b60405180910390a35050505050565b60007f73e3af67f35f30fb72bbaaf6cc07b987364ed643c93ba201702e213464e877ee5b6001600160a01b039290921660009081526020928352604080822094825293909252502090565b60007efc986db700c71340c673de619c46ee721167fc4ea17804bb535c4c196aa7d7610c9f565b610cf98484848461122f565b610af35760405162461bcd60e51b815260206004820152601a60248201527913db9b1e48135a5b9d195c919a5b1d195c8810591b5a5b9050d360321b6044820152606401610424565b6000610d4c61109c565b8281556040518381529091507fe3595da100053125f59ccb164c0aadf2b9ad08a2ec6de1e706e0c7ca160416779060200160405180910390a15050565b600080610d968585611149565b91509150808362ffffff161115610dbf5760405162461bcd60e51b815260040161042490611571565b818362ffffff161015610de45760405162461bcd60e51b815260040161042490611571565b6000610df08686610c7b565b805462ffffff861685811463ffffffff19909216610100820260ff1916179190911782556040519081529091506001600160a01b0386169087907f1c3e74a6c6fefbaeee166b031cd2016349c6c863d5188b67c9bbd0b0dcb2e2379060200160405180910390a3505050505050565b600080610e6c8484610c7b565b5460ff16949350505050565b60006103ce620f4240836115a2565b81600003610e9457505050565b6000610e9f826112c0565b905060008115610f2a57604051638639415b60e01b815260048101869052602481018590526001600160a01b03841690638639415b9060440161010060405180830381865afa158015610ef6573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610f1a91906115c4565b50949650610fa395505050505050565b604051638639415b60e01b815260048101869052602481018590526001600160a01b03841690638639415b9060440160c060405180830381865afa158015610f76573d6000803e3d6000fd5b505050506040513d601f19601f82011682018060405250810190610f9a919061164c565b50929450505050505b6001600160a01b038116610ff95760405162461bcd60e51b815260206004820152601f60248201527f52656e6465722050726f76696465722061646472657373206e6f7420736574006044820152606401610424565b6000816001600160a01b03168560405160006040518083038185875af1925050503d8060008114611046576040519150601f19603f3d011682016040523d82523d6000602084013e61104b565b606091505b5050905080610a3c5760405162461bcd60e51b815260206004820152601e60248201527f52656e6465722050726f7669646572207061796d656e74206661696c656400006044820152606401610424565b7f6aab9ffc5cd1e167fd16093ec2dc9fad33c2d2de62ce5b9a1df3152d598e2f9390565b60405163a47d29cb60e01b8152600481018490526000906001600160a01b0384169063a47d29cb90602401602060405180830381865afa158015611108573d6000803e3d6000fd5b505050506040513d601f19601f8201168201806040525081019061112c91906116b5565b6001600160a01b0316826001600160a01b03161490509392505050565b604051630ea5613f60e01b81526004810183905260009081906001600160a01b03841690630ea5613f9060240160c060405180830381865afa158015611193573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906111b791906116e7565b5093989297509195505050505050565b600062ffffff82111561122b5760405162461bcd60e51b815260206004820152602660248201527f53616665436173743a2076616c756520646f65736e27742066697420696e203260448201526534206269747360d01b6064820152608401610424565b5090565b60405163230448b160e01b81526001600160a01b03848116600483015283811660248301526001600160e01b0319831660448301526000919086169063230448b1906064016020604051808303816000875af1158015611293573d6000803e3d6000fd5b505050506040513d601f19601f820116820180604052508101906112b79190611746565b95945050505050565b6000806112cc83610767565b8054909150610100900460ff16156112e8575460ff1692915050565b60006112f3846107a0565b825481151561ffff1990911617610100179092555092915050565b6001600160a01b03811681146106ca57600080fd5b60006020828403121561133557600080fd5b81356103b88161130e565b6000806040838503121561135357600080fd5b8235915060208301356113658161130e565b809150509250929050565b60008060006060848603121561138557600080fd5b83356113908161130e565b92506020840135915060408401356113a78161130e565b809150509250925092565b6000806000606084860312156113c757600080fd5b8335925060208401356113d98161130e565b915060408401356001600160f81b03811681146113a757600080fd5b60006020828403121561140757600080fd5b5035919050565b60008060006060848603121561142357600080fd5b8335925060208401356114358161130e565b9150604084013562ffffff811681146113a757600080fd5b60005b83811015611468578181015183820152602001611450565b50506000910152565b6000815180845261148981602086016020860161144d565b601f01601f19169290920160200192915050565b6020815260006103cb6020830184611471565b84151581528360208201526080604082015260006114d16080830185611471565b905060018060a01b038316606083015295945050505050565b6000602082840312156114fc57600080fd5b5051919050565b6000825161151581846020870161144d565b9190910192915050565b60208082526017908201527613585e081a5b9d9bd8d85d1a5bdb9cc81c995858da1959604a1b604082015260600190565b818103818111156103ce57634e487b7160e01b600052601160045260246000fd5b602080825260179082015276496e76616c6964206d617820696e766f636174696f6e7360481b604082015260600190565b6000826115bf57634e487b7160e01b600052601260045260246000fd5b500490565b600080600080600080600080610100898b0312156115e157600080fd5b8851975060208901516115f38161130e565b60408a015160608b0151919850965061160b8161130e565b60808a015160a08b015191965094506116238161130e565b60c08a015160e08b0151919450925061163b8161130e565b809150509295985092959890939650565b60008060008060008060c0878903121561166557600080fd5b8651955060208701516116778161130e565b60408801516060890151919650945061168f8161130e565b608088015160a089015191945092506116a78161130e565b809150509295509295509295565b6000602082840312156116c757600080fd5b81516103b88161130e565b805180151581146116e257600080fd5b919050565b60008060008060008060c0878903121561170057600080fd5b8651955060208701519450611717604088016116d2565b9350611725606088016116d2565b92506080870151915061173a60a088016116d2565b90509295509295509295565b60006020828403121561175857600080fd5b6103cb826116d256fea2646970667358221220a3af31046c60b38ff997cffc95eeacf93ce3e0c2f31ae8f8c2787ccaa4a2f8ae64736f6c63430008130033", + "linkReferences": {}, + "deployedLinkReferences": {} +}