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-6337] swift build hangs #4924

Closed
swift-ci opened this issue Nov 9, 2017 · 6 comments
Closed

[SR-6337] swift build hangs #4924

swift-ci opened this issue Nov 9, 2017 · 6 comments
Labels

Comments

@swift-ci
Copy link
Contributor

swift-ci commented Nov 9, 2017

Previous ID SR-6337
Radar None
Original Reporter ianpartridge (JIRA User)
Type Bug
Status Resolved
Resolution Duplicate
Environment

Swift 4

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

md5: 3ae013a94fb8b73a07cbfdd44f2f4534

duplicates:

  • SR-3981 Using private repository for editable package

Issue Description:

Package.swift:

// swift-tools-version:4.0
// The swift-tools-version declares the minimum version of Swift required to build this package.

import PackageDescription

let package = Package(
name: "MyApp",
dependencies: [
.package(url: "https://github.com/IBM-Swift/Kitura.git", from: "2.0.0"),
.package(url: "https://github.com/IBM-Swift/Kitura-CredentialsHTTP.git", from: "1.8.0")
],
targets: [
.target(
name: "MyApp",
dependencies: ["Kitura", "CredentialsHTTP"]),
]
)

Log:

$ swift build
Fetching https://github.com/IBM-Swift/Kitura.git
Fetching https://github.com/IBM-Swift/Kitura-CredentialsHTTP.git
Fetching https://github.com/IBM-Swift/Kitura-net.git
Fetching https://github.com/IBM-Swift/Kitura-TemplateEngine.git
Fetching https://github.com/IBM-Swift/KituraContracts.git
Fetching https://github.com/IBM-Swift/LoggerAPI.git
Fetching https://github.com/IBM-Swift/BlueSocket.git
Fetching https://github.com/IBM-Swift/CCurl.git
Fetching https://github.com/IBM-Swift/BlueSSLService.git
Fetching https://github.com/IBM-Swift/Kitura-Credentials.git
Fetching https://github.com/IBM-Swift/Kitura-Session.git

Adding --verbose shows much gitness occurring...

@swift-ci
Copy link
Contributor Author

swift-ci commented Nov 9, 2017

Comment by Ian Partridge (JIRA)

@aciidb0mb3r here's an example of what we discussed at Swift Summit.

@swift-ci
Copy link
Contributor Author

Comment by Jack Newcombe (JIRA)

This occurred for me because git was waiting for user input but the prompt was being swallowed.

If you run your build in verbose mode, copy out the command that it hangs on and run it locally to see what the prompt is.

In my case it was prompting me to add the github RSA key to the known_hosts file. After accepting the addition, I ran swift build again and it worked fine.

@swift-ci
Copy link
Contributor Author

Comment by Ian Partridge (JIRA)

That is a separate issue to this one. This is about package manager spinning during dependency resolution.

@swift-ci
Copy link
Contributor Author

swift-ci commented Apr 5, 2018

Comment by Addison Webb (JIRA)

I am also running into this issue on Ubuntu.

Swift 4.1 - swift-4.1-RELEASE-ubuntu16.04

{{Package.swift}}

import PackageDescription

let package = Package(
    name: "myapp",
    products: [
        .executable(
            name: "myapp",
            targets: ["myapp"])
    ],
    dependencies: [
        .package(url: "git@github.com:IBM-Swift/Kitura.git", from: "2.0.0")
    ],
    targets: [
        .target(
            name: "myapp",
            dependencies: ["Kitura"]
        )
    ]
)

@swift-ci
Copy link
Contributor Author

Comment by Addison Webb (JIRA)

I was able to resolve the issue by changing the package url to: {{https://github.com/IBM-Swift/Kitura.git}}

@swift-ci
Copy link
Contributor Author

Comment by Jack Newcombe (JIRA)

addisonwebb (JIRA User) per my comment, try cloning the repo manually once to see if you are prompted to add the host to the authorised list.

@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