vapor-community / Imperial

Federated Authentication with OAuth providers
MIT License
153 stars 48 forks source link

Docker build error - ambiguous use of 'hex' #66

Closed jstorm31 closed 4 years ago

jstorm31 commented 4 years ago

When running tests inside a Docker container I get the following error:

/package/.build/checkouts/Imperial/Sources/Imperial/Services/Shopify/URL+Shopify.swift:13:10: error: ambiguous use of 'hex'
swapper_1_c2f870a92ea5 |                 return hmac.hex
swapper_1_c2f870a92ea5 |                        ^
swapper_1_c2f870a92ea5 | /package/.build/checkouts/Imperial/Sources/Imperial/Services/Shopify/URL+Shopify.swift:26:16: note: found this candidate
swapper_1_c2f870a92ea5 |     public var hex: String {
swapper_1_c2f870a92ea5 |                ^
swapper_1_c2f870a92ea5 | /package/.build/checkouts/vapor/Sources/Vapor/Utilities/Bytes+Hex.swift:2:16: note: found this candidate
swapper_1_c2f870a92ea5 |     public var hex: String {
swapper_1_c2f870a92ea5 |                ^
swapper_1_c2f870a92ea5 | [2239/2281] Compiling Imperial GoogleJWTResponse.swift
swapper_1_c2f870a92ea5 | /package/.build/checkouts/Imperial/Sources/Imperial/Services/Shopify/URL+Shopify.swift:13:10: error: ambiguous use of 'hex'
swapper_1_c2f870a92ea5 |                 return hmac.hex
swapper_1_c2f870a92ea5 |                        ^
swapper_1_c2f870a92ea5 | /package/.build/checkouts/Imperial/Sources/Imperial/Services/Shopify/URL+Shopify.swift:26:16: note: found this candidate
swapper_1_c2f870a92ea5 |     public var hex: String {
swapper_1_c2f870a92ea5 |                ^
swapper_1_c2f870a92ea5 | /package/.build/checkouts/vapor/Sources/Vapor/Utilities/Bytes+Hex.swift:2:16: note: found this candidate
swapper_1_c2f870a92ea5 |     public var hex: String {
swapper_1_c2f870a92ea5 |                ^
swapper_1_c2f870a92ea5 | [2240/2281] Compiling Imperial GoogleJWTRouter.swift
swapper_1_c2f870a92ea5 | /package/.build/checkouts/Imperial/Sources/Imperial/Services/Shopify/URL+Shopify.swift:13:10: error: ambiguous use of 'hex'
swapper_1_c2f870a92ea5 |                 return hmac.hex

It seems like the package has a conflict with Vapor package extension. I don't have any custom similar extensions in the project. This only happens when running tests inside a Docker container. Everything works fine in XCode.

Imperial version: 1.0.0-beta.1 Vapor version: 4.14.0

litso commented 4 years ago

I'm seeing the same issue in XCode with Vapor version 4.27.1

0xTim commented 4 years ago

@jstorm31 @litso turns out this was already fixed but a release hadn't been tagged. I've just release 1.0.0 Beta 2 which should solve the issues

jstorm31 commented 4 years ago

Great, I can confirm the build succeeds now. Thanks. 🙂