Remove PTY-level keepalive #449

Merged
starhound merged 4 commits from starhound/pty-keep-alive-ping-echo into dev-1.10.0 2025-12-17 04:27:53 +00:00
starhound commented 2025-12-16 22:18:38 +00:00 (Migrated from github.com)

Overview

This pull request removes the PTY-level keepalive mechanism from the SSH terminal backend to prevent unwanted ^@ characters from appearing in user terminals. The code now relies solely on SSH-level keepalive settings for connection health monitoring, which avoids producing visible output in the terminal.

Documentation and references:

  • Added comments explaining that SSH-level keepalive is now handled via connectConfig options (keepaliveInterval, keepaliveCountMax, tcpKeepAlive) and included references to relevant GitHub issues for further context.…SH-level keepalive instead
  • Added: ...
  • Updated: ...
  • Removed: ...
  • Fixed: ...
  • Removed the periodic writing of \x00 to the SSH stream as a keepalive (previously done via setupPingInterval and pingInterval). This was causing visible control characters in terminals with echoctl enabled.
  • Cleaned up related code by removing the pingInterval variable and its setup/cleanup logic. [1] [2] [3]

Changes Made

  • Removes PTY level keep-alive in favor of SSH Keep-alive options.

Related Issues

Screenshots / Demos

https://vimeo.com/1147146616?share=copy&fl=sv&fe=ci

Checklist

  • Code follows project style guidelines
  • [] Supports mobile and desktop UI/app (if applicable) --> Electron only.
  • I have read Contributing.md
# Overview This pull request removes the PTY-level keepalive mechanism from the SSH terminal backend to prevent unwanted ^@ characters from appearing in user terminals. The code now relies solely on SSH-level keepalive settings for connection health monitoring, which avoids producing visible output in the terminal. Documentation and references: * Added comments explaining that SSH-level keepalive is now handled via `connectConfig` options (`keepaliveInterval`, `keepaliveCountMax`, `tcpKeepAlive`) and included references to relevant GitHub issues for further context.…SH-level keepalive instead - [ ] Added: ... - [ ] Updated: ... - [ ] Removed: ... - [x] Fixed: ... * Removed the periodic writing of `\x00` to the SSH stream as a keepalive (previously done via `setupPingInterval` and `pingInterval`). This was causing visible control characters in terminals with `echoctl` enabled. * Cleaned up related code by removing the `pingInterval` variable and its setup/cleanup logic. [[1]](diffhunk://#diff-7f0fa8b35f8860de5ec33c197da5ad86aeb625737440c810a622ada38fedee51L319) [[2]](diffhunk://#diff-7f0fa8b35f8860de5ec33c197da5ad86aeb625737440c810a622ada38fedee51L805-L806) [[3]](diffhunk://#diff-7f0fa8b35f8860de5ec33c197da5ad86aeb625737440c810a622ada38fedee51L1282-L1286) # Changes Made - Removes PTY level keep-alive in favor of SSH Keep-alive options. # Related Issues - Closes #232 - Related to #232 # Screenshots / Demos https://vimeo.com/1147146616?share=copy&fl=sv&fe=ci # Checklist - [x] Code follows project style guidelines - [] Supports mobile and desktop UI/app (if applicable) --> Electron only. - [x] I have read [Contributing.md](https://github.com/Termix-SSH/Termix/blob/main/CONTRIBUTING.md)
LukeGus commented 2025-12-17 04:27:40 +00:00 (Migrated from github.com)

LGTM. I'll monitor over time to see if the removal of the keep-alive has any impact. I had added it in the past when users were reporting getting disconnected early.

LGTM. I'll monitor over time to see if the removal of the keep-alive has any impact. I had added it in the past when users were reporting getting disconnected early.
Sign in to join this conversation.