fiatjaf
fed4a55613
fix reconnection relay leakage and double onclose calls.
2026-07-21 14:38:15 -03:00
fiatjaf
cbb1b9688d
subscribeMap's onClose is now called with {url, reason}[] instead of reason[].
2026-07-14 13:17:35 -03:00
fiatjaf
b1406da48e
blossom: send content-type header when uploading.
2026-07-13 22:28:19 -03:00
fiatjaf
514678b102
automatically closed unused relay connections after a while.
2026-07-13 11:24:56 -03:00
fiatjaf
21d11f1496
export new modules to jsr.
2026-07-01 00:49:15 -03:00
fiatjaf
73ff3660ac
add a bunch of kind numbers.
2026-06-26 18:59:47 -03:00
fiatjaf
dab630de34
nip10/nip22: guard against malformed tags.
2026-06-22 21:20:09 -03:00
fiatjaf
e17366cd2e
add AUTH recommendations to README.
...
fixes https://github.com/nbd-wtf/nostr-tools/issues/537
2026-06-10 22:09:28 -03:00
fiatjaf
5de4f4549b
fix jsr export.
2026-05-18 21:11:05 -03:00
fiatjaf
ed47ef8ef7
bump version.
2026-05-18 20:52:28 -03:00
fiatjaf
a9e89e16e3
nip22: like nip10, but for kind:1111 and adjacent kinds.
2026-05-18 20:52:05 -03:00
d3vv3 and fiatjaf
1b955bdbcb
fix: window.printer is undefined in AbstractRelay._onmessage
2026-02-28 01:01:07 -03:00
fiatjaf
1c1e2cc51a
verify event should catch exceptions from basic validation.
2026-02-26 18:10:39 -03:00
fiatjaf
e45a9987e2
pool: prevent edge case with undefined subcloser.
2026-02-12 15:08:13 -03:00
fiatjaf
ab802c8dbe
automatic prune broken relay objects and keep track of relay idleness so they can be pruned.
2026-02-02 18:44:52 -03:00
fiatjaf
ccb9641fb9
pool: maxWaitForConnection parameter.
...
this was so obvious.
2026-01-31 00:27:55 -03:00
fiatjaf
b624ad4059
pool: hooks to notify when a relay fails to connect, then ask whether a connection should be attempted.
2026-01-30 17:35:46 -03:00
fiatjaf
b3d314643a
make everything dependent on npm again.
2026-01-30 07:16:04 -03:00
fiatjaf
3588d30044
do the same for @noble/ciphers and @scure packages.
2026-01-27 22:43:54 -03:00
fiatjaf
bfa40da316
nip46: improve fromURI() and implement "switch_relays".
2026-01-22 21:50:30 -03:00
fiatjaf
0235b490fa
nip27: fix trailing / in urls.
2025-12-11 21:23:32 -03:00
fiatjaf
7a50d9328d
add some more kinds.
2025-12-09 10:56:43 -03:00
fiatjaf
0b6543e1a8
use setInterval() instead of nested setTimeout()s for pingpong.
...
prevent call stacks from building up
2025-12-05 21:46:16 -03:00
fiatjaf
85c964be3d
enableReconnect() always update the filters to the time of the last received event on each subscription.
2025-12-05 13:24:49 -03:00
fiatjaf
de7d459f6f
only transform filters with enableReconnect() when we're actually reconnecting.
2025-12-05 09:22:33 -03:00
fiatjaf
e959409c14
fix classifyKind() test.
2025-11-25 22:21:46 -03:00
fiatjaf
34a1d8db47
kinds: more reliable regular/replaceable kind figuring.
2025-11-24 20:08:15 -03:00
fiatjaf
01880b6fb5
nip27: parse emoji shortcodes and hashtags too.
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
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
2025-11-18 09:33:11 -03:00
Chris McCormick and fiatjaf
1e0f393268
Fix subscribeMap EOSE grouping. Fixes #514
2025-10-29 08:18:49 -03:00
Chris McCormick and fiatjaf
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.
2025-10-26 23:33:38 -03:00
tajava2006 and fiatjaf_
0e6e7af934
chore: Bump version and document NIP-46 usage
2025-08-25 11:00:06 -03:00
fiatjaf
86235314c4
deduplicate relay URLs in pool.subscribe() and pool.subscribeMany()
2025-08-06 10:37:36 -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.
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
fiatjaf
4b6cc19b9c
cleanup.
2025-07-23 16:22:25 -03:00
vornis101 and fiatjaf_
de1cf0ed60
Fix JSON syntax of jsr.json
2025-07-19 08:58:05 -03:00
fiatjaf
d706ef961f
pool: closed relays must be eliminated.
2025-07-17 23:39:16 -03:00
fiatjaf
f0357805c3
catch errors on function passed to auth() and log them.
2025-06-10 10:20:20 -03:00
fiatjaf
d773012658
proper auth support on pool.publish().
2025-06-06 22:36:07 -03:00
fiatjaf
b8f91c37fa
and there was an error in jsr.json
2025-06-05 14:37:56 -03:00
fiatjaf
2da3528362
forgot to expose blossom, as usual.
2025-06-05 01:29:54 -03:00
fiatjaf
315e9a472c
expose signer module.
2025-06-04 21:47:17 -03:00
fiatjaf
5b78a829c7
ignore error when sending on a CLOSE to a closed connection.
2025-05-31 12:29:24 -03:00
fiatjaf
de26ee98c5
failed to connect to a websocket should reject the promise.
2025-05-31 11:16:22 -03:00
fiatjaf
eff9ea9579
remove deprecated subscribeManyMap()
2025-05-17 18:52:01 -03:00
fiatjaf
4ba9c8886b
forgot to remove nip96 from export lists.
2025-05-12 05:24:57 -03:00
fiatjaf
3e839db6f2
tag v2.13.0 (breaking because stuff is removed).
2025-05-12 05:20:45 -03:00