mirror of
https://github.com/vitorpamplona/amethyst.git
synced 2026-08-12 09:13:23 +00:00
Move EventFinderFilterAssembler(+QueryState), the loaders (NoteEventLoader, FilterMissingEvents, FilterMissingAddressables, AddressableAuthorRelayLoader) and watchers (EventWatcher, FilterRepliesAndReactionsToNotes/Addresses) from amethyst/reqCommand/event/ into commons/relayClient/event/, mirroring the Phase 2 user-finder move. - EventFinderQueryState carries the narrow UserFinderAccount; DROPS AccountScopedQuery. Attribution stays inline via userFinderPubkeyHex; ExplainedFilter/SubPurpose tags (REFERENCED_EVENTS / ENGAGEMENT) preserved. - cache: LocalCache -> ICacheProvider threaded into NoteEventLoaderSubAssembler + the FilterMissing* functions (which called the LocalCache singleton statically); getOrCreateUser is now nullable at these sites. Added ICacheProvider.checkGetOrCreateUser default; LocalCache.checkGetOrCreateUser now overrides it. - SingleSubNoEoseCacheEoseManager moved to commons (account-agnostic accountPubKeyOf); its two amethyst callers keep attribution via a new amethyst subclass AccountScopedSingleSubNoEoseCacheEoseManager (ChannelLoader) or the plain commons base (NWCPaymentWatcher, which never attributed). Android unchanged via EventFinderShims.kt (typealiases + AccountViewModel overload); EventObservers.kt stays in amethyst. New commons EventFinderFilterAssemblerSubscription (LocalEventFinder + (note) overload reusing LocalUserFinderAccount) for Desktop. Updated the direct loader-function callers (search/hashtag/thread sub-assemblers + the moved test) to import from commons and pass LocalCache. Green: commons JVM + iOS purity, :amethyst compilePlayDebugKotlin, :desktopApp compile, spotless. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>