From 0403d64c4794ee79f2ef5fa4047caac2d074f4fb Mon Sep 17 00:00:00 2001 From: Claude Date: Thu, 9 Apr 2026 17:50:36 +0000 Subject: [PATCH] fix: filter out chess game challenges from home feed, keep only ended games LiveChessGameChallengeEvent (kind 30064) represents game offers/challenges that haven't ended yet. Remove them from both the home feed filter and the relay subscription so only completed games (kind 64) and game end events (kind 30067) appear. https://claude.ai/code/session_01XiWkVxXQBnLPTbeswL3y4c --- .../ui/screen/loggedIn/home/dal/HomeNewThreadFeedFilter.kt | 3 --- .../home/datasource/nip64Chess/FilterHomePostsByChess.kt | 2 -- 2 files changed, 5 deletions(-) diff --git a/amethyst/src/main/java/com/vitorpamplona/amethyst/ui/screen/loggedIn/home/dal/HomeNewThreadFeedFilter.kt b/amethyst/src/main/java/com/vitorpamplona/amethyst/ui/screen/loggedIn/home/dal/HomeNewThreadFeedFilter.kt index d5c134ba4..1373fca9c 100644 --- a/amethyst/src/main/java/com/vitorpamplona/amethyst/ui/screen/loggedIn/home/dal/HomeNewThreadFeedFilter.kt +++ b/amethyst/src/main/java/com/vitorpamplona/amethyst/ui/screen/loggedIn/home/dal/HomeNewThreadFeedFilter.kt @@ -43,7 +43,6 @@ import com.vitorpamplona.quartz.nip18Reposts.RepostEvent import com.vitorpamplona.quartz.nip22Comments.CommentEvent import com.vitorpamplona.quartz.nip23LongContent.LongTextNoteEvent import com.vitorpamplona.quartz.nip54Wiki.WikiNoteEvent -import com.vitorpamplona.quartz.nip64Chess.challenge.offer.LiveChessGameChallengeEvent import com.vitorpamplona.quartz.nip64Chess.end.LiveChessGameEndEvent import com.vitorpamplona.quartz.nip64Chess.game.ChessGameEvent import com.vitorpamplona.quartz.nip84Highlights.HighlightEvent @@ -62,7 +61,6 @@ class HomeNewThreadFeedFilter( WikiNoteEvent.KIND, ClassifiedsEvent.KIND, LongTextNoteEvent.KIND, - LiveChessGameChallengeEvent.KIND, LiveChessGameEndEvent.KIND, AttestationEvent.KIND, ) @@ -130,7 +128,6 @@ class HomeNewThreadFeedFilter( noteEvent is VoiceEvent || noteEvent is AudioHeaderEvent || noteEvent is ChessGameEvent || - noteEvent is LiveChessGameChallengeEvent || noteEvent is LiveChessGameEndEvent || noteEvent is AttestationEvent || noteEvent is AttestationRequestEvent || diff --git a/amethyst/src/main/java/com/vitorpamplona/amethyst/ui/screen/loggedIn/home/datasource/nip64Chess/FilterHomePostsByChess.kt b/amethyst/src/main/java/com/vitorpamplona/amethyst/ui/screen/loggedIn/home/datasource/nip64Chess/FilterHomePostsByChess.kt index a83f45dda..47f3b3840 100644 --- a/amethyst/src/main/java/com/vitorpamplona/amethyst/ui/screen/loggedIn/home/datasource/nip64Chess/FilterHomePostsByChess.kt +++ b/amethyst/src/main/java/com/vitorpamplona/amethyst/ui/screen/loggedIn/home/datasource/nip64Chess/FilterHomePostsByChess.kt @@ -24,14 +24,12 @@ import com.vitorpamplona.amethyst.model.topNavFeeds.chess.ChessTopNavPerRelayFil import com.vitorpamplona.amethyst.service.relays.SincePerRelayMap import com.vitorpamplona.quartz.nip01Core.relay.client.pool.RelayBasedFilter import com.vitorpamplona.quartz.nip01Core.relay.filters.Filter -import com.vitorpamplona.quartz.nip64Chess.challenge.offer.LiveChessGameChallengeEvent import com.vitorpamplona.quartz.nip64Chess.end.LiveChessGameEndEvent import com.vitorpamplona.quartz.nip64Chess.game.ChessGameEvent val ChessPostsKinds = listOf( ChessGameEvent.KIND, // Completed games (Kind 64) - LiveChessGameChallengeEvent.KIND, // Challenges (Kind 30064) LiveChessGameEndEvent.KIND, // Game endings (Kind 30067) )