Skip to content

Websocket reconnect null check exception #2303

@szechyjs

Description

@szechyjs

Which packages are you using?

stream_chat, stream_chat_flutter

On what platforms did you experience the issue?

iOS

What version are you using?

9.13.0

What happened?

I've been getting the following crash reports from Crashlytics...

Fatal Exception: FlutterError
0. ???  0x0 WebSocket._buildUri + 164 (websocket.dart:164)
1. ???  0x0 WebSocket._reconnect.<fn> + 266 (websocket.dart:266)

Steps to reproduce

Not sure how to reproduce, stacktrace is from user devices, not development.

Supporting info to reproduce

Based on the code it seems like an incorrect assumption was made that _user would always have a value. It seems a null check needs to be done somewhere.

I wonder if the work done in #2260 needs implemented in _reconnect as well?

Relevant log output

Flutter analyze output

Flutter doctor output

Code of Conduct

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't workingpr_openA PR to fix the issue is already open

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions