$ ape --version
# 0.6.26
$ ape plugins list
# Installed Plugins
alchemy 0.6.5
etherscan 0.6.10
foundry 0.6.19
polygon 0.6.7
solidity 0.6.11
Python Version: 3.9.12
OS: macOS
What went wrong?
Please include information like:
what command you ran
ape run test --network polygon:mumbai:geth
the code that caused the failure (see this link for help with formatting code)
full output of the error you received
Traceback (most recent call last):
File "/Users/user/Downloads/ape-learn/venv/bin/ape", line 8, in
sys.exit(cli())
File "/Users/user/Downloads/ape-learn/venv/lib/python3.9/site-packages/click/core.py", line 1157, in call
return self.main(args, kwargs)
File "/Users/user/Downloads/ape-learn/venv/lib/python3.9/site-packages/click/core.py", line 1078, in main
rv = self.invoke(ctx)
File "/Users/user/Downloads/ape-learn/venv/lib/python3.9/site-packages/ape/_cli.py", line 37, in invoke
return super().invoke(ctx)
File "/Users/user/Downloads/ape-learn/venv/lib/python3.9/site-packages/click/core.py", line 1688, in invoke
return _process_result(sub_ctx.command.invoke(sub_ctx))
File "/Users/user/Downloads/ape-learn/venv/lib/python3.9/site-packages/ape_run/_cli.py", line 74, in invoke
return super().invoke(ctx)
File "/Users/user/Downloads/ape-learn/venv/lib/python3.9/site-packages/click/core.py", line 1688, in invoke
return _process_result(sub_ctx.command.invoke(sub_ctx))
File "/Users/user/Downloads/ape-learn/venv/lib/python3.9/site-packages/ape/cli/commands.py", line 29, in invoke
super().invoke(ctx)
File "/Users/user/Downloads/ape-learn/venv/lib/python3.9/site-packages/click/core.py", line 1434, in invoke
return ctx.invoke(self.callback, ctx.params)
File "/Users/user/Downloads/ape-learn/venv/lib/python3.9/site-packages/click/core.py", line 783, in invoke
return __callback(args, **kwargs)
File "/Users/user/Downloads/ape-learn/venv/lib/python3.9/site-packages/ape_run/_cli.py", line 148, in call
main_ns["main"]() # Execute the script
File "/Users/user/Downloads/ape-learn/scripts/test.py", line 19, in main
explorer.publish_contract(c)
File "/Users/user/Downloads/ape-learn/venv/lib/python3.9/site-packages/ape_etherscan/explorer.py", line 60, in publish_contract
return verifier.attempt_verification()
File "/Users/user/Downloads/ape-learn/venv/lib/python3.9/site-packages/ape_etherscan/verify.py", line 253, in attempt_verification
settings = all_settings[version]
KeyError: Version('0.8.13+commit.abaa5c0e')
How can it be fixed?
file: venv/lib/python3.9/site-packages/ape_etherscan/verify.py , line 250
compiler_plugin = self.compiler_manager.registered_compilers[self._ext]
all_settings = compiler_plugin.get_compiler_settings(
[self._source_path], base_path=self._base_path
) # version type from semantic_version import Version
settings = all_settings[version] # version type from packaging.version import Version
optimizer = settings.get("optimizer", {})
Environment information
ape
and plugin versions:What went wrong?
Please include information like:
what command you ran ape run test --network polygon:mumbai:geth
the code that caused the failure (see this link for help with formatting code)
full output of the error you received
Traceback (most recent call last): File "/Users/user/Downloads/ape-learn/venv/bin/ape", line 8, in
sys.exit(cli())
File "/Users/user/Downloads/ape-learn/venv/lib/python3.9/site-packages/click/core.py", line 1157, in call
return self.main(args, kwargs)
File "/Users/user/Downloads/ape-learn/venv/lib/python3.9/site-packages/click/core.py", line 1078, in main
rv = self.invoke(ctx)
File "/Users/user/Downloads/ape-learn/venv/lib/python3.9/site-packages/ape/_cli.py", line 37, in invoke
return super().invoke(ctx)
File "/Users/user/Downloads/ape-learn/venv/lib/python3.9/site-packages/click/core.py", line 1688, in invoke
return _process_result(sub_ctx.command.invoke(sub_ctx))
File "/Users/user/Downloads/ape-learn/venv/lib/python3.9/site-packages/ape_run/_cli.py", line 74, in invoke
return super().invoke(ctx)
File "/Users/user/Downloads/ape-learn/venv/lib/python3.9/site-packages/click/core.py", line 1688, in invoke
return _process_result(sub_ctx.command.invoke(sub_ctx))
File "/Users/user/Downloads/ape-learn/venv/lib/python3.9/site-packages/ape/cli/commands.py", line 29, in invoke
super().invoke(ctx)
File "/Users/user/Downloads/ape-learn/venv/lib/python3.9/site-packages/click/core.py", line 1434, in invoke
return ctx.invoke(self.callback, ctx.params)
File "/Users/user/Downloads/ape-learn/venv/lib/python3.9/site-packages/click/core.py", line 783, in invoke
return __callback(args, **kwargs)
File "/Users/user/Downloads/ape-learn/venv/lib/python3.9/site-packages/ape_run/_cli.py", line 148, in call
main_ns["main"]() # Execute the script
File "/Users/user/Downloads/ape-learn/scripts/test.py", line 19, in main
explorer.publish_contract(c)
File "/Users/user/Downloads/ape-learn/venv/lib/python3.9/site-packages/ape_etherscan/explorer.py", line 60, in publish_contract
return verifier.attempt_verification()
File "/Users/user/Downloads/ape-learn/venv/lib/python3.9/site-packages/ape_etherscan/verify.py", line 253, in attempt_verification
settings = all_settings[version]
KeyError: Version('0.8.13+commit.abaa5c0e')
How can it be fixed?
file: venv/lib/python3.9/site-packages/ape_etherscan/verify.py , line 250