Flutter project Pod install issue in ios side - cocoapods

I have trying to pod install flutter project in iOS side..but i am unable to install the pod in iOS side
its error show
[!] Invalid Podfile file: no implicit conversion of nil into String.

Fixed It by deleting the Podfile and Podfile.lock in ios folder and then run:
flutter run
or
flutter build ios
That way flutter will generate the new Podfile for flutter

Related

xCode build failed: Module 'connectivity_plus' not found

I am developing a flutter app and running on iOS Simulator works fine in Android Studio, and it works well when building from terminal flutter build ios. But when I try to build from xCode (so I can create an archive and release the app), I get this error:
Module 'connectivity_plus' not found
I used to use connectivity, and then the error was Module 'connectivity' not found.
I have found some similar questions, but none of the suggested answers worked for me. I have tried:
flutter clean
rm -rf /ios/Pods
rm -rf /ios/Podfile
rm -rf /ios/Podfile.lock
flutter pub get
cd ios
pod install
I uncomment this line in Podfile:
platform :ios, '13.0'
That is the iOS Deployment Target as well, so they match.
flutter build ios
That works ok, but when I open Runner.xcworkspace in xCode and build, I get the same error. What am I doing wrong?

XCode generating random errors

I am not sure why this error is persisting. I tried flutter clean, flutter pub get, pod deintegrate, pod install, flutter build ios. Nothing seems to work. Regards.

Pod install fails for Flutters video_editor example

I am able to clone and run flutter video_editor https://github.com/seel-channel/video_editor
in both the iPhone and Android
.
However, if I copy its example part, it works in Android but not on iPhone (physical). Ipod install fails. Please see attached screenhsot.
I am using all the same versions of everything, for the example part as well as the clone part.
Podfile
platform :ios, '9.3'
pubsec.yaml
video_editor:
path: ^1.8.0
helpers: ^1.1.1
image_picker: ^0.8.4
video_player: ^2.2.6
macOS Monterey
version 12.1
xCode version 13.1
It's work for me.
I download example from video editor.
Then in pubspec.yaml file I changed following
# video_editor:
# path: ../
video_editor: ^1.2.2
Then I fire command flutter pub get and pod install it's getting same error you want.
Then after I change platform :ios, '9.3' to platform :ios, '12.1' in pod file and changed deployment info 9.0 to 12.1 in target(Like below image) then fire commane pod install and it's work fine.

Firebase Unity project fails to find BoringSSL-GRPC library during Xcode build

I'm attempting to compile a Xcode .xcworkspace built by Unity that contains Google Firebase. I tried all the solutions I could find online without any luck. If you have any ideas I can try, can you please share?
The error I'm getting is that it can't find the BoringSSL-GRPC library. I tried running pod update and pod install to resolve this and I can see while it does successfully install BoringSSL-GRPC (0.0.7), Xcode still gives this error even if I open the .xcworkspace file.
ld: library not found for -lBoringSSL-GRPC
When I add use_frameworks! to the podfile per a suggestion online, I get this error:
ld: framework not found FBLPromises
When I removed the above and then add use_modular_headers! per another suggestion, I get this error:
fatal error: module map file '/Users/xxx/Documents/Builds/DemoProj/Pods/Headers/Private/grpc/gRPC-Core.modulemap' not found
Each time, I changed the podfile, I'd run pod update and pod install before doing a clean build in Xcode.
Here are the versions I'm using:
macOS Catalina 10.15.6
Unity 2019.4.4f1
Firebase 6.15.2
Xcode 11.6 (11E708)
CocoaPods 1.9.3
And here is my podfile:
use_frameworks!
source 'https://github.com/CocoaPods/Specs.git'
platform :ios, '10.0'
target 'UnityFramework' do
pod 'Firebase/Core', '6.24.0'
pod 'Firebase/Analytics', '6.24.0'
pod 'Firebase/RemoteConfig', '6.24.0'
pod 'FirebaseCrashlytics', '4.1.0'
pod 'FirebaseFirestore', '1.15.0'
end
Notes:
I've also tried adding ,:modular_headers => true at the end of each pod which didn't work.
I have a paid developer account and Xcode is configured for that account

AlamoFire + SwiftyJSON on iOS 9.0

I have been trying to install and use AlamoFire and SwiftyJSON on iOS 9 using CocoaPods. The latest version keeps getting installed and it is not compatible with iOS 9.0.
My PodFile looks like this:
platform :ios, '9.0'
use_frameworks!
target 'Kitchology' do
pod 'Alamofire'
pod 'SwiftyJSON'
pod 'AlamofireImage'
end
I tried commenting them out and doing a pod install to remove them, then put them back in and do another pod install. Every time the latest is installed.
I do have the project itself set to iOS 9.0 and NOT iOS 9.3 for the project build on all versions.
Figured this one out. I deleted the pods by commenting them out and running pod update. Then we deleted the workspace. Then comes the main part of the solution - we deleted everything in the derived data folder. You can find this location in Xcode->Preferences Locations. Although a clean should delete this data, it obviously did not.
Now we recreate the pods again. Do a pod init, add the pods back into the Podfile and do a pod install. Open the workspace and everything was then good.
This was a problem with cached data in Xcode.

Resources