ElaWorkshop / TagListView

Simple and highly customizable iOS tag list view, in Swift.
MIT License
2.64k stars 492 forks source link

Problem after updating pod to 1.3.1 version / Swift 4.2 #203

Closed Kharauzov closed 5 years ago

Kharauzov commented 5 years ago

Guys, could you suggest, what I am doing wrong. In project I see, that TagListView pod was updated successfully to latest version 1.3.1. I checked it few times. However the code of pod seems to be still not at Swift 4.2. Check my screenshot for reference.
http://snpy.in/lohHYG http://snpy.in/xaeMd7 Probably I did something wrong, but can figure out what exactly.

EstebanVallejo commented 5 years ago

I have the same issue v1.3.1 installed and the pod is using Swift Language Version 4.2

EstebanVallejo commented 5 years ago

@Kharauzov meanwhile, you can use this podfile script as a workaround:

post_install do |installer|
installer.pods_project.targets.each do |target|
        if target.name == 'TagListView'
        target.build_configurations.each do |config|
          config.build_settings['SWIFT_VERSION'] = '4.0'
        end
      end
    end
end

Place that on your podfile, this will change the TagListView pod 'Swift Language Version' each time you install or update your pods.

Kharauzov commented 5 years ago

@EstebanVallejo , thanks for help. So it seems, that latest version of this pod just contains old version of code.

EstebanVallejo commented 5 years ago

Yeah actually I'm not sure what it's happening because if you take a look at the source code on GitHub it is written in Swift 4.2, but once you download it it's in 4.0, so I don't know what's happening that the latest code is not being downloaded properly.

The code on the Master Branch is not matching the one you get once you install the pod.

Kharauzov commented 5 years ago

Yeah actually I'm not sure what it's happening because if you take a look at the source code on GitHub it is written in Swift 4.2, but once you download it it's in 4.0, so I don't know what's happening that the latest code is not being downloaded probably.

The code on the Master Branch is not matching the one you get once you install the pod.

The same for me.

srv7 commented 5 years ago
pod 'TagListView', :git => 'https://github.com/ElaWorkshop/TagListView.git'
EstebanVallejo commented 5 years ago
pod 'TagListView', :git => 'https://github.com/ElaWorkshop/TagListView.git'

Great @srv7 , this fixed it, but I'm trying to understand why it is not working without specifying the git source... Perhaps cocoapods is keeping a cache of the old code???

EstebanVallejo commented 5 years ago

Alright, yes, it seems to be a problem with cocoapods caching the pod itself.

I ran the command pod cache clean --all , and then pod update (or install) and now the code is in Swift 4.2 without specifying the ':git => ...'

Kharauzov commented 5 years ago

Alright, yes, it seems to be a problem with cocoapods caching the pod itself.

I ran the command pod cache clean --all , and then pod update (or install) and now the code is in Swift 4.2 without specifying the ':git => ...'

Wow, I need to try this approach too.

Kharauzov commented 5 years ago

Alright, yes, it seems to be a problem with cocoapods caching the pod itself. I ran the command pod cache clean --all , and then pod update (or install) and now the code is in Swift 4.2 without specifying the ':git => ...'

Wow, I need to try this approach too.

Unfortunately, pod cache clean --all did not help me. Maybe in my Xcode there is a bit different case. But this approach pod 'TagListView', :git => 'https://github.com/ElaWorkshop/TagListView.git' made a trick and fixed a problem. Very mysterious bug. Never met before. In any way, thanks to all of you guys for help and suggestions. Issue could be closed.