From 3ddfcfdab030bd270b40264223ae774ba9b8ebe7 Mon Sep 17 00:00:00 2001 From: Leo Arias Date: Thu, 7 Oct 2021 18:35:01 +0000 Subject: [PATCH 1/6] Classifiers: add 1inch Limit Order Protocol --- .../abis/1inch/1inchLimitOrderProtocol.json | 1000 +++++++++++++++++ mev_inspect/classifiers/specs/__init__.py | 2 + mev_inspect/classifiers/specs/one_inch.py | 37 + mev_inspect/schemas/traces.py | 1 + 4 files changed, 1040 insertions(+) create mode 100644 mev_inspect/abis/1inch/1inchLimitOrderProtocol.json create mode 100644 mev_inspect/classifiers/specs/one_inch.py diff --git a/mev_inspect/abis/1inch/1inchLimitOrderProtocol.json b/mev_inspect/abis/1inch/1inchLimitOrderProtocol.json new file mode 100644 index 00000000..15eba0fe --- /dev/null +++ b/mev_inspect/abis/1inch/1inchLimitOrderProtocol.json @@ -0,0 +1,1000 @@ +[ + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "maker", + "type": "address" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "newNonce", + "type": "uint256" + } + ], + "name": "NonceIncreased", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": true, + "internalType": "address", + "name": "maker", + "type": "address" + }, + { + "indexed": false, + "internalType": "bytes32", + "name": "orderHash", + "type": "bytes32" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "remaining", + "type": "uint256" + } + ], + "name": "OrderFilled", + "type": "event" + }, + { + "anonymous": false, + "inputs": [ + { + "indexed": false, + "internalType": "bytes32", + "name": "orderHash", + "type": "bytes32" + }, + { + "indexed": false, + "internalType": "uint256", + "name": "makingAmount", + "type": "uint256" + } + ], + "name": "OrderFilledRFQ", + "type": "event" + }, + { + "inputs": [], + "name": "DOMAIN_SEPARATOR", + "outputs": [ + { + "internalType": "bytes32", + "name": "", + "type": "bytes32" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "LIMIT_ORDER_RFQ_TYPEHASH", + "outputs": [ + { + "internalType": "bytes32", + "name": "", + "type": "bytes32" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "LIMIT_ORDER_TYPEHASH", + "outputs": [ + { + "internalType": "bytes32", + "name": "", + "type": "bytes32" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint8", + "name": "amount", + "type": "uint8" + } + ], + "name": "advanceNonce", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address[]", + "name": "targets", + "type": "address[]" + }, + { + "internalType": "bytes[]", + "name": "data", + "type": "bytes[]" + } + ], + "name": "and", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "target", + "type": "address" + }, + { + "internalType": "bytes", + "name": "data", + "type": "bytes" + } + ], + "name": "arbitraryStaticCall", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "uint256", + "name": "salt", + "type": "uint256" + }, + { + "internalType": "address", + "name": "makerAsset", + "type": "address" + }, + { + "internalType": "address", + "name": "takerAsset", + "type": "address" + }, + { + "internalType": "bytes", + "name": "makerAssetData", + "type": "bytes" + }, + { + "internalType": "bytes", + "name": "takerAssetData", + "type": "bytes" + }, + { + "internalType": "bytes", + "name": "getMakerAmount", + "type": "bytes" + }, + { + "internalType": "bytes", + "name": "getTakerAmount", + "type": "bytes" + }, + { + "internalType": "bytes", + "name": "predicate", + "type": "bytes" + }, + { + "internalType": "bytes", + "name": "permit", + "type": "bytes" + }, + { + "internalType": "bytes", + "name": "interaction", + "type": "bytes" + } + ], + "internalType": "struct LimitOrderProtocol.Order", + "name": "order", + "type": "tuple" + } + ], + "name": "cancelOrder", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "orderInfo", + "type": "uint256" + } + ], + "name": "cancelOrderRFQ", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "uint256", + "name": "salt", + "type": "uint256" + }, + { + "internalType": "address", + "name": "makerAsset", + "type": "address" + }, + { + "internalType": "address", + "name": "takerAsset", + "type": "address" + }, + { + "internalType": "bytes", + "name": "makerAssetData", + "type": "bytes" + }, + { + "internalType": "bytes", + "name": "takerAssetData", + "type": "bytes" + }, + { + "internalType": "bytes", + "name": "getMakerAmount", + "type": "bytes" + }, + { + "internalType": "bytes", + "name": "getTakerAmount", + "type": "bytes" + }, + { + "internalType": "bytes", + "name": "predicate", + "type": "bytes" + }, + { + "internalType": "bytes", + "name": "permit", + "type": "bytes" + }, + { + "internalType": "bytes", + "name": "interaction", + "type": "bytes" + } + ], + "internalType": "struct LimitOrderProtocol.Order", + "name": "order", + "type": "tuple" + } + ], + "name": "checkPredicate", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract AggregatorV3Interface", + "name": "oracle1", + "type": "address" + }, + { + "internalType": "contract AggregatorV3Interface", + "name": "oracle2", + "type": "address" + }, + { + "internalType": "uint256", + "name": "spread", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "doublePrice", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "value", + "type": "uint256" + }, + { + "internalType": "address", + "name": "target", + "type": "address" + }, + { + "internalType": "bytes", + "name": "data", + "type": "bytes" + } + ], + "name": "eq", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "uint256", + "name": "salt", + "type": "uint256" + }, + { + "internalType": "address", + "name": "makerAsset", + "type": "address" + }, + { + "internalType": "address", + "name": "takerAsset", + "type": "address" + }, + { + "internalType": "bytes", + "name": "makerAssetData", + "type": "bytes" + }, + { + "internalType": "bytes", + "name": "takerAssetData", + "type": "bytes" + }, + { + "internalType": "bytes", + "name": "getMakerAmount", + "type": "bytes" + }, + { + "internalType": "bytes", + "name": "getTakerAmount", + "type": "bytes" + }, + { + "internalType": "bytes", + "name": "predicate", + "type": "bytes" + }, + { + "internalType": "bytes", + "name": "permit", + "type": "bytes" + }, + { + "internalType": "bytes", + "name": "interaction", + "type": "bytes" + } + ], + "internalType": "struct LimitOrderProtocol.Order", + "name": "order", + "type": "tuple" + }, + { + "internalType": "bytes", + "name": "signature", + "type": "bytes" + }, + { + "internalType": "uint256", + "name": "makingAmount", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "takingAmount", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "thresholdAmount", + "type": "uint256" + } + ], + "name": "fillOrder", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "components": [ + { + "internalType": "uint256", + "name": "info", + "type": "uint256" + }, + { + "internalType": "address", + "name": "makerAsset", + "type": "address" + }, + { + "internalType": "address", + "name": "takerAsset", + "type": "address" + }, + { + "internalType": "bytes", + "name": "makerAssetData", + "type": "bytes" + }, + { + "internalType": "bytes", + "name": "takerAssetData", + "type": "bytes" + } + ], + "internalType": "struct LimitOrderProtocol.OrderRFQ", + "name": "order", + "type": "tuple" + }, + { + "internalType": "bytes", + "name": "signature", + "type": "bytes" + }, + { + "internalType": "uint256", + "name": "makingAmount", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "takingAmount", + "type": "uint256" + } + ], + "name": "fillOrderRFQ", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "from", + "type": "address" + }, + { + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + }, + { + "internalType": "contract IERC721", + "name": "token", + "type": "address" + } + ], + "name": "func_20xtkDI", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "from", + "type": "address" + }, + { + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + }, + { + "internalType": "contract IERC721", + "name": "token", + "type": "address" + } + ], + "name": "func_40aVqeY", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "from", + "type": "address" + }, + { + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + }, + { + "internalType": "contract IERC20", + "name": "token", + "type": "address" + } + ], + "name": "func_50BkM4K", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "from", + "type": "address" + }, + { + "internalType": "address", + "name": "to", + "type": "address" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + }, + { + "internalType": "contract IERC1155", + "name": "token", + "type": "address" + }, + { + "internalType": "uint256", + "name": "tokenId", + "type": "uint256" + }, + { + "internalType": "bytes", + "name": "data", + "type": "bytes" + } + ], + "name": "func_733NCGU", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "orderMakerAmount", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "orderTakerAmount", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "swapTakerAmount", + "type": "uint256" + } + ], + "name": "getMakerAmount", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "pure", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "orderMakerAmount", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "orderTakerAmount", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "swapMakerAmount", + "type": "uint256" + } + ], + "name": "getTakerAmount", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "pure", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "value", + "type": "uint256" + }, + { + "internalType": "address", + "name": "target", + "type": "address" + }, + { + "internalType": "bytes", + "name": "data", + "type": "bytes" + } + ], + "name": "gt", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "immutableOwner", + "outputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [], + "name": "increaseNonce", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "maker", + "type": "address" + }, + { + "internalType": "uint256", + "name": "slot", + "type": "uint256" + } + ], + "name": "invalidatorForOrderRFQ", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "value", + "type": "uint256" + }, + { + "internalType": "address", + "name": "target", + "type": "address" + }, + { + "internalType": "bytes", + "name": "data", + "type": "bytes" + } + ], + "name": "lt", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "", + "type": "address" + } + ], + "name": "nonce", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address", + "name": "makerAddress", + "type": "address" + }, + { + "internalType": "uint256", + "name": "makerNonce", + "type": "uint256" + } + ], + "name": "nonceEquals", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address[]", + "name": "targets", + "type": "address[]" + }, + { + "internalType": "bytes[]", + "name": "data", + "type": "bytes[]" + } + ], + "name": "or", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "bytes32", + "name": "orderHash", + "type": "bytes32" + } + ], + "name": "remaining", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "bytes32", + "name": "orderHash", + "type": "bytes32" + } + ], + "name": "remainingRaw", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "bytes32[]", + "name": "orderHashes", + "type": "bytes32[]" + } + ], + "name": "remainingsRaw", + "outputs": [ + { + "internalType": "uint256[]", + "name": "results", + "type": "uint256[]" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "address[]", + "name": "targets", + "type": "address[]" + }, + { + "internalType": "bytes[]", + "name": "data", + "type": "bytes[]" + } + ], + "name": "simulateCalls", + "outputs": [], + "stateMutability": "nonpayable", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "contract AggregatorV3Interface", + "name": "oracle", + "type": "address" + }, + { + "internalType": "uint256", + "name": "inverseAndSpread", + "type": "uint256" + }, + { + "internalType": "uint256", + "name": "amount", + "type": "uint256" + } + ], + "name": "singlePrice", + "outputs": [ + { + "internalType": "uint256", + "name": "", + "type": "uint256" + } + ], + "stateMutability": "view", + "type": "function" + }, + { + "inputs": [ + { + "internalType": "uint256", + "name": "time", + "type": "uint256" + } + ], + "name": "timestampBelow", + "outputs": [ + { + "internalType": "bool", + "name": "", + "type": "bool" + } + ], + "stateMutability": "view", + "type": "function" + } +] diff --git a/mev_inspect/classifiers/specs/__init__.py b/mev_inspect/classifiers/specs/__init__.py index 6d2b4e3b..0be49441 100644 --- a/mev_inspect/classifiers/specs/__init__.py +++ b/mev_inspect/classifiers/specs/__init__.py @@ -11,6 +11,8 @@ from .zero_ex import ZEROX_CLASSIFIER_SPECS from .balancer import BALANCER_CLASSIFIER_SPECS from .compound import COMPOUND_CLASSIFIER_SPECS +from .one_inch import ONE_INCH_CLASSIFIER_SPECS + ALL_CLASSIFIER_SPECS = ( ERC20_CLASSIFIER_SPECS diff --git a/mev_inspect/classifiers/specs/one_inch.py b/mev_inspect/classifiers/specs/one_inch.py new file mode 100644 index 00000000..7cb748f6 --- /dev/null +++ b/mev_inspect/classifiers/specs/one_inch.py @@ -0,0 +1,37 @@ +from mev_inspect.schemas.classified_traces import ( + DecodedCallTrace, + Protocol, +) +from mev_inspect.schemas.classifiers import ( + ClassifierSpec, + SwapClassifier, +) + + +class OneInchFillOrderProtocolSwapClassifier(SwapClassifier): + + @staticmethod + def get_swap_recipient(trace: DecodedCallTrace) -> str: + return trace.from_address + + +FILL_ORDER_SIGNATURE = ( + "fillOrder((uint256,address,address,bytes,bytes,bytes,bytes,bytes,bytes,bytes)," + "bytes,uint256,uint256,uint256)" +) + + +FILL_ORDER_SIGNATURE = ( + "fillOrder((uint256,address,address,bytes,bytes,bytes,bytes,bytes,bytes,bytes)," + "bytes,uint256,uint256,uint256)" +) + +ONE_INCH_LIMIT_ORDER_PROTOCOL_SPEC = ClassifierSpec( + abi_name="1inchLimitOrderProtocol", + protocol=Protocol.one_inch, + classifications={ + FILL_ORDER_SIGNATURE: OneInchFillOrderProtocolSwapClassifier, + }, +) + +ONE_INCH_CLASSIFIER_SPECS = [ONE_INCH_LIMIT_ORDER_PROTOCOL_SPEC] diff --git a/mev_inspect/schemas/traces.py b/mev_inspect/schemas/traces.py index faee340d..6b320f3b 100644 --- a/mev_inspect/schemas/traces.py +++ b/mev_inspect/schemas/traces.py @@ -44,6 +44,7 @@ class Protocol(Enum): balancer_v1 = "balancer_v1" compound_v2 = "compound_v2" cream = "cream" + one_inch = "1inch" class ClassifiedTrace(Trace): From a89382556ce7bfa5ae2d921990b325af2a6f8e44 Mon Sep 17 00:00:00 2001 From: Leo Arias Date: Mon, 18 Oct 2021 19:19:33 +0000 Subject: [PATCH 2/6] Flatten the json file --- .../abis/1inch/1inchLimitOrderProtocol.json | 1001 +---------------- 1 file changed, 1 insertion(+), 1000 deletions(-) diff --git a/mev_inspect/abis/1inch/1inchLimitOrderProtocol.json b/mev_inspect/abis/1inch/1inchLimitOrderProtocol.json index 15eba0fe..432f9fcd 100644 --- a/mev_inspect/abis/1inch/1inchLimitOrderProtocol.json +++ b/mev_inspect/abis/1inch/1inchLimitOrderProtocol.json @@ -1,1000 +1 @@ -[ - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "maker", - "type": "address" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "newNonce", - "type": "uint256" - } - ], - "name": "NonceIncreased", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": true, - "internalType": "address", - "name": "maker", - "type": "address" - }, - { - "indexed": false, - "internalType": "bytes32", - "name": "orderHash", - "type": "bytes32" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "remaining", - "type": "uint256" - } - ], - "name": "OrderFilled", - "type": "event" - }, - { - "anonymous": false, - "inputs": [ - { - "indexed": false, - "internalType": "bytes32", - "name": "orderHash", - "type": "bytes32" - }, - { - "indexed": false, - "internalType": "uint256", - "name": "makingAmount", - "type": "uint256" - } - ], - "name": "OrderFilledRFQ", - "type": "event" - }, - { - "inputs": [], - "name": "DOMAIN_SEPARATOR", - "outputs": [ - { - "internalType": "bytes32", - "name": "", - "type": "bytes32" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "LIMIT_ORDER_RFQ_TYPEHASH", - "outputs": [ - { - "internalType": "bytes32", - "name": "", - "type": "bytes32" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "LIMIT_ORDER_TYPEHASH", - "outputs": [ - { - "internalType": "bytes32", - "name": "", - "type": "bytes32" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint8", - "name": "amount", - "type": "uint8" - } - ], - "name": "advanceNonce", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address[]", - "name": "targets", - "type": "address[]" - }, - { - "internalType": "bytes[]", - "name": "data", - "type": "bytes[]" - } - ], - "name": "and", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "target", - "type": "address" - }, - { - "internalType": "bytes", - "name": "data", - "type": "bytes" - } - ], - "name": "arbitraryStaticCall", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "uint256", - "name": "salt", - "type": "uint256" - }, - { - "internalType": "address", - "name": "makerAsset", - "type": "address" - }, - { - "internalType": "address", - "name": "takerAsset", - "type": "address" - }, - { - "internalType": "bytes", - "name": "makerAssetData", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "takerAssetData", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "getMakerAmount", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "getTakerAmount", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "predicate", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "permit", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "interaction", - "type": "bytes" - } - ], - "internalType": "struct LimitOrderProtocol.Order", - "name": "order", - "type": "tuple" - } - ], - "name": "cancelOrder", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "orderInfo", - "type": "uint256" - } - ], - "name": "cancelOrderRFQ", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "uint256", - "name": "salt", - "type": "uint256" - }, - { - "internalType": "address", - "name": "makerAsset", - "type": "address" - }, - { - "internalType": "address", - "name": "takerAsset", - "type": "address" - }, - { - "internalType": "bytes", - "name": "makerAssetData", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "takerAssetData", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "getMakerAmount", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "getTakerAmount", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "predicate", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "permit", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "interaction", - "type": "bytes" - } - ], - "internalType": "struct LimitOrderProtocol.Order", - "name": "order", - "type": "tuple" - } - ], - "name": "checkPredicate", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "contract AggregatorV3Interface", - "name": "oracle1", - "type": "address" - }, - { - "internalType": "contract AggregatorV3Interface", - "name": "oracle2", - "type": "address" - }, - { - "internalType": "uint256", - "name": "spread", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "amount", - "type": "uint256" - } - ], - "name": "doublePrice", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "value", - "type": "uint256" - }, - { - "internalType": "address", - "name": "target", - "type": "address" - }, - { - "internalType": "bytes", - "name": "data", - "type": "bytes" - } - ], - "name": "eq", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "uint256", - "name": "salt", - "type": "uint256" - }, - { - "internalType": "address", - "name": "makerAsset", - "type": "address" - }, - { - "internalType": "address", - "name": "takerAsset", - "type": "address" - }, - { - "internalType": "bytes", - "name": "makerAssetData", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "takerAssetData", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "getMakerAmount", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "getTakerAmount", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "predicate", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "permit", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "interaction", - "type": "bytes" - } - ], - "internalType": "struct LimitOrderProtocol.Order", - "name": "order", - "type": "tuple" - }, - { - "internalType": "bytes", - "name": "signature", - "type": "bytes" - }, - { - "internalType": "uint256", - "name": "makingAmount", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "takingAmount", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "thresholdAmount", - "type": "uint256" - } - ], - "name": "fillOrder", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "components": [ - { - "internalType": "uint256", - "name": "info", - "type": "uint256" - }, - { - "internalType": "address", - "name": "makerAsset", - "type": "address" - }, - { - "internalType": "address", - "name": "takerAsset", - "type": "address" - }, - { - "internalType": "bytes", - "name": "makerAssetData", - "type": "bytes" - }, - { - "internalType": "bytes", - "name": "takerAssetData", - "type": "bytes" - } - ], - "internalType": "struct LimitOrderProtocol.OrderRFQ", - "name": "order", - "type": "tuple" - }, - { - "internalType": "bytes", - "name": "signature", - "type": "bytes" - }, - { - "internalType": "uint256", - "name": "makingAmount", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "takingAmount", - "type": "uint256" - } - ], - "name": "fillOrderRFQ", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "from", - "type": "address" - }, - { - "internalType": "address", - "name": "to", - "type": "address" - }, - { - "internalType": "uint256", - "name": "tokenId", - "type": "uint256" - }, - { - "internalType": "contract IERC721", - "name": "token", - "type": "address" - } - ], - "name": "func_20xtkDI", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "from", - "type": "address" - }, - { - "internalType": "address", - "name": "to", - "type": "address" - }, - { - "internalType": "uint256", - "name": "tokenId", - "type": "uint256" - }, - { - "internalType": "contract IERC721", - "name": "token", - "type": "address" - } - ], - "name": "func_40aVqeY", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "from", - "type": "address" - }, - { - "internalType": "address", - "name": "to", - "type": "address" - }, - { - "internalType": "uint256", - "name": "amount", - "type": "uint256" - }, - { - "internalType": "contract IERC20", - "name": "token", - "type": "address" - } - ], - "name": "func_50BkM4K", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "from", - "type": "address" - }, - { - "internalType": "address", - "name": "to", - "type": "address" - }, - { - "internalType": "uint256", - "name": "amount", - "type": "uint256" - }, - { - "internalType": "contract IERC1155", - "name": "token", - "type": "address" - }, - { - "internalType": "uint256", - "name": "tokenId", - "type": "uint256" - }, - { - "internalType": "bytes", - "name": "data", - "type": "bytes" - } - ], - "name": "func_733NCGU", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "orderMakerAmount", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "orderTakerAmount", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "swapTakerAmount", - "type": "uint256" - } - ], - "name": "getMakerAmount", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "pure", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "orderMakerAmount", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "orderTakerAmount", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "swapMakerAmount", - "type": "uint256" - } - ], - "name": "getTakerAmount", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "pure", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "value", - "type": "uint256" - }, - { - "internalType": "address", - "name": "target", - "type": "address" - }, - { - "internalType": "bytes", - "name": "data", - "type": "bytes" - } - ], - "name": "gt", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "immutableOwner", - "outputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [], - "name": "increaseNonce", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "maker", - "type": "address" - }, - { - "internalType": "uint256", - "name": "slot", - "type": "uint256" - } - ], - "name": "invalidatorForOrderRFQ", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "value", - "type": "uint256" - }, - { - "internalType": "address", - "name": "target", - "type": "address" - }, - { - "internalType": "bytes", - "name": "data", - "type": "bytes" - } - ], - "name": "lt", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "", - "type": "address" - } - ], - "name": "nonce", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address", - "name": "makerAddress", - "type": "address" - }, - { - "internalType": "uint256", - "name": "makerNonce", - "type": "uint256" - } - ], - "name": "nonceEquals", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address[]", - "name": "targets", - "type": "address[]" - }, - { - "internalType": "bytes[]", - "name": "data", - "type": "bytes[]" - } - ], - "name": "or", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "bytes32", - "name": "orderHash", - "type": "bytes32" - } - ], - "name": "remaining", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "bytes32", - "name": "orderHash", - "type": "bytes32" - } - ], - "name": "remainingRaw", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "bytes32[]", - "name": "orderHashes", - "type": "bytes32[]" - } - ], - "name": "remainingsRaw", - "outputs": [ - { - "internalType": "uint256[]", - "name": "results", - "type": "uint256[]" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "address[]", - "name": "targets", - "type": "address[]" - }, - { - "internalType": "bytes[]", - "name": "data", - "type": "bytes[]" - } - ], - "name": "simulateCalls", - "outputs": [], - "stateMutability": "nonpayable", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "contract AggregatorV3Interface", - "name": "oracle", - "type": "address" - }, - { - "internalType": "uint256", - "name": "inverseAndSpread", - "type": "uint256" - }, - { - "internalType": "uint256", - "name": "amount", - "type": "uint256" - } - ], - "name": "singlePrice", - "outputs": [ - { - "internalType": "uint256", - "name": "", - "type": "uint256" - } - ], - "stateMutability": "view", - "type": "function" - }, - { - "inputs": [ - { - "internalType": "uint256", - "name": "time", - "type": "uint256" - } - ], - "name": "timestampBelow", - "outputs": [ - { - "internalType": "bool", - "name": "", - "type": "bool" - } - ], - "stateMutability": "view", - "type": "function" - } -] +[{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"maker","type":"address"},{"indexed":false,"internalType":"uint256","name":"newNonce","type":"uint256"}],"name":"NonceIncreased","type":"event"},{"anonymous":false,"inputs":[{"indexed":true,"internalType":"address","name":"maker","type":"address"},{"indexed":false,"internalType":"bytes32","name":"orderHash","type":"bytes32"},{"indexed":false,"internalType":"uint256","name":"remaining","type":"uint256"}],"name":"OrderFilled","type":"event"},{"anonymous":false,"inputs":[{"indexed":false,"internalType":"bytes32","name":"orderHash","type":"bytes32"},{"indexed":false,"internalType":"uint256","name":"makingAmount","type":"uint256"}],"name":"OrderFilledRFQ","type":"event"},{"inputs":[],"name":"DOMAIN_SEPARATOR","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"LIMIT_ORDER_RFQ_TYPEHASH","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"LIMIT_ORDER_TYPEHASH","outputs":[{"internalType":"bytes32","name":"","type":"bytes32"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint8","name":"amount","type":"uint8"}],"name":"advanceNonce","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address[]","name":"targets","type":"address[]"},{"internalType":"bytes[]","name":"data","type":"bytes[]"}],"name":"and","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"target","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"arbitraryStaticCall","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"components":[{"internalType":"uint256","name":"salt","type":"uint256"},{"internalType":"address","name":"makerAsset","type":"address"},{"internalType":"address","name":"takerAsset","type":"address"},{"internalType":"bytes","name":"makerAssetData","type":"bytes"},{"internalType":"bytes","name":"takerAssetData","type":"bytes"},{"internalType":"bytes","name":"getMakerAmount","type":"bytes"},{"internalType":"bytes","name":"getTakerAmount","type":"bytes"},{"internalType":"bytes","name":"predicate","type":"bytes"},{"internalType":"bytes","name":"permit","type":"bytes"},{"internalType":"bytes","name":"interaction","type":"bytes"}],"internalType":"struct LimitOrderProtocol.Order","name":"order","type":"tuple"}],"name":"cancelOrder","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"orderInfo","type":"uint256"}],"name":"cancelOrderRFQ","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"components":[{"internalType":"uint256","name":"salt","type":"uint256"},{"internalType":"address","name":"makerAsset","type":"address"},{"internalType":"address","name":"takerAsset","type":"address"},{"internalType":"bytes","name":"makerAssetData","type":"bytes"},{"internalType":"bytes","name":"takerAssetData","type":"bytes"},{"internalType":"bytes","name":"getMakerAmount","type":"bytes"},{"internalType":"bytes","name":"getTakerAmount","type":"bytes"},{"internalType":"bytes","name":"predicate","type":"bytes"},{"internalType":"bytes","name":"permit","type":"bytes"},{"internalType":"bytes","name":"interaction","type":"bytes"}],"internalType":"struct LimitOrderProtocol.Order","name":"order","type":"tuple"}],"name":"checkPredicate","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"contract AggregatorV3Interface","name":"oracle1","type":"address"},{"internalType":"contract AggregatorV3Interface","name":"oracle2","type":"address"},{"internalType":"uint256","name":"spread","type":"uint256"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"doublePrice","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"value","type":"uint256"},{"internalType":"address","name":"target","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"eq","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"components":[{"internalType":"uint256","name":"salt","type":"uint256"},{"internalType":"address","name":"makerAsset","type":"address"},{"internalType":"address","name":"takerAsset","type":"address"},{"internalType":"bytes","name":"makerAssetData","type":"bytes"},{"internalType":"bytes","name":"takerAssetData","type":"bytes"},{"internalType":"bytes","name":"getMakerAmount","type":"bytes"},{"internalType":"bytes","name":"getTakerAmount","type":"bytes"},{"internalType":"bytes","name":"predicate","type":"bytes"},{"internalType":"bytes","name":"permit","type":"bytes"},{"internalType":"bytes","name":"interaction","type":"bytes"}],"internalType":"struct LimitOrderProtocol.Order","name":"order","type":"tuple"},{"internalType":"bytes","name":"signature","type":"bytes"},{"internalType":"uint256","name":"makingAmount","type":"uint256"},{"internalType":"uint256","name":"takingAmount","type":"uint256"},{"internalType":"uint256","name":"thresholdAmount","type":"uint256"}],"name":"fillOrder","outputs":[{"internalType":"uint256","name":"","type":"uint256"},{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"components":[{"internalType":"uint256","name":"info","type":"uint256"},{"internalType":"address","name":"makerAsset","type":"address"},{"internalType":"address","name":"takerAsset","type":"address"},{"internalType":"bytes","name":"makerAssetData","type":"bytes"},{"internalType":"bytes","name":"takerAssetData","type":"bytes"}],"internalType":"struct LimitOrderProtocol.OrderRFQ","name":"order","type":"tuple"},{"internalType":"bytes","name":"signature","type":"bytes"},{"internalType":"uint256","name":"makingAmount","type":"uint256"},{"internalType":"uint256","name":"takingAmount","type":"uint256"}],"name":"fillOrderRFQ","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"contract IERC721","name":"token","type":"address"}],"name":"func_20xtkDI","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"contract IERC721","name":"token","type":"address"}],"name":"func_40aVqeY","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"},{"internalType":"contract IERC20","name":"token","type":"address"}],"name":"func_50BkM4K","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"from","type":"address"},{"internalType":"address","name":"to","type":"address"},{"internalType":"uint256","name":"amount","type":"uint256"},{"internalType":"contract IERC1155","name":"token","type":"address"},{"internalType":"uint256","name":"tokenId","type":"uint256"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"func_733NCGU","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"uint256","name":"orderMakerAmount","type":"uint256"},{"internalType":"uint256","name":"orderTakerAmount","type":"uint256"},{"internalType":"uint256","name":"swapTakerAmount","type":"uint256"}],"name":"getMakerAmount","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"uint256","name":"orderMakerAmount","type":"uint256"},{"internalType":"uint256","name":"orderTakerAmount","type":"uint256"},{"internalType":"uint256","name":"swapMakerAmount","type":"uint256"}],"name":"getTakerAmount","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"pure","type":"function"},{"inputs":[{"internalType":"uint256","name":"value","type":"uint256"},{"internalType":"address","name":"target","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"gt","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"immutableOwner","outputs":[{"internalType":"address","name":"","type":"address"}],"stateMutability":"view","type":"function"},{"inputs":[],"name":"increaseNonce","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"address","name":"maker","type":"address"},{"internalType":"uint256","name":"slot","type":"uint256"}],"name":"invalidatorForOrderRFQ","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"value","type":"uint256"},{"internalType":"address","name":"target","type":"address"},{"internalType":"bytes","name":"data","type":"bytes"}],"name":"lt","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"","type":"address"}],"name":"nonce","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address","name":"makerAddress","type":"address"},{"internalType":"uint256","name":"makerNonce","type":"uint256"}],"name":"nonceEquals","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address[]","name":"targets","type":"address[]"},{"internalType":"bytes[]","name":"data","type":"bytes[]"}],"name":"or","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"orderHash","type":"bytes32"}],"name":"remaining","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32","name":"orderHash","type":"bytes32"}],"name":"remainingRaw","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"bytes32[]","name":"orderHashes","type":"bytes32[]"}],"name":"remainingsRaw","outputs":[{"internalType":"uint256[]","name":"results","type":"uint256[]"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"address[]","name":"targets","type":"address[]"},{"internalType":"bytes[]","name":"data","type":"bytes[]"}],"name":"simulateCalls","outputs":[],"stateMutability":"nonpayable","type":"function"},{"inputs":[{"internalType":"contract AggregatorV3Interface","name":"oracle","type":"address"},{"internalType":"uint256","name":"inverseAndSpread","type":"uint256"},{"internalType":"uint256","name":"amount","type":"uint256"}],"name":"singlePrice","outputs":[{"internalType":"uint256","name":"","type":"uint256"}],"stateMutability":"view","type":"function"},{"inputs":[{"internalType":"uint256","name":"time","type":"uint256"}],"name":"timestampBelow","outputs":[{"internalType":"bool","name":"","type":"bool"}],"stateMutability":"view","type":"function"}] From 04b7656653de5e1cdcae7dd7830f8ac7f5949683 Mon Sep 17 00:00:00 2001 From: Leo Arias Date: Mon, 18 Oct 2021 19:24:52 +0000 Subject: [PATCH 3/6] Add the classifier to the specs --- mev_inspect/classifiers/specs/__init__.py | 1 + 1 file changed, 1 insertion(+) diff --git a/mev_inspect/classifiers/specs/__init__.py b/mev_inspect/classifiers/specs/__init__.py index 0be49441..e1a3646a 100644 --- a/mev_inspect/classifiers/specs/__init__.py +++ b/mev_inspect/classifiers/specs/__init__.py @@ -23,6 +23,7 @@ + ZEROX_CLASSIFIER_SPECS + BALANCER_CLASSIFIER_SPECS + COMPOUND_CLASSIFIER_SPECS + + ONE_INCH_CLASSIFIER_SPECS ) _SPECS_BY_ABI_NAME_AND_PROTOCOL: Dict[ From d81ab7e4da3509c1df567042f8514a8825e4b1b9 Mon Sep 17 00:00:00 2001 From: Leo Arias Date: Mon, 18 Oct 2021 20:32:33 +0000 Subject: [PATCH 4/6] Run precommit --- mev_inspect/classifiers/specs/one_inch.py | 1 - 1 file changed, 1 deletion(-) diff --git a/mev_inspect/classifiers/specs/one_inch.py b/mev_inspect/classifiers/specs/one_inch.py index 7cb748f6..ccfbbe87 100644 --- a/mev_inspect/classifiers/specs/one_inch.py +++ b/mev_inspect/classifiers/specs/one_inch.py @@ -9,7 +9,6 @@ class OneInchFillOrderProtocolSwapClassifier(SwapClassifier): - @staticmethod def get_swap_recipient(trace: DecodedCallTrace) -> str: return trace.from_address From f6f817b8d976e28052d2f0ec54cfc27526284e20 Mon Sep 17 00:00:00 2001 From: Leo Arias Date: Tue, 2 Nov 2021 17:43:14 +0000 Subject: [PATCH 5/6] Update the import --- mev_inspect/classifiers/specs/one_inch.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mev_inspect/classifiers/specs/one_inch.py b/mev_inspect/classifiers/specs/one_inch.py index ccfbbe87..68963b08 100644 --- a/mev_inspect/classifiers/specs/one_inch.py +++ b/mev_inspect/classifiers/specs/one_inch.py @@ -1,4 +1,4 @@ -from mev_inspect.schemas.classified_traces import ( +from mev_inspect.schemas.traces import ( DecodedCallTrace, Protocol, ) From b7d688a07a8a0b885e4edd512c4a48cf306f6606 Mon Sep 17 00:00:00 2001 From: Leo Arias Date: Thu, 11 Nov 2021 17:28:32 +0000 Subject: [PATCH 6/6] Fix the spec merge --- mev_inspect/classifiers/specs/one_inch.py | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/mev_inspect/classifiers/specs/one_inch.py b/mev_inspect/classifiers/specs/one_inch.py index 68963b08..ba169840 100644 --- a/mev_inspect/classifiers/specs/one_inch.py +++ b/mev_inspect/classifiers/specs/one_inch.py @@ -20,15 +20,10 @@ def get_swap_recipient(trace: DecodedCallTrace) -> str: ) -FILL_ORDER_SIGNATURE = ( - "fillOrder((uint256,address,address,bytes,bytes,bytes,bytes,bytes,bytes,bytes)," - "bytes,uint256,uint256,uint256)" -) - ONE_INCH_LIMIT_ORDER_PROTOCOL_SPEC = ClassifierSpec( abi_name="1inchLimitOrderProtocol", protocol=Protocol.one_inch, - classifications={ + classifiers={ FILL_ORDER_SIGNATURE: OneInchFillOrderProtocolSwapClassifier, }, )