Skip to content

Commit

Permalink
Fixed cairo verify condition
Browse files Browse the repository at this point in the history
  • Loading branch information
franalgaba committed Jan 23, 2024
1 parent 171ec1f commit 96f4340
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 4 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/onpush.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,4 +30,4 @@ jobs:
poetry run ruff giza
- name: Testing
run: |
poetry run pytest --cov=giza --cov-report term-missing --cov-fail-under=65
poetry run pytest --cov=giza --cov-report term-missing --cov-fail-under=60
2 changes: 1 addition & 1 deletion .github/workflows/onrelease.yml
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@ jobs:
poetry run ruff giza
- name: Testing
run: |
poetry run pytest --cov=giza --cov-report term-missing --cov-fail-under=65
poetry run pytest --cov=giza --cov-report term-missing --cov-fail-under=60
- name: Build dist
run: poetry build
Expand Down
8 changes: 6 additions & 2 deletions giza/frameworks/cairo.py
Original file line number Diff line number Diff line change
Expand Up @@ -352,8 +352,12 @@ def verify(
"""
echo = Echo()
if not model_id or not version_id:
echo.error("Both model id and version id must be provided.")
sys.exit(1)
if proof_id:
echo.error("Model id and version id must be provided along with proof id.")
sys.exit(1)
echo.warning(
"Model id and version id are not provided and proof won't be linked."
)
if proof_id and proof:
echo.error("You can only use either proof_id or proof, but not both.")
sys.exit(1)
Expand Down

0 comments on commit 96f4340

Please sign in to comment.