2024-04-28 20:27:25 -05:00
|
|
|
{
|
|
|
|
"_format": "hh-sol-artifact-1",
|
|
|
|
"contractName": "Rollup",
|
|
|
|
"sourceName": "contracts/Rollup.sol",
|
|
|
|
"abi": [
|
|
|
|
{
|
|
|
|
"inputs": [
|
|
|
|
{
|
|
|
|
"internalType": "contract DAO",
|
|
|
|
"name": "dao",
|
|
|
|
"type": "address"
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"stateMutability": "nonpayable",
|
|
|
|
"type": "constructor"
|
|
|
|
},
|
2024-05-01 22:24:53 -05:00
|
|
|
{
|
|
|
|
"inputs": [
|
|
|
|
{
|
|
|
|
"internalType": "address",
|
|
|
|
"name": "dao",
|
|
|
|
"type": "address"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"internalType": "address",
|
|
|
|
"name": "sender",
|
|
|
|
"type": "address"
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"name": "InvalidSender",
|
|
|
|
"type": "error"
|
|
|
|
},
|
2024-04-28 20:27:25 -05:00
|
|
|
{
|
|
|
|
"anonymous": false,
|
|
|
|
"inputs": [
|
|
|
|
{
|
|
|
|
"indexed": false,
|
|
|
|
"internalType": "uint256",
|
|
|
|
"name": "stakeIndex",
|
|
|
|
"type": "uint256"
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"name": "AvailabilityStaked",
|
|
|
|
"type": "event"
|
|
|
|
},
|
2024-05-01 22:24:53 -05:00
|
|
|
{
|
|
|
|
"anonymous": false,
|
|
|
|
"inputs": [
|
|
|
|
{
|
|
|
|
"indexed": false,
|
|
|
|
"internalType": "string",
|
|
|
|
"name": "postId",
|
|
|
|
"type": "string"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"indexed": false,
|
|
|
|
"internalType": "address",
|
|
|
|
"name": "sender",
|
|
|
|
"type": "address"
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"name": "BatchItemAdded",
|
|
|
|
"type": "event"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"anonymous": false,
|
|
|
|
"inputs": [
|
|
|
|
{
|
|
|
|
"indexed": false,
|
|
|
|
"internalType": "address",
|
|
|
|
"name": "batchWorker",
|
|
|
|
"type": "address"
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"name": "BatchWorkerAssigned",
|
|
|
|
"type": "event"
|
|
|
|
},
|
2024-04-28 20:27:25 -05:00
|
|
|
{
|
|
|
|
"inputs": [
|
|
|
|
{
|
|
|
|
"internalType": "address",
|
|
|
|
"name": "sender",
|
|
|
|
"type": "address"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"internalType": "uint256",
|
|
|
|
"name": "amount",
|
|
|
|
"type": "uint256"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"internalType": "uint256",
|
|
|
|
"name": "duration",
|
|
|
|
"type": "uint256"
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"name": "acceptAvailability",
|
|
|
|
"outputs": [],
|
|
|
|
"stateMutability": "nonpayable",
|
|
|
|
"type": "function"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"inputs": [
|
|
|
|
{
|
|
|
|
"internalType": "address",
|
|
|
|
"name": "author",
|
|
|
|
"type": "address"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"internalType": "uint256",
|
|
|
|
"name": "stakeAmount",
|
|
|
|
"type": "uint256"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"internalType": "string",
|
|
|
|
"name": "postId",
|
|
|
|
"type": "string"
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"name": "addItem",
|
|
|
|
"outputs": [],
|
|
|
|
"stateMutability": "payable",
|
|
|
|
"type": "function"
|
|
|
|
},
|
2024-05-01 22:24:53 -05:00
|
|
|
{
|
|
|
|
"inputs": [],
|
|
|
|
"name": "batchWorker",
|
|
|
|
"outputs": [
|
|
|
|
{
|
|
|
|
"internalType": "address",
|
|
|
|
"name": "",
|
|
|
|
"type": "address"
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"stateMutability": "view",
|
|
|
|
"type": "function"
|
|
|
|
},
|
2024-04-28 20:27:25 -05:00
|
|
|
{
|
|
|
|
"inputs": [
|
|
|
|
{
|
|
|
|
"internalType": "uint256",
|
|
|
|
"name": "stakeIndex",
|
|
|
|
"type": "uint256"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"internalType": "uint256",
|
|
|
|
"name": "duration",
|
|
|
|
"type": "uint256"
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"name": "extendAvailability",
|
|
|
|
"outputs": [],
|
|
|
|
"stateMutability": "nonpayable",
|
|
|
|
"type": "function"
|
|
|
|
},
|
2024-05-01 22:24:53 -05:00
|
|
|
{
|
|
|
|
"inputs": [],
|
|
|
|
"name": "itemCount",
|
|
|
|
"outputs": [
|
|
|
|
{
|
|
|
|
"internalType": "uint256",
|
|
|
|
"name": "",
|
|
|
|
"type": "uint256"
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"stateMutability": "view",
|
|
|
|
"type": "function"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"inputs": [
|
|
|
|
{
|
|
|
|
"internalType": "uint256",
|
|
|
|
"name": "",
|
|
|
|
"type": "uint256"
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"name": "items",
|
|
|
|
"outputs": [
|
|
|
|
{
|
|
|
|
"internalType": "address",
|
|
|
|
"name": "sender",
|
|
|
|
"type": "address"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"internalType": "address",
|
|
|
|
"name": "worker",
|
|
|
|
"type": "address"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"internalType": "uint256",
|
|
|
|
"name": "stakeAmount",
|
|
|
|
"type": "uint256"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"internalType": "uint256",
|
|
|
|
"name": "fee",
|
|
|
|
"type": "uint256"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"internalType": "string",
|
|
|
|
"name": "postId",
|
|
|
|
"type": "string"
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"stateMutability": "view",
|
|
|
|
"type": "function"
|
|
|
|
},
|
2024-04-28 20:27:25 -05:00
|
|
|
{
|
|
|
|
"inputs": [],
|
|
|
|
"name": "stakeCount",
|
|
|
|
"outputs": [
|
|
|
|
{
|
|
|
|
"internalType": "uint256",
|
|
|
|
"name": "",
|
|
|
|
"type": "uint256"
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"stateMutability": "view",
|
|
|
|
"type": "function"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"inputs": [
|
|
|
|
{
|
|
|
|
"internalType": "uint256",
|
|
|
|
"name": "",
|
|
|
|
"type": "uint256"
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"name": "stakes",
|
|
|
|
"outputs": [
|
|
|
|
{
|
|
|
|
"internalType": "address",
|
|
|
|
"name": "worker",
|
|
|
|
"type": "address"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"internalType": "uint256",
|
|
|
|
"name": "amount",
|
|
|
|
"type": "uint256"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"internalType": "uint256",
|
|
|
|
"name": "endTime",
|
|
|
|
"type": "uint256"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"internalType": "bool",
|
|
|
|
"name": "assigned",
|
|
|
|
"type": "bool"
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"stateMutability": "view",
|
|
|
|
"type": "function"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"inputs": [
|
|
|
|
{
|
|
|
|
"internalType": "string",
|
|
|
|
"name": "batchPostId",
|
|
|
|
"type": "string"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"internalType": "uint256",
|
|
|
|
"name": "batchSize",
|
|
|
|
"type": "uint256"
|
|
|
|
},
|
|
|
|
{
|
|
|
|
"internalType": "uint256",
|
|
|
|
"name": "poolDuration",
|
|
|
|
"type": "uint256"
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"name": "submitBatch",
|
|
|
|
"outputs": [
|
|
|
|
{
|
|
|
|
"internalType": "uint256",
|
|
|
|
"name": "poolIndex",
|
|
|
|
"type": "uint256"
|
|
|
|
}
|
|
|
|
],
|
|
|
|
"stateMutability": "nonpayable",
|
|
|
|
"type": "function"
|
|
|
|
}
|
|
|
|
],
|
2024-05-01 22:24:53 -05:00
|
|
|
"bytecode": "0x60a06040523480156200001157600080fd5b50604051620022dc380380620022dc8339818101604052810190620000379190620000f4565b80808073ffffffffffffffffffffffffffffffffffffffff1660808173ffffffffffffffffffffffffffffffffffffffff168152505050505062000126565b600080fd5b600073ffffffffffffffffffffffffffffffffffffffff82169050919050565b6000620000a8826200007b565b9050919050565b6000620000bc826200009b565b9050919050565b620000ce81620000af565b8114620000da57600080fd5b50565b600081519050620000ee81620000c3565b92915050565b6000602082840312156200010d576200010c62000076565b5b60006200011d84828501620000dd565b91505092915050565b608051612177620001656000396000818161023a015281816102c80152818161031b015281816108ff015281816109e80152610b2a01526121776000f3fe6080604052600436106100865760003560e01c8063bfb231d211610059578063bfb231d214610133578063c4a9e11614610174578063d5a44f861461019f578063da553ec2146101df578063f85c5a8a1461021c57610086565b8063216ed6ad1461008b57806324364a6b146100b45780636bfb0d01146100df578063b5b20c001461010a575b600080fd5b34801561009757600080fd5b506100b260048036038101906100ad91906111ee565b610238565b005b3480156100c057600080fd5b506100c961048a565b6040516100d69190611250565b60405180910390f35b3480156100eb57600080fd5b506100f46104b0565b604051610101919061127a565b60405180910390f35b34801561011657600080fd5b50610131600480360381019061012c9190611295565b6104b6565b005b34801561013f57600080fd5b5061015a600480360381019061015591906112d5565b61062a565b60405161016b959493929190611392565b60405180910390f35b34801561018057600080fd5b50610189610728565b604051610196919061127a565b60405180910390f35b3480156101ab57600080fd5b506101c660048036038101906101c191906112d5565b61072e565b6040516101d69493929190611407565b60405180910390f35b3480156101eb57600080fd5b50610206600480360381019061020191906114b1565b61078b565b604051610213919061127a565b60405180910390f35b61023660048036038101906102319190611525565b610e59565b005b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16146102c6576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016102bd9061160b565b60405180910390fd5b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614610378577f0000000000000000000000000000000000000000000000000000000000000000336040517fe1130dba00000000000000000000000000000000000000000000000000000000815260040161036f92919061162b565b60405180910390fd5b600082116103bb576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016103b2906116a0565b60405180910390fd5b6000600160008154809291906103d0906116ef565b91905055905060008060008381526020019081526020016000209050848160000160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555083816001018190555082426104449190611737565b81600201819055507fa85b1153cd317f9d39e14d8dbfb592ffb46123e9fc61b21b3f70d7d90a81a7e98260405161047b919061127a565b60405180910390a15050505050565b600460009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b60035481565b600080600084815260200190815260200160002090508060000160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff161461055e576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610555906117dd565b60405180910390fd5b8060030160009054906101000a900460ff16156105b0576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016105a79061186f565b60405180910390fd5b80600201544211156105d55781426105c89190611737565b81600201819055506105ee565b8181600201546105e59190611737565b81600201819055505b7fa85b1153cd317f9d39e14d8dbfb592ffb46123e9fc61b21b3f70d7d90a81a7e98360405161061d919061127a565b60405180910390a1505050565b60026020528060005260406000206000915090508060000160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16908060010160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff169080600201549080
|
|
|
|
"deployedBytecode": "0x6080604052600436106100865760003560e01c8063bfb231d211610059578063bfb231d214610133578063c4a9e11614610174578063d5a44f861461019f578063da553ec2146101df578063f85c5a8a1461021c57610086565b8063216ed6ad1461008b57806324364a6b146100b45780636bfb0d01146100df578063b5b20c001461010a575b600080fd5b34801561009757600080fd5b506100b260048036038101906100ad91906111ee565b610238565b005b3480156100c057600080fd5b506100c961048a565b6040516100d69190611250565b60405180910390f35b3480156100eb57600080fd5b506100f46104b0565b604051610101919061127a565b60405180910390f35b34801561011657600080fd5b50610131600480360381019061012c9190611295565b6104b6565b005b34801561013f57600080fd5b5061015a600480360381019061015591906112d5565b61062a565b60405161016b959493929190611392565b60405180910390f35b34801561018057600080fd5b50610189610728565b604051610196919061127a565b60405180910390f35b3480156101ab57600080fd5b506101c660048036038101906101c191906112d5565b61072e565b6040516101d69493929190611407565b60405180910390f35b3480156101eb57600080fd5b50610206600480360381019061020191906114b1565b61078b565b604051610213919061127a565b60405180910390f35b61023660048036038101906102319190611525565b610e59565b005b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff16146102c6576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016102bd9061160b565b60405180910390fd5b7f000000000000000000000000000000000000000000000000000000000000000073ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff1614610378577f0000000000000000000000000000000000000000000000000000000000000000336040517fe1130dba00000000000000000000000000000000000000000000000000000000815260040161036f92919061162b565b60405180910390fd5b600082116103bb576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016103b2906116a0565b60405180910390fd5b6000600160008154809291906103d0906116ef565b91905055905060008060008381526020019081526020016000209050848160000160006101000a81548173ffffffffffffffffffffffffffffffffffffffff021916908373ffffffffffffffffffffffffffffffffffffffff16021790555083816001018190555082426104449190611737565b81600201819055507fa85b1153cd317f9d39e14d8dbfb592ffb46123e9fc61b21b3f70d7d90a81a7e98260405161047b919061127a565b60405180910390a15050505050565b600460009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1681565b60035481565b600080600084815260200190815260200160002090508060000160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff1673ffffffffffffffffffffffffffffffffffffffff163373ffffffffffffffffffffffffffffffffffffffff161461055e576040517f08c379a0000000000000000000000000000000000000000000000000000000008152600401610555906117dd565b60405180910390fd5b8060030160009054906101000a900460ff16156105b0576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016105a79061186f565b60405180910390fd5b80600201544211156105d55781426105c89190611737565b81600201819055506105ee565b8181600201546105e59190611737565b81600201819055505b7fa85b1153cd317f9d39e14d8dbfb592ffb46123e9fc61b21b3f70d7d90a81a7e98360405161061d919061127a565b60405180910390a1505050565b60026020528060005260406000206000915090508060000160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16908060010160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16908060020154908060030154908060040180546106a5906118be565b80601f01602080910402602001604051908101604052809291908181526020018280546106d1906118be565b801561071e5780601f106106f35761010080835404028352916020019161071e565b820191906000526020600020905b81548152906001019060200180831161070157829003601f168201915b5050505050905085565b60015481565b60006020528060005260406000206000915090508060000160009054906101000a900473ffffffffffffffffffffffffffffffffffffffff16908060010154908060020154908060030160009054906101000a900460ff16905084565b60006003548311156107d2576040517f08c379a00000000000000000000000000000000000000000000000000000000081526004016107c99061193b565b60405180910390fd5b600073ffffffffffffffffffffffffffffffffffffffff166004600090549061
|
2024-04-28 20:27:25 -05:00
|
|
|
"linkReferences": {},
|
|
|
|
"deployedLinkReferences": {}
|
|
|
|
}
|