Open thijskuilman opened 2 years ago
i'm facing the same thing on ios 15
@AhmedAbogameel @Waqar27324 I might have figured this out.
Solution
ios/Podfile
to contain the following line: platform :ios, '13.0'
target.build_configurations.each do |config|
config.build_settings.delete 'IPHONEOS_DEPLOYMENT_TARGET'
end
For example, my post_install looks like this:
post_install do |installer|
installer.pods_project.targets.each do |target|
flutter_additional_ios_build_settings(target)
target.build_configurations.each do |config|
config.build_settings.delete 'IPHONEOS_DEPLOYMENT_TARGET'
end
end
end
pubspec.yaml
. And replace the pusher_client dependency with my fork:pusher_client:
git:
url: git://github.com/thijskuilman/pusher_client.git
flutter clean && flutter pub get && cd ios && pod install
What I did in the fork I replaced replaced PusherSwiftWithEncryption with PusherSwift (version > 9.0). Also updated the imports in the iOS code accordingly. See my commit for all changes: https://github.com/thijskuilman/pusher_client/commit/d95d362a74d3e0602e8959b3c8b992ec57adba24
What I've tested so far I successfully tested the following:
I currently don't have an app that uses all capabilities of the pusher_client plugin, so I'm not able to test everything right now. But it seems to work perfectly fine now! @AhmedAbogameel @Waqar27324 could you test this solution in your project and let me know if it works for your projects as well? Anything I'm overlooking right now? If not, then I can submit a pull request for this package.
I will definately try this later 🤞Thanks!
definitely works @thijskuilman, only problem is I always got this error failed to connect to ws-ap1.pusher.com/XX.XXX.XX.XX (port 6001) from /:: (port 53350): connect failed: ETIMEDOUT (Connection timed out), I am expecting to connect to a defined domain not with pusher.com
definitely works @thijskuilman, only problem is I always got this error failed to connect to ws-ap1.pusher.com/XX.XXX.XX.XX (port 6001) from /:: (port 53350): connect failed: ETIMEDOUT (Connection timed out), I am expecting to connect to a defined domain not with pusher.com
removing the cluster made me pass with this error
have to drop it here tho, next thing after applying this is this error message
[] nw_protocol_copy_ws_definition_block_invoke [C1.1:1] nw_ws_validate_server_response did you passed by this too @thijskuilman ?
pusher_client: git: url: git://github.com/thijskuilman/pusher_client.git
This works!! Thanks
@AhmedAbogameel @Waqar27324 I might have figured this out.
Solution
1. First of all, update your `ios/Podfile` to contain the following line: `platform :ios, '13.0'` 2. Add the following code to your post_install command within the Podfile:
target.build_configurations.each do |config| config.build_settings.delete 'IPHONEOS_DEPLOYMENT_TARGET' end
For example, my post_install looks like this:
post_install do |installer| installer.pods_project.targets.each do |target| flutter_additional_ios_build_settings(target) target.build_configurations.each do |config| config.build_settings.delete 'IPHONEOS_DEPLOYMENT_TARGET' end end end
1. Go to your `pubspec.yaml`. And replace the pusher_client dependency with my fork:
pusher_client: git: url: git://github.com/thijskuilman/pusher_client.git
1. Go to your project root folder. Run `flutter clean && flutter pub get && cd ios && pod install` 2. Try to run the app on your iOS device or simulator
What I did in the fork I replaced replaced PusherSwiftWithEncryption with PusherSwift (version > 9.0). Also updated the imports in the iOS code accordingly. See my commit for all changes: thijskuilman@d95d362
What I've tested so far I successfully tested the following:
* Connect with a PusherClient * onConnectionStateChange * onConnectionError * Channel subscribe * Channel event binding
I currently don't have an app that uses all capabilities of the pusher_client plugin, so I'm not able to test everything right now. But it seems to work perfectly fine now! @AhmedAbogameel @Waqar27324 could you test this solution in your project and let me know if it works for your projects as well? Anything I'm overlooking right now? If not, then I can submit a pull request for this package.
Fantastic
nw_protocol_copy_ws_definition_block_invoke [C1.1:1] nw_ws_validate_server_response
I also facing same issue
check this issue https://github.com/chinloyal/pusher_client/issues/39 there is a working workaround there
check this issue #39 there is a working workaround there
HI @ragingallan I have tried all thing and at the last I end up with nw_protocol_copy_ws_definition_block_invoke [C1.1:1] nw_ws_validate_server_response error ... when I use V8 plugin...it working fine...but only in debug mode, In Archive build it making error like multiple command product with "Reachability" and "ReachabilityShift" frameWork . Now I'm totaly confused that what should I do? any solution?
mmm., I ended up not using any package that has conflict with Reachability.,
here's the package that I used: laravel_echo: ^1.0.0-beta.1 laravel_flutter_pusher: ^0.0.4
https://github.com/chinloyal/pusher_client/pull/41 can you put this request too ?
Any updates on this?
@GauravCalidig @adham-ashraf77 Yes in my case I'm using below packages laravel_echo: ^0.2.9 pusher_client: ^1.1.3
for "Reachability" and "ReachabilityShift" conflict I check all other packages who use this framework. Then I got "keyboard_visibility" plugin which had this conflict problem. then I remove this "Reachability" framework from keyboard_visibility.podspec file. this help me to get rid to build error
finally code is working fine. let me know if you need more help
@swatiElegant can you share this part "other is I add "arm64" in Excluded Architectures in below pods" how did you do it? Thanks for your help. Would appreciate that.
hi... If you working with laravel_echo and pusher client then you should have Sodium, PusherSwiftWithEncryption, pusher_client PODs (check in Xcode project) .. I'm sharing some screenshot where you can get your query.
second thing change IOS deployment target from 8.0 to 9.0 in above pods.
let me know or share here your error which you are facing ..if you find any difficulty.
I'm facing this error
[] nw_protocol_copy_ws_definition_block_invoke [C18.1:1] nw_ws_validate_server_response
after too many attempts. I did get some luck from this solution! but when I used this fork, I could not connect to the pusher. Then I reverted back to original plugin "pusher_client: ^2.0.0" , now my connections are stable and everything is working fine
after too many attempts. I did get some luck from this solution! but when I used this fork, I could not connect to the pusher. Then I reverted back to original plugin "pusher_client: ^2.0.0" , now my connections are stable and everything is working fine
@ZakwanIbrahim3321 Did you make it worked in both android and ios?
after too many attempts. I did get some luck from this solution! but when I used this fork, I could not connect to the pusher. Then I reverted back to original plugin "pusher_client: ^2.0.0" , now my connections are stable and everything is working fine
@ZakwanIbrahim3321 Did you make it worked in both android and ios?
yes it's working on both android and iOS
I changed this line url: git://github.com/thijskuilman/pusher_client.git to url: https://github.com/thijskuilman/pusher_client.git then pub get worked
@LakshithWithana Can you change org.jetbrains.kotlin:kotlin-gradle-plugin to more new please?
The Android Gradle plugin supports only Kotlin Gradle plugin version 1.5.20 and higher. The following dependencies do not satisfy the required version: project ':pusher_client' -> org.jetbrains.kotlin:kotlin-gradle-plugin:1.3.50
Steps to reproduce
flutter run
(I'm building for the iPhone 12 Pro Max simulator)Expected behavior
I'd expect the app to compile and run in the iOS simulator.
Actual behavior
I get the following error:
Output of
flutter doctor
: