chinloyal / pusher_client

A Pusher Channels Client for Fluttter (Fully supports Android and iOS)

Home Page:https://pusher.com/channels

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Keeps in connecting status in IOS

melchorlapinigjr opened this issue · comments

Flutter doctor:
`Doctor summary (to see all details, run flutter doctor -v):

[✓] Flutter (Channel stable, 3.3.4, on macOS 12.6 21G115 darwin-arm, locale en-PH)
[✓] Android toolchain - develop for Android devices (Android SDK version 33.0.0)
[✓] Xcode - develop for iOS and macOS (Xcode 14.0)
[✓] Chrome - develop for the web
[✓] Android Studio (version 2021.3)
[✓] VS Code (version 1.72.2)
[✓] Connected device (5 available)
[✓] HTTP Host Availability
`

Logs:

"D/PusherClientPlugin: Event stream listening..." "D/PusherClientPlugin: Pusher initialized" "D/PusherClientPlugin: [connecting]" "D/PusherClientPlugin: [connecting]" flutter: INFO: --> POST https://api.hours.fi/api/users/560/update_token flutter: INFO: content-type: application/json; charset=utf-8 flutter: INFO: {"token":""} flutter: INFO: --> END POST (175-byte body) flutter: INFO: --> GET https://api.hours.fi/api/notifications?page=1&is_paginate=true&per_page=10 flutter: INFO: --> END GET flutter: \^[[38;5;12m┌───────────────────────────────────────────────────────────────────────────────────────────────────────────────────────<…> flutter: \^[[38;5;12m│ #0 _MainAppState.build.<anonymous closure>.<anonymous closure>.<anonymous closure>.<anonymous closure> (package:hours_flutter/main.dart:169:38)<…> flutter: \^[[38;5;12m│ #1 BlocBuilder.build (package:flutter_bloc/src/bloc_builder.dart:90:57)<…> flutter: \^[[38;5;12m├┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄<…> flutter: \^[[38;5;12m│ 💡 AuthenticationState=Authenticated(false)<…> flutter: \^[[38;5;12m└───────────────────────────────────────────────────────────────────────────────────────────────────────────────────────<…> "D/PusherClientPlugin: Subscribed: user_560" "D/PusherClientPlugin: Event stream cancelled." "D/PusherClientPlugin: Event stream listening..." "D/PusherClientPlugin: [BIND] App\\Events\\WorkUpdate" "D/PusherClientPlugin: Subscribed: private-users_560" "D/PusherClientPlugin: Event stream cancelled." "D/PusherClientPlugin: Event stream listening..." "D/PusherClientPlugin: [BIND] Illuminate\\Notifications\\Events\\BroadcastNotificationCreated" flutter: \^[[38;5;12m┌───────────────────────────────────────────────────────────────────────────────────────────────────────────────────────<…> flutter: \^[[38;5;12m│ #0 PusherClientHelper.initializePusherClient.<anonymous closure> (package:hours_flutter/src/api/pusher_client.dart:35:14)<…> flutter: \^[[38;5;12m│ #1 PusherClient._eventHandler (package:pusher_client/src/pusher/pusher_client.dart:127:34)<…> flutter: \^[[38;5;12m├┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄┄<…> flutter: \^[[38;5;12m│ 💡 previousState: connecting, currentState: connecting<…> flutter: \^[[38;5;12m└───────────────────────────────────────────────────────────────────────────────────────────────────────────────────────<…>

I'm using physical device iPhone X iOS 15.6
Been stuck for 2 days. Any help or hind is appreciated. Thank you.

I am having the same issue on android, so if you find a fix for this please let me know :D
Also, what might work for you if you have not tried this yet is this: https://github.com/chinloyal/pusher_client#subscribing-to-private-channels-with-ios

And have you also gone over these steps? https://github.com/chinloyal/pusher_client#for-ios

I fixed it for my application - forked the code and made some tweaks. Reverted to older PusherSwift (from https://github.com/thijskuilman/pusher_client).

The newer versions of PusherSwift do not work with non-Pusher versions - it only works with the official plugin. Please let me know if you need help.

commented

Hey there,
I'm having this issue too,
could anyone fix this.

this is what I get when I subscribe to a channel.

[  +49 ms] D/PusherClientPlugin(20983): Event stream cancelled.
[        ] D/PusherClientPlugin(20983): Event stream listening...
[  +14 ms] D/PusherClientPlugin(20983): [CONNECTING]
[        ] D/PusherClientPlugin(20983): [CONNECTING]
[   +1 ms] D/PusherClientPlugin(20983): [CONNECTING]
[        ] D/PusherClientPlugin(20983): [CONNECTING]
[   +1 ms] D/PusherClientPlugin(20983): [CONNECTING]
[        ] D/PusherClientPlugin(20983): [CONNECTING]
[        ] D/PusherClientPlugin(20983): [CONNECTING]
[ +737 ms] D/PusherClientPlugin(20983): [RECONNECTING]
[   +1 ms] D/PusherClientPlugin(20983): [RECONNECTING]
[        ] D/PusherClientPlugin(20983): [RECONNECTING]
[        ] D/PusherClientPlugin(20983): [RECONNECTING]