Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error when building AlamofireObjectMapper (6.0.0) with Xcode 10.2 & Swift 5 #270

Closed
YMonnier opened this issue Apr 27, 2019 · 13 comments
Closed

Comments

@YMonnier
Copy link

Pods

Analyzing dependencies
Downloading dependencies
Using Alamofire (5.0.0-beta.6)
Using AlamofireObjectMapper (6.0.0)
Using ObjectMapper (3.4.2)

Screenshot 2019-04-27 at 7 12 31 PM

@ghost
Copy link

ghost commented Apr 30, 2019

Has anyone found a solution to this problem?

@nlhdung
Copy link

nlhdung commented May 3, 2019

I have the same issue :(

@kateusz
Copy link

kateusz commented May 3, 2019

Pods

Analyzing dependencies
Downloading dependencies
Using Alamofire (5.0.0-beta.6)
Using AlamofireObjectMapper (6.0.0)
Using ObjectMapper (3.4.2)
Screenshot 2019-04-27 at 7 12 31 PM

The quickest solution is to provide default value, in this case just pass .main DispatchQueue, like below:

return response(queue: queue ?? .main, responseSerializer: DataRequest.ObjectMapperSerializer(keyPath, mapToObject: object, context: context), completionHandler: completionHandler)

@tiwari1amrit
Copy link

Have same issue did anyone solved it?

Screen Shot 2019-05-05 at 1 22 27 PM

@YMonnier
Copy link
Author

YMonnier commented May 5, 2019

Nop! I changed the library of my project... Now I am using Moya + ObjectMapper

@RomanPodymov
Copy link
Contributor

RomanPodymov commented May 8, 2019

Fixed in this pull request. As a temporal solution you can add the following line to your Podfile:
pod 'Alamofire', '5.0.0-beta.3'

@KieranLafferty
Copy link

KieranLafferty commented May 21, 2019

Still stuck on this
Screen Shot 2019-05-21 at 2 39 31 PM

Was able to resolve other issues locally but it appears it can't differentiate between the method signatures in ImmutableMappable and Mappable's implementation of .mapArray(JSONObject:)

Currently blocked on moving to swift 5 on this 😭Lmk if anyone has a workaround!

@RomanPodymov
Copy link
Contributor

RomanPodymov commented May 22, 2019

Hello @KieranLafferty
I cannot reproduce the issue you reported. Do you use CocoaPods to install AlamofireObjectMapper? If so, do you have the following line pod 'AlamofireObjectMapper', :git => 'https://github.com/RomanPodymov/AlamofireObjectMapper.git', :branch => 'master' in your Podfile?

@davisford
Copy link

Is there a solution for Carthage users?

@RomanPodymov
Copy link
Contributor

Hello @davisford
Replace github "tristanhimmelman/AlamofireObjectMapper" ~> 5.2 with github "RomanPodymov/AlamofireObjectMapper" "master" in your Cartfile.

@RomanPodymov
Copy link
Contributor

Hello @YMonnier
#271 was merged to master. Are you still able to reproduce the issue?

@YMonnier
Copy link
Author

Seems good with AlamofireObjectMapper 6.1.0 via Cocoapods ;)

@RomanPodymov
Copy link
Contributor

Seems good with AlamofireObjectMapper 6.1.0 via Cocoapods ;)

In such case close the issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

7 participants