810 Commits

Author SHA1 Message Date
fiatjaf
85c964be3d enableReconnect() always update the filters to the time of the last received event on each subscription. v2.19.1 2025-12-05 13:24:49 -03:00
fiatjaf
de7d459f6f only transform filters with enableReconnect() when we're actually reconnecting. v2.19.0 2025-12-05 09:22:33 -03:00
fiatjaf
21ec5bb2dc allow automatically performing AUTH against all relays. 2025-12-05 09:12:59 -03:00
fiatjaf
e959409c14 fix classifyKind() test. v2.18.2 2025-11-25 22:21:46 -03:00
fiatjaf
8a76c4e329 fix normalizeUrl to make websocket urls out of http urls. 2025-11-25 22:20:38 -03:00
fiatjaf
34a1d8db47 kinds: more reliable regular/replaceable kind figuring. v2.18.1 2025-11-24 20:08:15 -03:00
fiatjaf
d3ddd490c2 nip27: test emoji behavior when no tags. 2025-11-22 22:23:03 -03:00
fiatjaf
7730e321a5 nip27: support more image, audio and video extensions. 2025-11-22 20:36:04 -03:00
fiatjaf
400d132612 nip77: negentropy tests and small fixes. v2.18.0 2025-11-21 19:51:55 -03:00
fiatjaf
01880b6fb5 nip27: parse emoji shortcodes and hashtags too. 2025-11-21 00:37:40 -03:00
fiatjaf
e87ffc433c build "core" although we shouldn't. 2025-11-21 00:37:40 -03:00
fiatjaf
c45e861493 fire subscriptions.
this was broken during the negentropy stuff.

fixes https://github.com/nbd-wtf/nostr-tools/issues/517
v2.17.4
2025-11-19 14:53:24 -03:00
fiatjaf
66cc55c7f0 nip77: negentropy implementation and nip77 interface.
supersedes https://github.com/nbd-wtf/nostr-tools/pull/516
v2.17.3
2025-11-18 09:33:11 -03:00
fiatjaf
5841b0936b throw when subscription is created without filters.
fixes https://github.com/nbd-wtf/nostr-tools/pull/497
2025-11-18 08:09:45 -03:00
max-gy
f5d0c0eb0f fix prettier checks on nip77 related *ts files 2025-11-18 08:06:26 -03:00
max-gy
e19db61bec nip77: adds wrapper for negentropy and fallback for yieldThread MessageChannel 2025-11-18 08:06:26 -03:00
Chris McCormick
1e0f393268 Fix subscribeMap EOSE grouping. Fixes #514 v2.17.2 2025-10-29 08:18:49 -03:00
Chris McCormick
1bec9fa365 Ping pong memory leak fix for #511 (#512)
* New test for pingpong memory leak (failing).

* Shim once in relay ping mem test.

* Fix pong memory leak with .once.

Fixes #511.

* Fix missing global WebSocket on Node.

* Lint fix.

* Remove overkill WebSocket impl check.
v2.17.1
2025-10-26 23:33:38 -03:00
雪猫
e8927d78e6 nip57: lud16 must take precedence over lud06 2025-10-12 11:01:25 -03:00
Chris McCormick
bc1294e4e6 Reconnect with exponential backoff flag: enableReconnect (#507)
https://github.com/nbd-wtf/nostr-tools/pull/507
2025-09-30 10:01:07 -03:00
Chris McCormick
226d7d07e2 Improvements to enablePing() & tests (#506)
https://github.com/nbd-wtf/nostr-tools/pull/506
2025-09-29 10:41:40 -03:00
fiatjaf
c9ff51e278 subscribeMap() now sends multiple filters to the same relay in the same REQ.
because the initiative to get rid of multiple filters went down.
v2.17.0
2025-09-20 16:54:12 -03:00
Anderson Juhasc
23aebbd341 update NIP-27 example in README 2025-08-27 10:32:45 -03:00
Anderson Juhasc
a3fcd79545 ensures consistency for .jpg/.JPG, .mp4/.MP4, etc 2025-08-27 10:32:45 -03:00
tajava2006
0e6e7af934 chore: Bump version and document NIP-46 usage 2025-08-25 11:00:06 -03:00
codytseng
8866042edf relay: ensure onclose callback is triggered 2025-08-24 22:22:38 -03:00
hoppe
ebe7df7b9e feat(nip46): Add support for client-initiated connections in BunkerSigner (#502)
* add: nostrconnect

* fix: typo
2025-08-24 15:53:01 -03:00
fiatjaf
86235314c4 deduplicate relay URLs in pool.subscribe() and pool.subscribeMany() v2.16.2 2025-08-06 10:37:36 -03:00
Don
b39dac3551 nip57: include "e" tag. 2025-08-04 15:23:29 -03:00
fiatjaf
929d62bbbb nip57: cleanup useless tests. v2.16.1 2025-08-01 20:28:49 -03:00
fiatjaf
b575e47844 nip57: include "k" tag. 2025-08-01 19:38:03 -03:00
fiatjaf
b076c34a2f tag new minor because of the pingpong stuff. v2.16.0 2025-08-01 14:12:53 -03:00
fiatjaf
4bb3eb2d40 remove unnecessary normalizeURL() call that can throw sometimes. 2025-08-01 14:11:44 -03:00
Chris McCormick
87f2c74bb3 Get pingpong working in the browser with dummy REQ (#499) 2025-07-24 11:22:15 -03:00
fiatjaf
4b6cc19b9c cleanup. v2.15.2 2025-07-23 16:22:25 -03:00
fiatjaf
b2f3a01439 nip46: remove deprecated getRelays() 2025-07-23 16:22:16 -03:00
Chris McCormick
6ec19b618c WIP: pingpong with logging. 2025-07-23 16:16:12 -03:00
Chris McCormick
b3cc9f50e5 WIP: hack in pingpong #495
TypeScript does not like the duck typing of .on and .ping (only valid on Node ws).
2025-07-23 16:16:12 -03:00
vornis101
de1cf0ed60 Fix JSON syntax of jsr.json 2025-07-19 08:58:05 -03:00
fiatjaf
d706ef961f pool: closed relays must be eliminated. v2.15.1 2025-07-17 23:39:16 -03:00
SondreB
2f529b3f8a enhance parseConnectionString to support double slash URL format 2025-07-13 11:59:04 -03:00
fiatjaf
f0357805c3 catch errors on function passed to auth() and log them. v2.15.0 2025-06-10 10:20:20 -03:00
fiatjaf
ffa7fb926e remove deprecated unused _onauth hook. 2025-06-10 10:16:11 -03:00
fiatjaf
12acb900ab SubCloser.close() can take a reason string optionally. 2025-06-10 10:15:58 -03:00
fiatjaf
d773012658 proper auth support on pool.publish(). v2.14.3 2025-06-06 22:36:07 -03:00
fiatjaf
b8f91c37fa and there was an error in jsr.json v2.14.2 2025-06-05 14:37:56 -03:00
fiatjaf
2da3528362 forgot to expose blossom, as usual. v2.14.1 2025-06-05 01:29:54 -03:00
fiatjaf
315e9a472c expose signer module. v2.14.0 2025-06-04 21:47:17 -03:00
fiatjaf
a2b1bf0338 blossom test. 2025-06-04 21:45:43 -03:00
fiatjaf
861a77e2b3 nipB7 (blossom) and a generic signer interface. 2025-06-04 21:28:33 -03:00