Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added a try block around ABI loading for Foundry projects #11

Merged
merged 2 commits into from
Mar 8, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 5 additions & 3 deletions inspector_facet/abi.py
Original file line number Diff line number Diff line change
@@ -73,9 +73,11 @@ def foundry_project_abis(project_dir: str, build_dirname: None) -> Dict[str, Lis
with open(filepath, "r") as ifp:
contract_artifact = json.load(ifp)

contract_abi = contract_artifact.get("abi", [])

abis[contract_name] = contract_abi
try:
contract_abi = contract_artifact.get("abi", [])
abis[contract_name] = contract_abi
except Exception:
continue

return abis

2 changes: 1 addition & 1 deletion inspector_facet/version.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
0.3.0
0.3.1