-
Notifications
You must be signed in to change notification settings - Fork 8
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
fix: always finish progress in autofixing #478
fix: always finish progress in autofixing #478
Conversation
p.ReportWithMessage(int(math.Max(tries, 99)), "Polling for fix...") | ||
fix, complete := pollFunc() | ||
if !complete { | ||
tries++ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is this logic to set a ceiling to the max number of retries?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nope, it's just to not report more than a 100% (timeout is currently set to 120, and didn't want to implement a complicated logic with rounding to integers afterwards). But I should use Min, not Max. Oops.
…tofix-fails' into fix/finish-progress-also-when-autofix-fails
p.ReportWithMessage(int(math.Min(tries, 99)), "Polling for fix...") | ||
fix, complete := pollFunc() | ||
if !complete { | ||
tries++ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this is going it be showing 99 until tries passes 99, right? We are not aiming to show a progress I understand
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Now, it's gonna show a progress up to the 99s limit - with Max it was only showing 99...
Description
Provide description of this PR and changes, if linked Jira ticket doesn't cover it in full.
Checklist
🚨After having merged, please update the CLI go.mod to pull in latest language server.
Screenshots / GIFs
Visuals that may help the reviewer. Please add screenshots for any UI change. GIFs are most welcome!