-
Notifications
You must be signed in to change notification settings - Fork 51
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
NIOSSHClient gets stucked #86
Comments
@vladimir-aubrecht Same problem here. Did you find a solution? |
I'm getting an exception exactly there. Do you also get an exception? Or is it just endlessly waiting?
|
@sarensw You seem to have another issue, which is that you're creating a channel when the connection has been torn down already. |
@Lukasa thanks for the info. I'll create another ticket then as I am using the Swift SSH example client without any line changed. |
@Lukasa Now I also stumbled into the same situation as described by the author of this ticket. The following section is basically taken from the client example, with some prints added. // Wait for the connection to close
print("closing")
try! childChannel.closeFuture.wait()
print("child channel closed")
let exitStatus = try! exitStatusPromise.futureResult.wait()
print("exist status promise awaited")
try! channel.close().wait()
print("all closed")
print(exitStatus)
The command that I provide is executed correctly on the remotely connected system, just as I would expect. So the channel seems to be successfully created. Do you have any idea? Is there any way that I can analyse this further? |
@Lukasa , so I've been adding print() pretty much everywhere in the code now. It turns out that private func partnerWriteEOF() {
print("func partnerWriteEOF")
self.context?.close(mode: .output, promise: nil)
print("func partnerWriteEOF closed")
} So |
That is unlikely to be possible: |
I am having what appears to be the same problem. Any updates @sarensw? |
This also looks related @Lukasa: https://forums.swift.org/t/wrapper-for-niosshclient-swift-nio-ssh-client-example/55741 |
@daugust7 no update yet. I want to take some time again next week to "print the call stack after this point" using You are right with the link in the forum. The question in the forum is actually also from me. So it is related 👍 |
Any update on this issue? |
Any updates on this issue? |
Problem
When testing NIOSSHClient, I am always getting stucked indefinitely on childChannel wait() method. Could somebody help me understand what is the problem?
Findings
Setup
The text was updated successfully, but these errors were encountered: