Skip to content

Commit

Permalink
Only link code when utils contract is available
Browse files Browse the repository at this point in the history
This isn't true for older deployments, which made this crash.
  • Loading branch information
palango committed May 6, 2021
1 parent 7738725 commit 023ce57
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion raiden_contracts/deploy/contract_verifier.py
Original file line number Diff line number Diff line change
Expand Up @@ -203,7 +203,10 @@ def _verify_deployed_contract(
blockchain_bytecode = self.web3.eth.get_code(contract_instance.address).hex()
compiled_bytecode = self.contract_manager.get_runtime_hexcode(contract_name)

if contract_name == CONTRACT_TOKEN_NETWORK_REGISTRY:
if (
contract_name == CONTRACT_TOKEN_NETWORK_REGISTRY
and LIBRARY_TOKEN_NETWORK_UTILS in contracts
):
# We need to link the libs into the contract bytecode.
# As this is run in the tests in fake file systems, do poor mans linking here
compiled_bytecode = link_bytecode(
Expand Down

0 comments on commit 023ce57

Please sign in to comment.