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

SwiftLint 0.52.4: "The package product SwiftOperators requires minimum platform version 13.0 for the iOS platform, but this target supports 12.0" #5228

Closed
2 tasks done
curia-damiano opened this issue Sep 19, 2023 · 7 comments
Labels
integration Issues related to integration of SwiftLint into toolchains.

Comments

@curia-damiano
Copy link

curia-damiano commented Sep 19, 2023

New Issue Checklist

Describe the bug

When updating SwiftLint from 0.52.2 to 0.52.4, I get multiple compiler errors, like in the subject

Environment

  • SwiftLint version: 0.52.4

  • Installation method used: Swift Package

  • Are you using nested configurations?
    No

  • Which Xcode version are you using (check xcodebuild -version)?
    15.0

  • Do you have a sample that shows the issue? Run echo "[string here]" | swiftlint lint --no-cache --use-stdin --enable-all-rules
    to quickly test if your example is really demonstrating the issue. If your example is more
    complex, you can use swiftlint lint --path [file here] --no-cache --enable-all-rules.
    Yes, I have an open-source sample in GitHub

ISSUE:

  • I have a small app in GitHub at https://github.com/curia-damiano/SwiftUIDownloader
  • This app was using SwiftLint 0.52.2
  • I am checking that everything works with Xcode 15.0 and I want to update to the latest SwiftLint
  • I get multiple errors like in the subject.
    I have also removed the package (the solution compiles successfully) and re-added it, but still I get the errors.
  • I currently have all my targets at iOS 15.0; I've also updated them to 16.0, but the error persists
  • From a similar issue in the Apple Forum, it can be that a dependency of SwiftLint targets iOS 12, but I'm skilled enough to troubleshoot it myself
  • If needed, I can attach to this issue my small POC project as zip file (I don't want to commit in GitHub if it doesn't compile)
@SimplyDanny SimplyDanny added the integration Issues related to integration of SwiftLint into toolchains. label Sep 19, 2023
@drekka
Copy link

drekka commented Sep 20, 2023

Duplicate of #5208 but I like your title so I've updated mine to look like yours so others can find it easier :-)

@curia-damiano
Copy link
Author

curia-damiano commented Oct 5, 2023

Solved with the release of 0.53.0.

I close my own issue.......

@curia-damiano
Copy link
Author

Reopening because on a different project I get exactly the same error, even with 0.53.0

@curia-damiano curia-damiano reopened this Oct 8, 2023
@drekka
Copy link

drekka commented Oct 16, 2023

v0.53.0 hasn't fixed it over here. Only updated the error to say it requires support for iOS 12 instead of 11. So improved I guess, but definitely NOT fixed.

@jpsim
Copy link
Collaborator

jpsim commented Oct 16, 2023

The package product SwiftOperators requires minimum platform version 13.0 for the iOS platform, but this target supports 12.0

Please read the error messages that Xcode is providing carefully. Your projects are configured in such a way that Xcode is attempting to build SwiftLint for iOS, which will not compile. SwiftLint supports building and running on macOS and Linux only.

This appears to be a common mistake. Please try this suggestion to see if it helps: #3073 (comment)

@SimplyDanny
Copy link
Collaborator

Closing as duplicate of #5208.

@curia-damiano
Copy link
Author

The package product SwiftOperators requires minimum platform version 13.0 for the iOS platform, but this target supports 12.0

Please read the error messages that Xcode is providing carefully. Your projects are configured in such a way that Xcode is attempting to build SwiftLint for iOS, which will not compile. SwiftLint supports building and running on macOS and Linux only.

This appears to be a common mistake. Please try this suggestion to see if it helps: #3073 (comment)

I confirm that the comment solves my issue. But you can see that many non-expert devs like me face this issue.
Just as suggestion: would you be able to provide a more specific message?
Also, the old version was working when adding the packages to the targets, so, again, many of us hit this issue.

Anyway, thank you for finally solving this issue!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
integration Issues related to integration of SwiftLint into toolchains.
Projects
None yet
Development

No branches or pull requests

4 participants