
This workaround would be more time-consuming for people trying out PSPDFKit, but at least the process would work reliably. We considered other options, such as if our sample projects didn’t have the Swift package dependencies already configured, and we documented how to add these. We documented the requirement to reset package caches, but of course, iOS developers commonly expect that you can just open and run an Xcode project without additional steps. Since downloading the package sometimes worked and sometimes didn’t, we were fairly certain this was a bug in Swift Package Manager, and we thought we couldn’t do anything about it.Īnd so this problem remained for months - and it was a really awful first experience with PSPDFKit for our customers. Adding the packages from scratch also worked reliably. To fix this issue, we found you just need to select File > Packages > Reset Package Caches at any point after opening the Xcode project, and then the download would work. However, since around the release of Xcode 13.0 (and tested up until Xcode 14.0 beta 1 at the time of writing), we observed that when first cloning or downloading our Catalog and Minimal sample projects, the following error would show up in Xcode:įailed downloading ‘ ’ which is required by binary target ‘PSPDFKit’: ~/Library/Developer/Xcode/DerivedData/Minimal-enhpcflwoobkdifztstuqbqotegx/SourcePackages/artifacts/pspdfkit-sp/11.3.1.zip already exists in file systemĪt first, I basically read this error message as “failed downloading PSPDFKit, some long path, blah blah”. Swift Package Manager is a fabulously convenient way to add PSPDFKit’s advanced PDF functionality to any app. This occurred alongside the introduction of support for binary (precompiled) frameworks in packages in Xcode 12.0.

Our iOS PDF SDK has supported Swift Package Manager since PSPDFKit 10 was released.
