Boilertalk / Web3.swift

A pure swift Ethereum Web3 library
MIT License
643 stars 189 forks source link

Add explicit swift_version #72

Closed pixelmatrix closed 1 year ago

pixelmatrix commented 5 years ago

If you pod install on a new project in Xcode 10 it will default to Swift version of 4.2, which made some breaking changes that this library needs to address. This will fix the pod for people installing until the library supports 4.2.

koraykoska commented 5 years ago

@pixelmatrix I think we are using some 4.1 features. But I'm not entirely sure. Is there a reason you set it to 4.0?

pixelmatrix commented 5 years ago

4.1 isn’t an option in Xcode for some reason. I think it was not intended to be a major release, but rather a temporary release until they got 4.2 out. It seems to build fine and the tests run on 4.0, but it’s your call.

On Nov 11, 2018, at 4:02 PM, Koray Koska notifications@github.com wrote:

@pixelmatrix I think we are using some 4.1 features. But I'm not entirely sure. Is there a reason you set it to 4.0?

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub, or mute the thread.

koraykoska commented 5 years ago

If it does it's fine for me. Just wanted to know the reason. 4.1 is really a weird version...

On Mon, Nov 12, 2018, 01:24 Josh Pyles notifications@github.com wrote:

4.1 isn’t an option in Xcode for some reason. I think it was not intended to be a major release, but rather a temporary release until they got 4.2 out. It seems to build fine and the tests run on 4.0, but it’s your call.

On Nov 11, 2018, at 4:02 PM, Koray Koska notifications@github.com wrote:

@pixelmatrix I think we are using some 4.1 features. But I'm not entirely sure. Is there a reason you set it to 4.0?

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub, or mute the thread.

— You are receiving this because you commented.

Reply to this email directly, view it on GitHub https://github.com/Boilertalk/Web3.swift/pull/72#issuecomment-437720006, or mute the thread https://github.com/notifications/unsubscribe-auth/AK1JzVhOXDY1K_Hf2WJylY1zthagp8sVks5uuL_CgaJpZM4YMHCK .

pixelmatrix commented 5 years ago

@rogerluan Good catch. I ran the tests locally and then I forgot to follow up on this PR. Didn't realize there was a .swift-version file, but since it's deprecated, I removed it just now.

rogerluan commented 5 years ago

Looks like removing that file broke something in the CI environment setup 🤔

pixelmatrix commented 5 years ago

Yep, looks like there's something in the Travis config that relies on that file. @Ybrin can we remove that portion of the config now?

More on the deprecation here: https://blog.cocoapods.org/CocoaPods-1.4.0/

koraykoska commented 5 years ago

Yes I was using .swift-version to install the swift compiler on the Linux test system. I guess we will have to manually specify it now in the travis config file.

pixelmatrix commented 5 years ago

@Ybrin Maybe it can parse the Podspec and read the swift version from there?

pixelmatrix commented 5 years ago

Alternatively we can leave the swift-version file for now and just make sure it matches. Might be just pushing the pain down the road though.

koraykoska commented 5 years ago

Parsing the podspec would be ideal. But I've never done this before. If you know how, fell free to implement it, even if it's a little bit of an overkill, I appreciate it 😉