lint: wrap long lines (E501), fix F841/F821/E731 — make check fully green

All 32 findings resolved: regex literals kept single-line with noqa
(pattern IS the reviewed artifact), HTML rows string-concatenated for
line length, walrus tuple in BIP-340 verify split into named generator,
unused pytest import dropped. No behavior changes; 44/44 tests pass.
Full-gate discipline restored: ruff exit 0.
This commit is contained in:
2026-10-19 22:03:53 +00:00
parent abbaf7e4e2
commit a282aedb94
7 changed files with 147 additions and 47 deletions
+4 -2
View File
@@ -28,7 +28,9 @@ def _item(channel="nostr", theme="atm-fees", scheduled=None, status=ContentStatu
def test_event_build_verify_roundtrip():
event = nostr.build_event(bytes.fromhex(TEST_KEY), "gm", tags=[["t", "bitcoin"]], created_at=1700000000)
event = nostr.build_event(
bytes.fromhex(TEST_KEY), "gm", tags=[["t", "bitcoin"]], created_at=1700000000
)
assert nostr.verify_event(event)
assert len(event["id"]) == 64 and len(event["sig"]) == 128
@@ -97,7 +99,7 @@ def test_publish_due_nostr_happy_path(cfg, sess):
assert item.status is ContentStatus.PUBLISHED
assert item.post_ref and len(item.post_ref) == 64
assert item.published_at is not None
assert "wss://relay.example.org" in relays_seen[0]
assert "wss://relay.example.org" in relays_seen[0] # noqa: E501
def test_future_scheduled_item_not_published(cfg, sess):