Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Mulitline does not work well on windows command prompt #69

Closed
mannharleen opened this issue Apr 27, 2020 · 11 comments
Closed

Mulitline does not work well on windows command prompt #69

mannharleen opened this issue Apr 27, 2020 · 11 comments

Comments

@mannharleen
Copy link

mannharleen commented Apr 27, 2020

For every update, a new bar is written ie. the original bar is not updated.
Instead of getting one line that updates (code #1), I get a separate line for every update (code #2)

code #1 
[Account             ] ████████████████████████████████████████ 100 | Progress=19/19 | Elapsed(s)=5
code #2
[Account             ] ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 1 | Progress=1/100 | Elapsed(s)=0 | ETA(s)=1
[Account             ] ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 1 | Progress=1/100 | Elapsed(s)=1 | ETA(s)=1
[Account             ] ░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░░ 1 | Progress=1/100 | Elapsed(s)=2 | ETA(s)=1

node=11
cli-progress=3.8.0
windows=8
terminal= Microsoft Windows [Version 6.3.9600]

@AndiDittrich
Copy link
Member

AndiDittrich commented Apr 27, 2020

can you provide a minimal example to reproduce the issue ?
which versions (node, cli-progress, windows, which kind of terminal/version) do you use ?

@mannharleen
Copy link
Author

mannharleen commented Apr 27, 2020

That was a really quick response!
I just some luck - I had to increase the screen buffer size of the command prompt. That made the bars update in-place. However, now I issue occurs when the terminal has to auto scroll down

@AndiDittrich
Copy link
Member

the windows command prompt doesn't work as expected. please use the powershell.
since the issue is raised on an old windows version i'm unable to test it - cli-progress is not designed for windows even it may work

generally the window has to be bigger then the number of total progress bars - see #59

@mannharleen
Copy link
Author

"cli-progress is not designed for windows even it may work" - it would be best mentioned on the README.md then

@AndiDittrich
Copy link
Member

maybe...but this issue affects any UI component within the standard command prompts on windows

@AndiDittrich
Copy link
Member

did you tried it with windows powershell on win10 ?

@mannharleen
Copy link
Author

Same issue with powershell.

@AndiDittrich
Copy link
Member

it works without any issues...the problem seems to be related to your environment (windows version, powershell version, environment config)

image

@AndiDittrich
Copy link
Member

std windows command prompt ...

image

@mannharleen
Copy link
Author

Thanks for your responses Andi. I've settled for how it is on Win8.
It would still help if README mentions that it works as expected on Win10 CMD version etc & above.

I dont have Win10, so cant verify at my end.

@AndiDittrich
Copy link
Member

i've already added a "weak" notice about windows platforms: https://github.com/AndiDittrich/Node.CLI-Progress#compatibility

btw. cli-progress is also used in NodeMCU-Tool which doesn't encountered any issue with older windows versions yet - therefore you're observed behaviour is very strange

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants