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-209] Package Manager unable to download dependencies with a major of 0 #5440

Closed
swift-ci opened this issue Dec 12, 2015 · 4 comments
Closed
Labels

Comments

@swift-ci
Copy link
Contributor

Previous ID SR-209
Radar None
Original Reporter camelCaseD (JIRA User)
Type Bug
Status Resolved
Resolution Cannot Reproduce
Environment

Ubuntu 14.04

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

md5: b1484331102fb514ef15583d12f61b45

Issue Description:

Having a Package.swift like the following that depends on a package with no major version of 1 or greater than:

import PackageDescription

let package = Package(
  name: "Hello",
  dependencies: [
    .Package(url: "https://github.com/huytd/swift-http.git", versions: Version(0,0,0)...Version(1,0,0))
  ]
)

results in the following error when running swift build

The dependency graph could not be satisifed (https://github.com/huytd/swift-http.git). 

While the repository has been tagged with version 0.0.1.

I than created a fork of the repo and quickly created a tag of 1.0.0 then updated my Package.swift file to point to the fork and point to any version between majors of 1 and 2. Running swift build after this worked with no problems.

@swift-ci
Copy link
Contributor Author

swift-ci commented Jan 2, 2016

Comment by Kostiantyn Koval (JIRA)

camelCaseD (JIRA User)
Cab you please verify that this is still an issue? I can't reproduce it.
It find and fetches `0.0.1` now, but fails to compile

swift-build
Cloning https://github.com/huytd/swift-http.git
Using version 0.0.1 of package swift-http
Compiling Swift Module 'swifthttp' (2 sources)
/Users/konstantin/Work/spmExample/Task SR-209/Packages/swift-http-0.0.1/Sources/http.swift:23:42: error: value of type 'Int32' has no member 'rawValue'
    serverSocket = socket(AF_INET, Int32(SOCK_STREAM.rawValue), 0)
                                         ^~~~~~~~~~~ ~~~~~~~~
/Users/konstantin/Work/spmExample/Task SR-209/Packages/swift-http-0.0.1/Sources/http.swift:30:17: error: use of unresolved identifier 'htons'
      sin_port: htons(port),
                ^~~~~
<unknown>:0: error: build had 1 command failures

@swift-ci
Copy link
Contributor Author

swift-ci commented Jan 2, 2016

Comment by Kostiantyn Koval (JIRA)

Also it maybe useful to clear the Packages folder. It contains the cashed checked-out dependencies.

@swift-ci
Copy link
Contributor Author

swift-ci commented Jan 2, 2016

Comment by Brandon Borders (JIRA)

Yes I can verify that I am able to download it now

@swift-ci
Copy link
Contributor Author

swift-ci commented Jan 2, 2016

Comment by Kostiantyn Koval (JIRA)

Great, than I think I would mark this issue as resolved.

@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
This issue was closed.
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

1 participant