I've updated to Swift 4.2 but there's a Swift Compiler Error
Module file's minimum deployment target is ios10.0 v10.0: /Users/heba/Library/Developer/Xcode/DerivedData/------gnbsunckknydeadcdgwcmagycrxy/Build/Products/StagingDebug-iphonesimulator/Kingfisher/Kingfisher.framework/Modules/Kingfisher.swiftmodule/x86_64.swiftmodule

Knowing that the Kingfisher is 5.1.0

I don't know how can it be related to Swift version.
Kingfisher 5 supports from iOS 10 as the deploy target, so please make sure that your app also uses iOS 10 or later as the iOS Deployment Target. If you are integrating Kingfisher through CocoaPods, it also worth to check the "platform :ios" setting in your Podfile.
the platform :ios in Podfile is 10.0 indeed.
Have no idea on this yet. :(
Maybe try a clean/full clean for the derived folder, or restart your Xcode.
With Xcode 10.1 and build setting to Swift 4, I get this error as well. Revert to KingFisher 4.0?
@aleene
Kingfisher 5 should support both Swift 4 and 4.2. How did you integrate Kingfisher to your project (CocoaPods or Carthage? And its version?)
Is there any chance to give me a reproducible sample on this error?
Or does it also happen in a new project?
I figured it out, the iOS Deployment Target in Project and Target in Build Settings was below 10.
I am afraid that did not help me. I am using Carthage and get the error message in a processing struct:

@HebaAtallah could you reopen this issue to make it visible again ?
@aleene @teolemon Kingfisher 5 now requires iOS 10 or later. So please try to confirm that your deploy target is above iOS 10. If you still need to support iOS 9 for a while, you can choose to use Kingfisher 4.x instead.
Now there is an "ios9" branch fo iOS 9 supporting temporarily before we migrate to image renderer. Please consider to use that branch when you need to use Kingfisher 5 on iOS 9.
i'm having this issue too. iOS Deployment Target in Project and Target are both iOS 11, still getting this error. How to fix this?
Changing the minimum deployment target of the Pods project fixed the issue for me.
我已经更新到Swift 4.2,但是有一个Swift编译器错误
Module file's minimum deployment target is ios10.0 v10.0: /Users/heba/Library/Developer/Xcode/DerivedData/------gnbsunckknydeadcdgwcmagycrxy/Build/Products/StagingDebug-iphonesimulator/Kingfisher/Kingfisher.framework/Modules/Kingfisher.swiftmodule/x86_64.swiftmodule
知道翠鸟是
5.1.0
Hello, may I ask if you have solved this problem? I have encountered the same mistake as you. My swift is also 4.2 version, not upgraded to 5.0 version
Maybe you have more than 1 target in project, and in one of them min iOS version is below than 10.0?
Most helpful comment
Changing the minimum deployment target of the Pods project fixed the issue for me.