mirror of
https://github.com/GNS3/gns3-server.git
synced 2026-11-03 14:01:15 +02:00
docker: give the docker_exec console a tall default PTY geometry
The docker_exec console resized its exec PTY to 80x24 until a client sent NAWS. CLIs that page on the PTY window size instead of the terminal length (the IOS-XR pager) therefore parked long output at --More-- for clients that never negotiate NAWS — netmiko, bare telnet — making copilot device commands time out on XRd. Default the exec to 511x10000 instead (511 matches netmiko's own 'terminal width 511' convention): no paging and no hard wrapping for non-NAWS clients, while real NAWS clients keep resizing to their actual geometry as before. Also updates the project memory record with the confirmed root cause and the fix.
This commit is contained in:
4 files changed
+52
-47
No files matched your search
@@ -504,7 +504,14 @@ class _LazyExecTelnetServer(AsyncioTelnetServer):
|
||||
log.warning(f"{self._log_name}: failed to create exec: {exc}", exc_info=True)
|
||||
raise
|
||||
try:
|
||||
await self._on_naws(80, 24) # initial size before NAWS
|
||||
# Tall/wide default geometry before any NAWS arrives: a
|
||||
# 24-row PTY makes CLIs that page on the PTY window size
|
||||
# (e.g. the IOS-XR pager) park at --More-- for clients
|
||||
# that never negotiate NAWS (netmiko, bare telnet).
|
||||
# Width 511 matches netmiko's 'terminal width 511'.
|
||||
# Real NAWS clients resize to their own geometry right
|
||||
# after connecting.
|
||||
await self._on_naws(511, 10000)
|
||||
except Exception:
|
||||
pass
|
||||
else:
|
||||
|
||||
Reference in new issue
Block a user