"Missing package product" error for all local Swift Packages when switching git branches

Isn't Apple going to fix it? It's been four days.

@vine There's an updated Xcode 13.2.1 that's just been posted. The release notes showing it's explicitly aimed at two fixes - the package resolution issue from above, and another related to libConcurrency and bitcode.

3 Likes

One thing to try (it worked for me to resolve a very similar problem ["import" failing to be satisfied that the package was in scope] - Xcode 13.3.1 & macOS 12.3.1) is to not use the "Add Local .." button in the "Add Packages .." panel, but to type in a "file://.." URL (like you would "https://github.." for a web based package).

The result is quite different in that the Package is added to the "Package Dependencies" where Xcode sees it, whereas "Add Local .." puts the Package above the "Package Dependencies" where Xcode seems to ignore it. This after six hours of deleting derivatives and caches, removing and re-adding the package and cleaning the project so many times that it shines!

The above resolved the exact same problem on three different Macs - new and old.

So my package list is now:

https://github.com/me/PackOne.git   
https://github.com/me/PackTwo.git
file:///Users/me/Development/PackThree

.. and I've kissed a whole day goodbye, which I will consider worth it if this help someone else.

I might also have read: