Skip to content

Commit 73d1dd9

Browse files
rustyconoverclaude
andcommitted
Fix lint/format issues and run CI lint before tests
- Fix ruff format in test_http.py - Use ternary for prefix auto-detection (SIM108) - Add needs: lint to test job so lint failures fail fast Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
1 parent 4abe669 commit 73d1dd9

3 files changed

Lines changed: 3 additions & 7 deletions

File tree

.github/workflows/ci.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ env:
1818
jobs:
1919
test:
2020
name: Python ${{ matrix.python-version }} on ${{ matrix.os }}
21+
needs: lint
2122
runs-on: ${{ matrix.os }}
2223
strategy:
2324
fail-fast: false

tests/test_http.py

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -78,9 +78,7 @@
7878
def client(request: pytest.FixtureRequest) -> Iterator[_SyncTestClient]:
7979
"""Create a sync Falcon test client with proper cleanup, tested with both empty and /vgi prefix."""
8080
prefix: str = request.param
81-
c = make_sync_client(
82-
RpcServer(RpcFixtureService, RpcFixtureServiceImpl()), signing_key=b"test-key", prefix=prefix
83-
)
81+
c = make_sync_client(RpcServer(RpcFixtureService, RpcFixtureServiceImpl()), signing_key=b"test-key", prefix=prefix)
8482
yield c
8583
c.close()
8684

vgi_rpc/http/_client.py

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -416,10 +416,7 @@ def http_connect[P](
416416
client = httpx.Client(base_url=base_url, follow_redirects=True)
417417

418418
# Auto-detect prefix from _SyncTestClient when not explicitly provided
419-
if prefix is None:
420-
url_prefix = getattr(client, "prefix", "")
421-
else:
422-
url_prefix = prefix
419+
url_prefix = getattr(client, "prefix", "") if prefix is None else prefix
423420
try:
424421
yield cast(
425422
P,

0 commit comments

Comments
 (0)