Question says it all. I have a contract that I've written and compiled via Remix. I've dumped the ABI and Bytecode into local files, and I'm reading them into my python application. I'm following the documentation (https://web3py.readthedocs.io/en/stable/contracts.html) and trying to instantiate like:
mycontract = w3.eth.contract(abi=ABI,bytecode=BYTECODE)
where ABI is the copy-pasted abi from Remix, and the BYTECODE is the copy-pasted bytecode from Remix.
But I get a TypeError: Could not format value {'linkReferences': {}, 'object': '6080604...
I should mention that I can instantiate the contract the the same ABI and an address that the contract has been deployed to via Remix, and then successfully monitor the contract to log events. But what I would really like to do is deploy the contract from Python, using the locally stored abi and bytecode generated by Remix.
Currently, the "bytecode" that Remix provides is in a structure like this:
{
'linkReferences':[],
'object': '6080604052336000806...',
'opcodes': 'PUSH1 0x80...',
'sourcemap': '50:1984:0:-;;;2...'
}