Search code examples
swiftxcodecocoapodseureka-forms

Xcode 10.1 ImageRow issue


Is there anyone else who is getting error during build process after Xcode upgraded to 10.1? I am trying whole night and day what's wrong and it seems like ImageRow is not compatible with newest Xcode?

Swift 4.2
Xcode 10.1
Eureka 4.3.0
ImageRow 3.1.0

Pod file:

platform :ios, '9.0'

target 'My cashflow' do
  use_frameworks!

  pod 'ImageRow', '~> 3.0'
end

And errors I get after compiling:

enter image description here

Errors:

Cannot subscript a value of type '[String : Any]' with an index of type 'UIImagePickerController.InfoKey'

'UIImagePickerControllerSourceType' has been renamed to 'UIImagePickerController.SourceType'

Missing argument label 'rawValue:' in call

All pods installed and updated (Podfile.lock):

PODS:
  - Eureka (4.3.0)
  - ImageRow (3.1.0):
    - Eureka (~> 4.0)

DEPENDENCIES:
  - ImageRow (~> 3.0)

SPEC REPOS:
  https://github.com/cocoapods/specs.git:
    - Eureka
    - ImageRow

SPEC CHECKSUMS:
  Eureka: 6d711cb30ca333b4bc893110285a722ae3840114
  ImageRow: 1ea483078bfa3d880a7fc76fdfcddfd5f29a9e6b

PODFILE CHECKSUM: 0bae1aabb456725a8d30797929aa85ea96da832c

COCOAPODS: 1.5.3

Solution

  • Searching in the ImageRow known issues and you easily find the answer: https://github.com/EurekaCommunity/ImageRow/issues/51

    For Swift 4.2 use the master branch. There is no release for that yet

    So, in your Podfile, use:

    pod 'ImageRow', :git => 'https://github.com/EurekaCommunity/ImageRow', :branch => 'master'
    

    After pod update, your Podfile.lock will show the updated dependency as:

    PODS:
      - Eureka (4.3.0)
      - ImageRow (3.1.0):
        - Eureka (~> 4.0)
    
    DEPENDENCIES:
      - ImageRow (from `https://github.com/EurekaCommunity/ImageRow`, branch `master`)
    
    SPEC REPOS:
      https://github.com/cocoapods/specs.git:
        - Eureka
    
    EXTERNAL SOURCES:
      ImageRow:
        :branch: master
        :git: https://github.com/EurekaCommunity/ImageRow
    
    CHECKOUT OPTIONS:
      ImageRow:
        :commit: 6e75b9408bd3393daea467afa73c07cc021a87ae
        :git: https://github.com/EurekaCommunity/ImageRow
    
    SPEC CHECKSUMS:
      Eureka: 6d711cb30ca333b4bc893110285a722ae3840114
      ImageRow: 1ea483078bfa3d880a7fc76fdfcddfd5f29a9e6b
    
    PODFILE CHECKSUM: 0e94ba74cfd5e7ee8120ee7410f3045c8e2cbcfc
    
    COCOAPODS: 1.5.3
    

    And it will build fine in Xcode 10+.