Skip to content

Stream StreamMessageSearchListController issue for search #1503

Description

@Srj-Love

Which packages are you using?

stream_chat_flutter

On what platforms did you experience the issue?

Android

What version are you using?

stream_chat_flutter: ^5.3.0
stream_chat_localizations: ^4.1.0
flutter_local_notifications: ^13.0.0
stream_chat_flutter_core: ^5.3.0

What happened?

I have implemented StreamMessageSearchListController with StreamMessageSearchListView. Once I' mnavigating to the Channel by using below code:-

final messageResponse = messageResponses[index];
                  FocusScope.of(context).requestFocus(FocusNode());
                  final client = StreamChat.of(context).client;
                  final message = messageResponse.message;
                  final channel = client.channel(
                    messageResponse.channel!.type,
                    id: messageResponse.channel!.id,
                  );
                  if (channel.state == null) {
                    await channel.watch();
                  }

                  Get.to(()=>StreamChannel(
                    channel: channel,
                    initialMessageId: message.id,
                    child: ChannelPage(channel: channel,
                        highlightInitialMessage: true,
                        ),
                  ));

but getting the incorrect response.
Note:- Sometime I'm getting the correct and some time incorrect. also facing issue for the scrolling while navigating to details page.

chat_search_issues.mp4

Steps to reproduce

1. Go to 'Search for Message'
2. Click on 'any messages and open details page'
3. Scroll down to '-'
4. Check for highlight message
...

Supporting info to reproduce

No response

Relevant log output

No response

Flutter analyze output

No response

Flutter doctor output

flutter/bin/flutter doctor --verbose
[✓] Flutter (Channel stable, 3.7.0, on macOS 12.5 21G72 darwin-arm64 (Rosetta), locale en-IN)
    • Flutter version 3.7.0 on channel stable at /Users/unico-016/flutter
    • Upstream repository https://github.com/flutter/flutter.git
    • Framework revision b06b8b2710 (3 months ago), 2023-01-23 16:55:55 -0800
    • Engine revision b24591ed32
    • Dart version 2.19.0
    • DevTools version 2.20.1

[✓] Android toolchain - develop for Android devices (Android SDK version 33.0.1)
    • Android SDK at /Users/unico-016/Library/Android/sdk
    • Platform android-33, build-tools 33.0.1
    • Java binary at: /Applications/Android Studio.app/Contents/jre/Contents/Home/bin/java
    • Java version OpenJDK Runtime Environment (build 11.0.15+0-b2043.56-8887301)
    • All Android licenses accepted.

[✓] Xcode - develop for iOS and macOS (Xcode 14.2)
    • Xcode at /Applications/Xcode.app/Contents/Developer
    • Build 14C18
    • CocoaPods version 1.12.0

[✓] Chrome - develop for the web
    • Chrome at /Applications/Google Chrome.app/Contents/MacOS/Google Chrome

[✓] Android Studio (version 2022.1)
    • Android Studio at /Applications/Android Studio.app/Contents
    • Flutter plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/9212-flutter
    • Dart plugin can be installed from:
      🔨 https://plugins.jetbrains.com/plugin/6351-dart
    • Java version OpenJDK Runtime Environment (build 11.0.15+0-b2043.56-8887301)

[✓] Connected device (3 available)
    • SM E225F (mobile) • 192.168.10.75:5555 • android-arm64  • Android 13 (API 33)
    • macOS (desktop)   • macos              • darwin-arm64   • macOS 12.5 21G72 darwin-arm64 (Rosetta)
    • Chrome (web)      • chrome             • web-javascript • Google Chrome 110.0.5481.100

Code of Conduct

  • I agree to follow this project's Code of Conduct

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions