grafana / k6

A modern load testing tool, using Go and JavaScript - https://k6.io
GNU Affero General Public License v3.0
24.77k stars 1.22k forks source link

Visual glitches on Windows terminals #1748

Open w1kman opened 3 years ago

w1kman commented 3 years ago

When running k6 (that exact command) in Command Prompt (CMD.exe), coloring breaks. There are no problems when running an actuall test (eg k6 run ...)

Checkmark displayed for passed tests, is also "broken"

Running Command Prompt via Windows Terminal seems to negate both problems.

Environment

Expected Behavior

Colored k6 logo (as when running Command Prompt via Windows Terminal) image

Checkmark in test result: image

Actual Behavior

Characters intended to color output are visible(ish) image

Boxed ? instead of checkmark in test result: image

Steps to Reproduce the Problem

  1. WIN+R
  2. Type cmd, click "Ok" (or press Enter)
  3. Type k6, Enter
jmk0317 commented 3 years ago

k6 javascript API check(val, sets, [tags]) - CLI - Windows 10 - from both the command prompt and PowerShell - returns this for the check mark

Screen Shot 2021-01-19 at 7 31 14 AM Screen Shot 2021-01-19 at 7 32 58 AM
na-- commented 3 years ago

https://github.com/loadimpact/k6/issues/957 shows that the k6 output in PowerShell has some artifacts, like µs instead of µs and some glitches in the logo.

na-- commented 3 years ago

Seems like Jenkins might have some of the same issues: https://github.com/loadimpact/k6/issues/1294

I'll rename this issue to be a more generic catch-all for all such visual glitches and UI problems in k6, so we don't have a bunch of related issues on the topic. And I guess the only "fix" for these would be to give users a way to disable them and use a simplified ASCII interface, e.g. via the proposed --ui-mode composite option (https://github.com/loadimpact/k6/issues/1376).

victorinho commented 3 years ago

I have the same problem that has been reported, I do not understand how I can solve it ... my version of k6 is: k6 v0.31.1

Can you help me how to solve it?

na-- commented 3 years ago

@victorinho, which of the multiple minor issues described here do you experience? Can you give a screenshot and some more details about your environment, like for example the terminal you use and the OS type and version?

victorinho commented 3 years ago

@victorinho, which of the multiple minor issues described here do you experience? Can you give a screenshot and some more details about your environment, like for example the terminal you use and the OS type and version?

Hello @na-- !

My problem is that some characters appear wrong as seen in the image. Attached image

My operating system is a windows 10 and the version of k6 is: v0.31.1

Screenshot_2

Thanks!

na-- commented 3 years ago

We'll try to fix this in the next k6 version, but I'm not giving any promises...

@victorinho, what terminal are you using to run k6? It seems like it doesn't support utf-8

victorinho commented 3 years ago

@na-- I am using windows command console (cmd)

Where can I run it from instead?

Regards

na-- commented 3 years ago

A more modern terminal like https://github.com/microsoft/terminal or https://cmder.net/ should work better.

immavalls commented 1 year ago

@na-- The user in https://community.k6.io/t/exporting-rate-to-json-looks-faulty/5707/14 mentions they can't use a more modern terminal and shares more details of what they see with powershell / command prompt and AzureDevOps.

RafaMalicia commented 10 months ago

Hi, does anyone know how to solve this? I'm getting these odd characters, I'm running k6 on Azure DevOps Release Job

Run Info:

2023-10-03T20:01:35.0002052Z Task : Command line 2023-10-03T20:01:35.0002115Z Description : Run a command line script using Bash on Linux and macOS and cmd.exe on Windows 2023-10-03T20:01:35.0002256Z Version : 2.212.0 2023-10-03T20:01:35.0002318Z Author : Microsoft Corporation 2023-10-03T20:01:35.0002393Z Help : https://docs.microsoft.com/azure/devops/pipelines/tasks/utility/command-line

image