mirror of
https://github.com/vitorpamplona/amethyst.git
synced 2026-10-06 11:48:24 +00:00
Three related fixes. 1. EventBroadcaster now reads the addressed author straight off the `a` coordinate. The whole a-tag branch was nested inside `getAddressableNoteIfExists(addressId)`, so an event answering an addressable this device had never cached contributed no relays at all - an RSVP to an appointment seen only as a bare reference went to the sender's own outbox and never to the host it was answering. A coordinate is `kind:pubkey:dTag`, so the author is in the tag and needs no cache entry. Adds a pure `addressedAuthors(AddressHintProvider)` (EventBroadcaster is not unit-constructible, so the logic is extracted the way this repo extracts routing decisions) and feeds each result through computeRelayListForLinkedUser, which already falls back to stored relay hints for an unknown user. 2. RenderCalendarRSVPEvent loads and subscribes to the appointment behind the RSVP. LoadAddressableNote puts the AddressableNote in LocalCache and EventFinderFilterAssemblerSubscription asks relays for it - filterMissingAddressables selects exactly the addressables whose event is null. This is what gives the broadcaster's a-tag walk something to walk: fix 1 reaches the host from the coordinate alone, but the other invitees are read off the appointment, which has to be in the cache. Composition-scoped like every other per-note subscription. 3. quartz/src/androidUnitTest/ was a dead source set. The module declares androidHostTest, so nothing under androidUnitTest/ was ever compiled and its two test classes had never run. IntentResultSerializerTest, HintIndexerMemoryTest and their RuntimeExt helper move to androidHostTest, where both now execute and pass. The directory's other two files were stale pre-migration duplicates and are deleted: relayDB.txt is byte-identical to the androidHostTest copy, and its TestResourceLoader.kt predates the loadDecompressString actual, so it would no longer compile against the current expect. `./gradlew test`: 11,694 tests, 0 failures. The 4 pre-existing testAndroidHostTest failures are untouched and still unrelated to this branch. Co-Authored-By: Claude Opus 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01Nxd2uiYajDGuymQK93txzG