'Safe' object has no attribute 'get_contract'
mmv08 opened this issue · comments
Describe the bug
When trying to load the safe in a cli using safe-cli <checksummed_safe_address> <ethereum_node_url>
command, it fails with AttributeError: 'Safe' object has no attribute 'get_contract'
To Reproduce
- install the CLI
- try to load a safe
Expected behavior
The safe loads fine
Full output:
~/projects/gnosis/safe-cli-test ❯ safe-cli 0xc61b9bb3a7a0767e3179713f3a5c7a9aedce193c https://mainnet.infura.io/v3/951c70103a18411db3f8285df6acf372 9s Py safe-cli-test 09:49:02
Traceback (most recent call last):
File "/Users/mmv/projects/gnosis/safe-cli-test/venv/bin/safe-cli", line 8, in
sys.exit(main())
File "/Users/mmv/projects/gnosis/safe-cli-test/venv/lib/python3.9/site-packages/safe_cli/main.py", line 146, in main
safe_cli = SafeCli()
File "/Users/mmv/projects/gnosis/safe-cli-test/venv/lib/python3.9/site-packages/safe_cli/main.py", line 49, in init
self.safe_operator = SafeOperator(safe_address, node_url)
File "/Users/mmv/projects/gnosis/safe-cli-test/venv/lib/python3.9/site-packages/safe_cli/operators/safe_operator.py", line 199, in init
self.safe_contract = self.safe.get_contract()
AttributeError: 'Safe' object has no attribute 'get_contract'
I can see that this line is updated on master
: https://github.com/5afe/safe-cli/blob/master/safe_cli/operators/safe_operator.py#L194
Can it be that the updated version is not pushed to PyPI yet?
Makes sense, thanks @mikhailxyz, I prepared a new release https://github.com/5afe/safe-cli/releases/tag/v0.5.0