Flutter keeps importing old version of Plugin for iOS Flutter keeps importing old version of Plugin for iOS dart dart

Flutter keeps importing old version of Plugin for iOS


In your case I take a look in plugin source on github and a see that you aren't updating the version of your plugin in your upetch_paysquare_service.podspec file.

This is your current version:

Pod::Spec.new do |s|  s.name             = 'upetch_paysquare_service'  s.version          = '0.0.2'#I Think you should update this field with '0.0.7'  s.summary          = 'A Flutter plugin for RazorPay SDK's.description = <<-DESC

Try update in your plugin to:

Pod::Spec.new do |s|      s.name             = 'upetch_paysquare_service'      s.version          = '0.0.7' #New Version       s.summary          = 'A Flutter plugin for RazorPay SDK'    s.description = <<-DESC

This change can help the apps that are using your plugin get the current version when the developer run pod install or pod update.

Why am I telling this?

Well, I had a problem like yours a few days ago but in a different case. In my case was in an app that I am developing and all plugins and versions are working pretty fine on android side but when I start on iOS platform the things was not pretty well.On iOS side all the plugins are coming with different versions that I declared in pubspec file, mostly in '0.0.1' version, and I was able to workaround this updating the specific_plugin.podspec file of each one. I really don't know if this is the correct way to solve this problem but in my case it's working!

But one exception! In my case the geolocator plugin was the only one that are coming with correct version declared in pubspec file and I see that in his geolocator.podspec file the current version was updated in s.version property. I suppose that pod update or pod install read this field to download the right plugin version.