Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[SR-13994] Dependency fails when already exists under different URL #4457

Open
swift-ci opened this issue Dec 26, 2020 · 1 comment
Open
Labels

Comments

@swift-ci
Copy link
Contributor

Previous ID SR-13994
Radar rdar://problem/72864702
Original Reporter Sherlouk (JIRA User)
Type Bug

Attachment: Download

Environment

Xcode 12.2 (12B45b)

Additional Detail from JIRA
Votes 0
Component/s Package Manager
Labels Bug
Assignee None
Priority Medium

md5: 3915714990d4a95bffaefae0d2705e12

Issue Description:

Hey! So I ran into a bit of a bizarre bug with Swift Package Manager yesterday when adding a dependency to my project. I've reproduced it in a fresh project and attached it to this project.

Take a project with this structure:

MyCodebase pulls in a remote (can be a local dependency, doesn't matter) dependency (DependencyOne) which itself has a dependency on another (DependenceTwo).

This works. No problems at this point.

Now if MyCodebase adds a new dependency onto DependencyTwo using the same URL. This works, still no problem.

However... if, when I add DependencyTwo to MyCodebase, I use a different URL for same package (for example without the .git extension) then the dependency is removed from the side panel (in Xcode) and the package will no longer be detected.

The only error you get is when you try to include DependencyTwo into a target (via the dependencies array). At that point it will simply say that DependencyTwo doesn't exist, which is of course very confusing when you've specified it above (and that's not raising any problems).

Hope that all makes sense... bit of a weird one! This was all made worse by the fact I didn't realise the dependency I was trying to add was already a dependency of the project since it was a couple packages down a chain.

@typesanitizer
Copy link

@swift-ci create

@swift-ci swift-ci transferred this issue from apple/swift-issues Apr 25, 2022
@shahmishal shahmishal transferred this issue from apple/swift May 4, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants