Search code examples
iosswiftswift-package-managerxcode14swift-package

Xcode: SPM Package shows as No such module 'AsyncAlgorithms'


I'm trying to add the swift-async-algorithms package to my project using SPM. I add it the package:

enter image description here

enter image description here

I'm tried to import the package to my project:

enter image description here

Any of you knows how can I can fix this error?

I tried almost all the posible solitons in here but none of them work.

I'll really appreciate your help.


Solution

  • Based on your screenshots and your import, it looks like you're looking at two different git repos / SPM's.

    The screenshot that you posted is for this repo: (swift-algorithms)

    However you're trying to import from this repo: (swift-async-algorithms)

    Both are Apple SPM's, but you added the wrong one. So you need to remove the first and use the second, and then you'll need to select which package products you want to use:

    enter image description here