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

spinner does not update according to its phases if there are too few state modification #166

Open
mandelsoft opened this issue Aug 20, 2023 · 1 comment

Comments

@mandelsoft
Copy link

The spinner only updates its rendered state, if the content of the bar is changed. If this happens not often enough the spinner character is not updated.

For example:

`       bar := progressbar.NewOptions(-1, progressbar.OptionSetDescription("test"), progressbar.OptionSpinnerType(15))
	for i := 0; i < 10; i++ {
		bar.Describe(fmt.Sprintf("test"))
		time.Sleep(1000 * time.Millisecond)
	}

It should iterate all letters, but it only shows a new letter if a Describe is called. As a result the spinner effect is gone.

@schollz
Copy link
Owner

schollz commented Feb 24, 2024

pr welcome

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

No branches or pull requests

2 participants