mapbox-maps-ios icon indicating copy to clipboard operation
mapbox-maps-ios copied to clipboard

Can't install on SPM - invalid archive errors

Open nichita-stefanita opened this issue 1 year ago • 3 comments

Environment

  • Xcode version: 15.4
  • iOS version: 15+
  • Devices affected: MacBook pro (intel)
  • Maps SDK Version: 11.4.0

Observed behavior and steps to reproduce

MapBox dependency was added to the project by another dev. However on my machine I can't get it to be installed. I've also tried removing and then adding it back to the project while constantly clearing SPM cache, removing org.swift.swiftpm file, cleaning project derived data and restarting xcode. Just like described in Troubleshooting and Updates in the docs.

I've ran this command in terminal, so it's definitely not caused by .netrc file or token. And it works fine for the other dev and in the CI Pipeline.

curl -ILn https://api.mapbox.com/downloads/v2/mobile-maps-ios/releases/ios/11.4.0/MapboxMaps.zip
HTTP/1.1 200 OK
Connection: keep-alive
Date: Wed, 26 Jun 2024 14:02:28 GMT
X-Powered-By: Express
Cache-Control: no-cache, no-store, private
Access-Control-Allow-Origin: *
Access-Control-Allow-Methods: GET
Timing-Allow-Origin: *
X-Cache: Miss from cloudfront
Via: 1.1 3bc7ecd5aee04a4d3c660b552dad8d14.cloudfront.net (CloudFront)
X-Amz-Cf-Pop: OTP50-P1
Alt-Svc: h3=":443"; ma=86400
X-Amz-Cf-Id: rgxaMX5UrF2aJhRawTdgNLFDr_vyHrAXEH1eR1pd1gSDLFbggh3PoA==

Screenshot 2024-06-26 at 17 43 51

Expected behavior

Notes / preliminary analysis

Additional links and references

nichita-stefanita avatar Jun 26 '24 14:06 nichita-stefanita

Same problem here. "mapbox-maps-ios.git could not be resolved"

jln19 avatar Jul 03 '24 03:07 jln19

Hi, issues like that usually happen because of Xcode caches. You can try to clean all spm caches like that rm -rf ~/Library/Caches/org.swift.swiftpm/artifacts/

persidskiy avatar Jul 04 '24 11:07 persidskiy

Hi, issues like that usually happen because of Xcode caches. You can try to clean all spm caches like that rm -rf ~/Library/Caches/org.swift.swiftpm/artifacts/

@persidskiy As I mentioned in the post, I was deleting the org.swift.swiftpm file completely. Would using the rm -rf ~/Library/Caches/org.swift.swiftpm/artifacts/ command produce different results?

nichita-stefanita avatar Jul 04 '24 18:07 nichita-stefanita

The issue did resolve itself. While I couldn't install the package I removed it in my branch and was able to continue working on my project without Map box. A few weeks later, without any input from my side I was able to install the Map Box SPM.

nichita-stefanita avatar Jul 15 '24 10:07 nichita-stefanita