0

Charts suggested us to install them with cocoapods without specifying release tag: pod 'Charts' and this is means that we are working with the master / trunk branch, right? So what is about potential risks of the inability of the existing Application with the last changes in Charts? How can I add Charts with specifying the concrete version?

P.S. specifying tag neither

pod 'Charts', '4.0.1'

nor

  pod 'Charts', :git => 'https://github.com/danielgindi/Charts.git', :tag => '4.0.1'

doesn't help, and brings us the error:

% pod update
...
Analyzing dependencies
[!] CocoaPods could not find compatible versions for pod "Charts":
  In Podfile:
    Charts (= 4.0.1)

None of your spec sources contain a spec satisfying the dependency: `Charts (= 4.0.1)`.

You have either:
 * mistyped the name or version.
 * not added the source repo that hosts the Podspec to your Podfile.
slavik
  • 1,341
  • 2
  • 11
  • 16
  • Does this answer your question? [could not find compatible versions for pod](https://stackoverflow.com/questions/48638059/could-not-find-compatible-versions-for-pod) – mfaani Sep 24 '21 at 13:34
  • Honey, unfortunately, no. – slavik Sep 25 '21 at 18:05

2 Answers2

2

Looking in GitHub, it appears that their tags have a "v" at the front of the version number. I would change your versioned attempt to be:

pod 'Charts', :git => 'https://github.com/danielgindi/Charts.git', :tag => 'v4.0.1'

Note I've changed 4.0.1 to v4.0.1 to match the tag name on GitHub.

Scott Thompson
  • 22,629
  • 4
  • 32
  • 34
  • 1
    Scott, big thanks for paying my attention on the tag label! Your answer solves the pod installation, but unexpectedly project can't build because of the Charts error - "No such module 'Algorithms'". – slavik Sep 25 '21 at 18:02
-1

With help of Scott Thompson, I've found that

pod 'Charts', '3.6.0'

is worked and there are no error at build time! So, I think this is the right solution.

slavik
  • 1,341
  • 2
  • 11
  • 16