signalr_flutter icon indicating copy to clipboard operation
signalr_flutter copied to clipboard

I can't receive hub events on ios. On android everything is working fine.

Open Deivid1071 opened this issue 3 years ago • 13 comments

When starting the app in ios the signal is connected and keeps the connection, but I don't receive any event. If I keep android and ios receiving the same event, on android it is received but on ios not.

Is there any specific configuration for ios at this point to work well?

Deivid1071 avatar Nov 12 '21 12:11 Deivid1071

I recently rewrote the plugin using flutter pigeon with few breaking changes. Will push a pre-release version on the pub by tomorrow. Your problem should resolve in that, if not feel free to let me know. Will notify here once it goes live on pub.dev.

AyonAB avatar Nov 12 '21 14:11 AyonAB

How amazing, thank you very much for your willingness and promptness, I'll wait to use the new version

Deivid1071 avatar Nov 12 '21 14:11 Deivid1071

A new pre-release version is released in pub.dev. Feel free to try it out.

AyonAB avatar Nov 13 '21 08:11 AyonAB

Hi, thanks for the info, I used this new version and the behavior persists. I made a call with the Hub do signal but the event only arrived on the android and did not arrive on the ios simulator. The ios status was "ConnectionStatus.connected"

Do I need to enable some setting?

Deivid1071 avatar Nov 13 '21 16:11 Deivid1071

Did you get any error message on your console after the event is dispatched? Will look into it once I get some time.

AyonAB avatar Nov 13 '21 17:11 AyonAB

I didn't get any error on the console, it just doesn't happen. I tried to run in the debug but nothing came up.

I understand, as soon as something new comes out I'll try again

Deivid1071 avatar Nov 13 '21 17:11 Deivid1071

Strange cause I tested on both debug and release mode and the events are arriving fine. Have you tried cleaning your project from vscode/android studio & xcode before trying the pre release version?

AyonAB avatar Nov 14 '21 14:11 AyonAB

I just updated the plugin, I'll try again cleaning the project. I'm using a Mac M1 I don't know if this is relevant. I will try again later. thanks for the feedback

Deivid1071 avatar Nov 14 '21 15:11 Deivid1071

Hi, I tried again with a clean project and used the example from the pub dev itself, but I couldn't receive events. On the hub side would need to send something different to work on ios? thanks for the support

Deivid1071 avatar Nov 16 '21 12:11 Deivid1071

Hello Have same problem on iOS for signalr_flutter: ^0.2.0-dev.2

flutter: @@@ ConnectionStatus.connecting
flutter: @@@ ConnectionStatus.connectionError
flutter: @@@ ConnectionStatus.disconnected

======== Exception caught by services library ======================================================
The following PlatformException was thrown during a platform message callback:
PlatformException(channel-error, ["source": Internal Server Error, "message": Error during start request. Stopping the connection.], null, null)

When the exception was thrown, this was the stack: 
#0      SignalR.onStatusChange (package:signalr_flutter/signalr_flutter.dart:46:7)
#1      SignalRPlatformApi.setup.<anonymous closure> (package:signalr_flutter/signalr_api.dart:277:21)
#2      SignalRPlatformApi.setup.<anonymous closure> (package:signalr_flutter/signalr_api.dart:270:35)
#3      BasicMessageChannel.setMessageHandler.<anonymous closure> (package:flutter/src/services/platform_channel.dart:73:49)
#4      BasicMessageChannel.setMessageHandler.<anonymous closure> (package:flutter/src/services/platform_channel.dart:72:47)
#5      _DefaultBinaryMessenger.setMessageHandler.<anonymous closure> (package:flutter/src/services/binding.dart:379:35)
#6      _DefaultBinaryMessenger.setMessageHandler.<anonymous closure> (package:flutter/src/services/binding.dart:376:46)
#7      _invoke2.<anonymous closure> (dart:ui/hooks.dart:205:15)
#11     _invoke2 (dart:ui/hooks.dart:204:10)
#12     _ChannelCallbackRecord.invoke (dart:ui/channel_buffers.dart:42:5)
#13     _Channel.push (dart:ui/channel_buffers.dart:132:31)
#14     ChannelBuffers.push (dart:ui/channel_buffers.dart:329:17)
#15     PlatformDispatcher._dispatchPlatformMessage (dart:ui/platform_dispatcher.dart:544:22)
#16     _dispatchPlatformMessage (dart:ui/hooks.dart:92:31)
(elided 3 frames from dart:async)
====================================================================================================

For previous version i had same problem, but empty log

xalabax avatar Dec 10 '21 15:12 xalabax

@xalabax have you fixed this issue ? because i am facing same problem in ios.

nikhilsingh834783 avatar Apr 06 '23 13:04 nikhilsingh834783

@AyonAB connection is not establishing in ios getting this error. SignalR Error: ["source": , "message": Error during start request. Stopping the connection.] Please help.

nikhilsingh834783 avatar Apr 06 '23 13:04 nikhilsingh834783

When starting the app in ios the signal is connected and keeps the connection, but I don't receive any event. If I keep android and ios receiving the same event, on android it is received but on ios not.

Is there any specific configuration for ios at this point to work well?

Deivid, did you find any solution?

potumati avatar Oct 26 '23 15:10 potumati