From 40b4615538f9a1f2b66871a7ebaa3761c6b1562f Mon Sep 17 00:00:00 2001 From: ixje Date: Tue, 8 Aug 2023 09:34:07 +0200 Subject: [PATCH] ci: actually fail if Black finds format issues (#277) --- .github/workflows/validate-pr-commit.yml | 2 +- neo3/api/noderpc.py | 5 ++++- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/.github/workflows/validate-pr-commit.yml b/.github/workflows/validate-pr-commit.yml index bc8bbef..2b476a8 100644 --- a/.github/workflows/validate-pr-commit.yml +++ b/.github/workflows/validate-pr-commit.yml @@ -54,7 +54,7 @@ jobs: - uses: actions/checkout@v3 - uses: psf/black@stable with: - options: '--target-version py310' + options: '--check --target-version py310' version: '22.8.0' src: "neo3/ examples/ tests/" type-checking: diff --git a/neo3/api/noderpc.py b/neo3/api/noderpc.py index d711c9c..1060591 100644 --- a/neo3/api/noderpc.py +++ b/neo3/api/noderpc.py @@ -1374,7 +1374,10 @@ async def wait_for_transaction_receipt( try: return await self.get_transaction_receipt(tx_hash) except JsonRpcError as e: - if "Unknown transaction" in e.message or "Unknown script container" in e.message: + if ( + "Unknown transaction" in e.message + or "Unknown script container" in e.message + ): await asyncio.sleep(retry_delay) else: raise e