swiftlang/swift-package-manager

Investigate usage of `nameForModuleDependencyResolutionOnly`, `explicitNameForModuleDependencyResolutionOnly`, etc. for potential removal

Open

#10,108 opened on May 22, 2026

View on GitHub
 (0 comments) (0 reactions) (0 assignees)Swift (1,462 forks)batch import
buggood first issue

Repository metrics

Stars
 (10,145 stars)
PR merge metrics
 (Avg merge 9d 4h) (62 merged PRs in 30d)

Description

Is it reproducible with SwiftPM command-line tools: swift build, swift test, swift package etc?

  • Confirmed reproduction steps with SwiftPM CLI. The description text must include reproduction steps with either of command-line SwiftPM commands, swift build, swift test, swift package etc.

Description

There are a handful of computed properties used to identify package dependencies across resolution; much of these properties are dependent on the kind of dependency (registry, source control, etc.) and at times rely on a derived identity (e.g. source control URL path components) if an explicit identity has not been given.

Much of these properties are influenced in part by the use of flags like --use-registry-identity-for-scm; in previous SwiftPM releases, it also seems like users were able to define a package dependency with a name: property to overwrite the way in which package authors would refer to this dependency in their target dependencies.

I think there is a way to make these cases a lot clearer without having so many of these computed properties.

Expected behavior

No response

Actual behavior

No response

Steps to reproduce

No response

Swift Package Manager version/commit hash

No response

Swift & OS version (output of swift --version ; uname -a)

No response

Contributor guide