JASidePanels Slide Menu iOS Native Library Crash only on device - iphone

I tried to use JASidePanel, but its crashes on device. I thought that is a problem in the link configuration, so, I changed it but the problem was not solved.
I flowed this example to create my project, but I using Xib file to create the login design screen: https://github.com/MvvmCross/MvvmCross-Samples/tree/master/XPlatformMenus
I using:
Xamarin.iOS: 10.3.1,
Xcode: 8.2,
MvvmCross: 4.4.0,
MvvmCross.iOS.Support: 4.4.0
MvvmCross.iOS.Support.JASidePanels: 4.4.0
The exception:
The exception

Related

Flutter - Apple Watch - unable to resolve product type 'com.apple.product-type.watchkit2-extension' for platform 'iphoneos'

I try to create a Flutter app with android and apple watch support.
For android i don't have problems so far. But I'm struggling with apple watch.
I followed the official instruction from flutter: https://docs.flutter.dev/development/platform-integration/ios/apple-watch. If I see it right, we don't have to enable Bitcode anymore because since Xcode 14 Bitcode is deprecated.
But anyway, i tried it with enabling and without enabling Bitcode. Both ways run into the same error.
After I added the Watch App as a Target I get these Errors:
Could not build the precompiled application for the device.
Error (Xcode): unable to resolve product type 'com.apple.product-type.watchkit2-extension' for platform 'iphoneos'
Error (Xcode): Couldn't look up product type 'com.apple.product-type.watchkit2-extension' in domain 'iphoneos': Couldn't load spec with identifier 'com.apple.product-type.watchkit2-extension' in domain 'iphoneos'
Error (Xcode): unable to resolve product type 'com.apple.product-type.application.watchapp2' for platform 'iphoneos'
Error (Xcode): Couldn't look up product type 'com.apple.product-type.application.watchapp2' in domain 'iphoneos': Couldn't load spec with identifier 'com.apple.product-type.application.watchapp2' in domain 'iphoneos'
Googleing this errors leaded me to this stackoverflow question and answer from 'karim'.
target specifies product type 'com.apple.product-type.watchkit2-extension', but there's no such product type for the 'iphonesimulator' platform
In my case, most of the things were ok when I add watchkit extension with xcode 7. but debug target of the extension was iOS. So when I run in debug/simulator I got this error. I have to change them to WatchOS. and Solved. Select Project > Targets > Supported Platform > Debug > watchOS (I had iOS here).
Checking my Supported Platforms, i saw that for my watch targets at 'Supported Platforms' it was also 'watchOS' for 'Debug' but for 'Profile' and 'Release' it was 'iphoneos'
I changed 'Profile' and 'Release' to 'watchOS'. Running with this changes, i get only three of the previous errors:
Could not build the precompiled application for the device.
Error (Xcode): unable to resolve product type 'com.apple.product-type.watchkit2-extension' for platform 'iphoneos'
Error (Xcode): unable to resolve product type 'com.apple.product-type.application.watchapp2' for platform 'iphoneos'
Error (Xcode): Couldn't look up product type 'com.apple.product-type.application.watchapp2' in domain 'iphoneos': Couldn't load spec with identifier 'com.apple.product-type.application.watchapp2' in domain 'iphoneos'
And at this point, I stuck... I don't know how to continue.
I found this guide and example that runs fine. But flutter shows an warning that parts of the code are already deprecated. I can't figure out what are the differences that makes his project run and my is having problems with...
https://medium.com/kbtg-life/adding-apple-watch-to-flutter-app-via-flutter-method-channel-f1443532d94e
https://github.com/theamorn/flutter-apple-watch
Can someone help?
Thanks in advance! :)
Edit 1 - 19.9.2022
Okay, the code of the example I talked about above, is not deprecated, just needs a small migration.
The original warning was:
This app is using a deprecated version of the Android embedding.
To avoid unexpected runtime failures, or future building failures, try to migrate this app to the V2 embedding.
Take a look at the docs for migrating an app: https://github.com/flutter/flutter/wiki/Upgrading-pre-1.12-Android-projects
What I just needed to do was to change in the AndroidMainifest.xml:
<application
android:name="io.flutter.app.FlutterApplication"
to:
<application
android:name="${applicationName}"
like here described:
How to Fix Flutter Warning: Your Flutter application is created using an older version
https://github.com/flutter/flutter/wiki/Upgrading-pre-1.12-Android-projects
But that still doesn't solve my original problem.
I don't want to build my app based of the example project. I would like to start at an entire new flutter project and add a Apple Watch as target.
I still can't figure out what are the differences between a new created project based on the flutter instruction and the working example project...
Edit 2 - 20.9.2022
Thanks to the Answer of #Einzeln , I noticed that my config ui layout looks different to his.
So I checked for Updates on all Programms that are needed.
Just for clarification what I have installed now after the update:
Flutter 3.3.2 - channel stable
Dart 2.18.1
DevTools 2.15.0
Android Studio Dolphin | 2021.3.1
Xcode Version 14.0
First different that I notice is that the file structure is different if I add a watch as target:
There is only on directory for the watch and not like before I updated ,and also in the example that I talked earlier, that there were two directory. One labeled 'watch' and the other 'watch extension'.
Thanks to #Einzelns answer I also checked the configuration. I had to manually add the watch to my 'Runner' app at 'Frameworks, Libraries, and Embedded Content'.
At the 'watch' I didn't need to add the Runner app there.
But I had to add the 'WatchKit Companion App Bundle Identifier' for the 'watch' at Build Settings -> Info.plist Values.
Starting both apps (watch app and smartphone app) from Xcode is working without any problems.
But starting the Flutter Project / App form Android Studio and also from terminal with 'flutter run' or 'flutter run --release' is leading me to this following problem:
Why is it working fine starting from Xcode but has problems starting from flutter?
For me it seems like that the default generated watch app has code that is only available at iOS 14 and newer. Here is the generated default code:
But probably I can work from here on and 'just' need to recreate the code so, that it is also supported by older iOS versions.
Actually, I have no idea what's happening with your project but I guess it's about Xcode configurations.
Can you check in Xcode > Targets > General
and see if you don't miss importing any Watch app inside
iOS
Apple Watch
I encountered this issue recently. I tried all the above solutions but got no effect. I found this one when I'm about to give up: https://dev.to/gie3d/add-an-apple-watch-target-on-flutter-app-3m0m
By updating the WKCompanionAppBundleIdentifier to the info.plist in the WatchKit Extension folder, all the problems went away, and I can compile the app again.
<!-- `info.plist` in WatchKit Extension folder -->
<plist version="1.0">
<dict>
<key>NSExtension</key>
<dict>
....blablabla
<key>NSExtensionPointIdentifier</key>
<string>com.apple.watchkit</string>
</dict>
<!-- Add the following two lines -->
<key>WKCompanionAppBundleIdentifier</key>
<string>$(PRODUCT_BUNDLE_IDENTIFIER)</string>
</dict>
</plist>
Change supported platforms in build setting to watchOS.
WatchOS Target Setting
There are two main problems you are facing:
Lack of Apple's up-to-date documentation after they changed watchOS project structure and moved watchOS App target settings to the main project file.
bugs in xCode that don't allow you to setup you project correctly.
I have recently spent a week setting up a similar project and here's how I got it going:
Downgrade your xCode to late 2021/early 2022 [!!!critical step!!!]
Create Flutter project as usual (flutter create ...)
Add watchOS companion app as per every manual out there (File->New->Target->watchOS-> add WatchOS Companion app ), and make sure it still runs as expected
Merge your project with Apple Watch Conectivity code sample by manually dragging the watch App and extension files from finder into the xCode project, making sure your targets are assigned correctly. Make sure to manually merge the code of the AppDelegate.swift files. The trick here is to keep the Watch app's Info.plist file from the code sample, but exclude it from the xCode build phases [!!! critical step !!!]
Upgrade xCode back to latest
Update your bundle ID's in all three targets' Info.plist files as/if necessary
Make sure your project still runs and back it up
Upgrade your xCode project as per xCode's suggestion - it will remove one of the targets so you will only have two, not three.
If everything went well - now you should be able to run the watch app with Flutter app.
Add Native Channel to Flutter app and iOS app to port connectivity status and other events in and out of Flutter app.
Run watchOS target via xCode and minimize it (do not close!).
Run flutter debug as per usual.
Now you should end up with your Flutter debug session connected to the watch app and you can use hot reload etc. to develop your FLutter app as per usual.

Can't get audio chat flutter app to run on iOS - 'AgoraRtcKit/AgoraRtcEngineKit.h' file not found

I am trying to run the flutter code from the following repository
https://github.com/perpetio/clubhouse
It succesfully installs and loads on Android (still working on the firebase authentication)
Unfortunately, on iOS (both simulator and device) I get the error message: " 'AgoraRtcKit/AgoraRtcEngineKit.h' file not found" which itself is thrown by the AgoraRtcEngineKit.h file during import
#import <AgoraRtcKit/AgoraRtcEngineKit.h>
Tried the scarce available solutions (mostly in the context of react-native) however still not working..
Many thanks in advance for your help
Did you make sure to add the iOS permissions? https://pub.dev/packages/agora_rtc_engine#ios
If you did, try this as well: https://pub.dev/packages/agora_rtc_engine#ios-video-cant-show-android-works-fine

The same Parse project for Android and IOS app at the same time

When I'm using the same Parse project that is already created for Android app for the swift app It created another Installation class inside the project so I can not use the same Installation class inside Parse project for Android and IOS app at the same time, how I can solve this problem
also when I want to send push msg I have only one choice for System only for Android.
I solved problem by using the following line to get the current Installation class at Parse Project.
let installation = PFInstallation.currentInstallation()
Another problem about Android OS to push notification the problem from me because I didn't add the certificate of app to the parse project.

Worklight application loops by wl_deviceNoProvisioningRealm challenges

My application with authentication is based on the sample code for Module 21. It is running on Android and PC-browser well. I have added an iPhone Environment and tested it on Xcode and Simulator then strange loop has occurred.
By my investigation, first call to adapter procedure enters loop. It seems caused by challenges response from adapter.
I have taken TCP trace with eclipse as following.
<request>
adapter=AdapterName&procedure=ProcedureName&parameters=xxxxxx&isAjaxRequest=true&x=0.19480942375957966
<response>
/*-secure-
{"challenges":{"wl_deviceNoProvisioningRealm":{"token":"lsfssroob823c30493g709st01"}}}*/
This occurs only on iPhone/iPad Simulator ( not on Android nor PC browser).
I had tried to add and remove some elements on authenticationConfig.xml but doesn't effect.
Worklight 5.0.5.1
xcode 4.6
iPhone Simulator iOS 5.0~6.1
How can I solve this ?
Did you add your bundleId attribute to the iPhone/iPad element in your application-descriptor.xml?

iPhone build failed on using Aviary SDK

I am creating an Iphone application wherein I need to process image and display it on application. I went through Aviary SDK which indeed really appeals to me as a developer. I went through its documentation which I understood very clearly.
The problem I am facing is in building the application. I receive a build failed when I try building application. I also went through GitHub repository CSPicker. Build also fails for that. I did every specific change mentioned in Prerequisites in the documentation. Still no success.
Following is the error I am getting:
Command /Xcode4.2/Platforms/iPhoneSimulator.platform/Developer/usr/bin/clang failed with exit code 1
I am using XCode 4.2 and iOS 5.0.
It's hard to say what is the problem. Likely you did not add necessary libraries to build with. Or used old compiler in settings (not LLVM)
As of right now Aviary has new version of SDK with decent description what needs to be done at http://www.aviary.com/ios-documentation