Skip to content

Bloated SPM Repository Checkout #42

@nicorichard

Description

@nicorichard

Issue

  • Resolving this dependency with Swift Package Manager takes a long time
  • Using this dependency consumes too much Hard Drive space

Context

This repository appears to exist as a mirror to provide a thinner version of the Sendbird UIKit for Swift Package Manager clients.

However, rather than using the framework binary which you make available on the Github release, this library has elected to store and reference a binary framework hosted directly in source control. This leads SPM to download not only the current release, but to checkout all previous releases when resolving the UIKit dependency.

This leads to a much-much larger download than necessary.

Worse yet, this information is not cleared after the installation, it sits in the developer's machine wasting hard drive capacity as well. A developer using the Sendbird UIKit in a modular project might have numerous copies of this repository on their machine. I have ~5GB dedicated to it myself.

Derived Data

1 copy per project using Sendbird

Screenshot 2024-08-01 at 9 47 25 AM

Swift PM Cache

1 copy per machine

Screenshot 2024-08-01 at 10 40 34 AM

Solution

I've created a repository demonstrating how I believe this package should be vendored.

Using this package (in the same way that you would install this one) leads to a much faster download and much less data retention

Derived Data

Screenshot 2024-08-01 at 10 30 51 AM

Swift PM Cache

Screenshot 2024-08-01 at 10 43 08 AM

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions