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

bug: garaga declare cli command gives false positive error. #220

Open
feltroidprime opened this issue Oct 3, 2024 · 1 comment
Open
Assignees

Comments

@feltroidprime
Copy link
Collaborator

feltroidprime commented Oct 3, 2024

see #217

I have a snarkjs generated artifacts (verification_key.json, public_inputs.json, proof.json, etc).

I generate cairo contract using garaga gen --system groth16 --vk verification_key.json, which created 3 files, as expected, but when I trying to declare project (garaga declare-project --project-path my/project/path --env-file .secrets --network sepolia --fee strk), i get an error: class hash not found - deploying Error during declaration: Client failed with code 20. Message: Contract not found.

Im sure that path to project is correct. I didnt changed autogenerated cairo files too.

Thank you in advance.

there is an issue in the flow here, when the class hash doesn't exists it still declares it but an error is raised in python.

async def declare_class_hash(self, account: Account, fee="eth") -> int | None:

rich.print(f"[bold red]Error during declaration: {e}[/bold red]")

it seems the error is wrongly raised up to the calling function despite being caught 🤔

When running the command for a 2nd time, it correctly detects that the class hash exists and prints it.

@bruhhgnik
Copy link
Contributor

I'd be grateful to work on this @feltroidprime

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants