feat: improve codequality and CI (#25)

* feat: improve codequality and CI
This commit is contained in:
dni ⚡ 2024-08-30 13:20:23 +02:00 committed by GitHub
parent 28121184c3
commit cc6752003a
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
28 changed files with 3114 additions and 292 deletions

View file

@ -61,7 +61,7 @@ class EventValidator:
def _validate_event(self, e: NostrEvent) -> Tuple[bool, str]:
if self._exceeded_max_events_per_hour():
return False, f"Exceeded max events per hour limit'!"
return False, "Exceeded max events per hour limit'!"
try:
e.check_signature()
@ -101,7 +101,7 @@ class EventValidator:
if self.config.full_storage_action == "block":
return (
False,
f"Cannot write event, no more storage available for public key: '{pubkey}'",
f"Cannot write event, no storage available for public key: '{pubkey}'",
)
if event_size_bytes > total_available_storage: