This fix addresses an issue where REQ messages with multiple filters were being rejected by the relay. Notably: The nostrmarket extension's "Refresh from Nostr" functionality sends a single REQ message containing 4 different filter subscriptions: - Direct Messages (kinds: [4]) - Stalls (kinds: [30017]) - Products (kinds: [30018]) - Profile (kinds: [0]) Changes: - Changed validation from `len(data) != 3` to `len(data) < 3` to allow multiple filters - Added loop to process all filters in a single REQ message (data[2:]) - Accumulate responses from all filters before returning This ensures compatibility with clients that batch multiple subscription filters in a single REQ message, which is a valid pattern according to NIP-01. |
||
|---|---|---|
| .. | ||
| __init__.py | ||
| client_connection.py | ||
| client_manager.py | ||
| event.py | ||
| event_validator.py | ||
| filter.py | ||
| relay.py | ||