medallia / digital-ios-sdk

MIT License
5 stars 5 forks source link

Build Failed #4

Closed Chevit closed 2 years ago

Chevit commented 2 years ago

Please don't do fixes in this way.

If you want to fix anything - add a new tag. At this moment our builds are broken cuz Xcode 13.2 can't find package product 'MedalliaPackage'. And And the previous version was good. 'Reset packages cache' and other commands don't help. As result, we will try to use manual integration and this is not the first time.

Screenshot 2022-03-21 at 14 06 07 Screenshot 2022-03-21 at 14 07 15 Screenshot 2022-03-21 at 14 07 51
OriMedallia commented 2 years ago

Hi @Chevit What you're suggesting won't work in Xcode 13.3 and above.

First, you need to remove the package from your project Clear the Swift Package Manager cache on your machine by going to ~/Library/Caches/org.swift.swiftpm/ and delete: Digital-iOS-SDK folder Digital-iOS-SDK lock file Then please reintegrate with version 4.0.2

If for some reason it doesn't work for you please contact your Medallia's CSM and we'll schedule a meeting.

noelstieglitz commented 2 years ago

We ran into the same issue. Our build broke and I can't re-add it using SPM for a specific version or range of versions (like we were doing).

I'm working around this issue by pointing to the main branch rather than specifying a version.

OriMedallia commented 2 years ago

Hi @noelstieglitz After clearing cache like mentioned above, you can point to exact version 4.0.2 or if you don't want to use exact version the version should be between 4.0.0 and 5.0.0 You can see that the 4.0.2 tag exist here https://github.com/medallia/Digital-iOS-SDK/tags If you're still experiencing this issue, please contact your Medallia's CSM and we'll schedule a meeting

noelstieglitz commented 2 years ago

@OriMedallia thanks for following up. We were successfully referencing this project pointing to 3.9.1 prior to the update to this repo ~8 days ago. After the latest changes, I receive an error on my dev machine (as well as in the CI pipeline, pointing to it not being a cache issue) trying to reference this library using SPM. As I mentioned in my previous comment, I also am not able to add a reference using a specific version or a range of versions. Steps to reproduce:

  1. Clear the cache per your recommendation above.
  2. Following the steps described in the readme (https://github.com/medallia/Digital-iOS-SDK/blob/main/README.md), reference a specific version or range of versions. Try 4.0.2 or 4.00 - 5.0.0.
  3. See an error in the Xcode SPM UI that the "package resolution failed"

I can temporarily work around this issue by following the steps in the readme, except instead of choosing a specific version or a range of versions, choosing "branch" -> main (or a specific commit). Pointing to main is obviously a bad long term solution because anytime you push to this repo, we'll get latest, which could cause unexpected changes in our CI pipeline vs. our local environment. @Chevit's solution is the better long term solution if you guys aren't able to fix the repo.

Interestingly I'm not seeing any reference to the previously existing (at least looking at our references, looks like it used to exist) 3.9.1 tag and I'm seeing multiple commits against the same 4.0.2 tag.

OriMedallia commented 2 years ago

@noelstieglitz Can please try to create a new project with v4.0.2 and let me know if the issue is reproduceable on an empty project? Thanks