Skip to content

tests: drop WinCNG retry workarounds - #2603

Closed
vszakats wants to merge 2 commits into
libssh2:masterfrom
vszakats:wincng-drop-retry
Closed

vszakats wants to merge 2 commits into
libssh2:masterfrom
vszakats:wincng-drop-retry

Conversation

@vszakats

Copy link
Copy Markdown
Member

Should no longer be necessary after fixing the root cause.
(Though we do not run these tests in CI at the moment.)

Ref: #804
Follow-up to f216bbe #2583
Follow-up to bc120a3 #1023

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 Changes recommended

test_ssh2 now incorrectly returns success for failures occurring after a successful handshake.

Get a fresh assessment by requesting another Copilot review.

Pull request overview

Removes WinCNG-specific test retries following the key-exchange fix associated with #804/#2583.

Changes:

  • Runs fixture tests once without retrying KEX failures.
  • Simplifies test_ssh2 handshake handling.
File summaries
File Description
tests/test_ssh2.c Removes handshake retries.
tests/runner.c Removes fixture-level retry loop.
Review details
  • Files reviewed: 2/2 changed files
  • Comments generated: 1
  • Review effort level: Balanced

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

Comment thread tests/test_ssh2.c Resolved

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟢 Approval recommended

The retry removal is consistent and preserves existing failure and cleanup behavior.

Review details
  • Files reviewed: 2/2 changed files
  • Comments generated: 0 new
  • Review effort level: Balanced

Should no longer be necessary after fixing the root cause.
(Though we do not run these tests in CI at the moment.)

Ref: libssh2#804
Follow-up to f216bbe libssh2#2583
Follow-up to bc120a3 libssh2#1023
@vszakats vszakats closed this in 5bfa574 Sep 11, 2026
@vszakats
vszakats deleted the wincng-drop-retry branch September 11, 2026 22:48
vszakats added a commit that referenced this pull request Oct 7, 2026
Example:
```
1: libssh2_session_handshake failed (-43): Failed getting banner
1: ---- sshd log ----
1: No matching private key for certificate: /etc/ssh/ssh_host_mldsa44-ed25519_key-cert.pub
1: debug1: Set /proc/self/oom_score_adj from 0 to -1000
1: debug2: fd 6 setting O_NONBLOCK
1: debug1: Bind to port 22 on 0.0.0.0.
1: Server listening on 0.0.0.0 port 22.
1: debug2: fd 7 setting O_NONBLOCK
1: debug1: Bind to port 22 on ::.
1: Server listening on :: port 22.
1: ------------------
1: Command: docker image pull ghcr.io/libssh2/ci_tests_openssh_server:8d1fde1834077fddb9f9
1: Command: docker image tag ghcr.io/libssh2/ci_tests_openssh_server:8d1fde1834077fddb9f9 libssh2/openssh_server
1: Command: docker run --rm -d -p 22 libssh2/openssh_server
1: Command: docker inspect --format "{{ (index (index .NetworkSettings.Ports \"22/tcp\") 0).HostIp }}" a1f1a209001852fa7e3aba87c0f1198661c4fe07c34ddcbf2e76e264ef64b7b8
1: Command: docker inspect --format "{{ (index (index .NetworkSettings.Ports \"22/tcp\") 0).HostPort }}" a1f1a209001852fa7e3aba87c0f1198661c4fe07c34ddcbf2e76e264ef64b7b8
1: Command: docker logs a1f1a209001852fa7e3aba87c0f1198661c4fe07c34ddcbf2e76e264ef64b7b8
1: Command: docker stop a1f1a209001852fa7e3aba87c0f1198661c4fe07c34ddcbf2e76e264ef64b7b8
 1/61 Test  #1: test_aa_warmup .......................................***Failed    6.08 sec
libssh2_session_handshake failed (-43): Failed getting banner
```
Ref: https://github.com/libssh2/libssh2/actions/runs/37613324059/job/112765610280?pr=2659#step:25:133

Ref: 5bfa574 #2603

Closes #2662
vszakats added a commit that referenced this pull request Oct 13, 2026
In an attempt to improve stability / reduce flakiness of these tests.
Especially the ECDSA-enable ones were prone to mass fail.

```
22:49:30.110000 * Failure establishing ssh session: -43, Failed getting banner
```
Ref: https://github.com/libssh2/libssh2/actions/runs/38480041149/job/115580107883#step:11:1034

This is a different failure than the long-chased flaky -8 kex failures,
which was fixed earlier and did not reoccur since then.

Follow-up to 5bfa574 #2603
Follow-up to f216bbe #2583
Follow-up to bb8e095 #2590

Closes #2666
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

tests Windows Windows-specific

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants