docker-archive / cloud-integration-beta

Docker CLI with ACI integration (beta)
https://www.docker.com
32 stars 14 forks source link

"docker logs --follow" output garbled #16

Closed karolz-ms closed 4 years ago

karolz-ms commented 4 years ago

Prereqs

Docker Desktop Edge build 46511 Windows Terminal 1.1.1671.0 (I install Windows Terminal via Scoop)

Repro steps

  1. Set up Windows Terminal so that it displays about 50 rows and 120 columns
  2. Deploy some container to ACI
  3. Do docker logs --follow container_name

Expected

The logs should be displayed as they are produced, without overwriting previous content in the terminal

Actual

The output of the command overwrites docker logs command invocation and even stuff that came before. Also, the same logs are re-printed repeatedly, garbling the previous output, see below.

 * Serving Flask app "app" (lazy loading)*****************************
 * Environment: productionloper Command Prompt v16.6.3
   WARNING: This is a development server. Do not use it in a production deployment.
   Use a production WSGI server instead.******************************
 * Debug mode: offs a development server. Do not use it in a production deployment.
 * Running on http://0.0.0.0:31117/ (Press CTRL+C to quit)
10.240.255.56 - - [07/Jul/2020 23:24:30] "GET / HTTP/1.1" 200 -oduction deployment.       PORTS
10.240.255.55 - - [07/Jul/2020 23:24:30] "GET /favicon.ico HTTP/1.1" 404 -ing             40.91.90.144:31117->31117/tcp
10.240.255.56 - - [07/Jul/2020 23:25:50] "GET / HTTP/1.1" 200 -oduction deployment.
10.240.255.55 - - [07/Jul/2020 23:25:53] "GET / HTTP/1.1" 200 -/1.1" 404 -
10.240.255.56 - - [07/Jul/2020 23:25:55] "GET / HTTP/1.1" 200 -oduction deployment.
10.240.255.56 - - [07/Jul/2020 23:26:02] "GET / HTTP/1.1" 200 -/1.1" 404 -
10.240.255.56 - - [07/Jul/2020 23:26:03] "GET / HTTP/1.1" 200 -oduction deployment.
10.240.255.55 - - [07/Jul/2020 23:26:04] "GET / HTTP/1.1" 200 -/1.1" 404 -
10.240.255.56 - - [07/Jul/2020 23:26:05] "GET / HTTP/1.1" 200 -
10.240.255.56 - - [07/Jul/2020 23:26:05] "GET / HTTP/1.1" 200 -/1.1" 404 -
10.240.255.55 - - [07/Jul/2020 23:26:06] "GET / HTTP/1.1" 200 -
10.240.255.56 - - [07/Jul/2020 23:26:06] "GET / HTTP/1.1" 200 -/1.1" 404 -
10.240.255.55 - - [07/Jul/2020 23:26:07] "GET / HTTP/1.1" 200 -
10.240.255.55 - - [07/Jul/2020 23:26:08] "GET / HTTP/1.1" 200 -
10.240.255.56 - - [07/Jul/2020 23:26:08] "GET / HTTP/1.1" 200 -
10.240.255.55 - - [07/Jul/2020 23:26:08] "GET / HTTP/1.1" 200 -
10.240.255.56 - - [07/Jul/2020 23:26:08] "GET / HTTP/1.1" 200 -
10.240.255.55 - - [07/Jul/2020 23:26:08] "GET / HTTP/1.1" 200 -
10.240.255.56 - - [07/Jul/2020 23:26:08] "GET / HTTP/1.1" 200 -
10.240.255.55 - - [07/Jul/2020 23:26:08] "GET / HTTP/1.1" 200 -
10.240.255.56 - - [07/Jul/2020 23:26:08] "GET / HTTP/1.1" 200 -
10.240.255.55 - - [07/Jul/2020 23:26:08] "GET / HTTP/1.1" 200 -
10.240.255.56 - - [07/Jul/2020 23:26:08] "GET / HTTP/1.1" 200 -
10.240.255.55 - - [07/Jul/2020 23:26:08] "GET / HTTP/1.1" 200 -
10.240.255.56 - - [07/Jul/2020 23:26:08] "GET / HTTP/1.1" 200 -
rumpl commented 4 years ago

@karolz-ms I haven't tried Windows Terminal indeed. Do you see the same garbled output on Powershell for example?

karolz-ms commented 4 years ago

@rumpl the same happens with Powershell window (I have set the window size to 120 columns x 50 rows)

rumpl commented 4 years ago

Found the culprit, the library we were using gave us always 80 for the terminal width so our calculations were always off...

chris-crone commented 4 years ago

This is fixed in the v0.10.0 build that will go out with Desktop Edge today.