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

Notify build is preparing before progress starts #1323

Merged

Conversation

plemarquand
Copy link
Contributor

The build progress notification would only appear once the progress values were shown in the output, i.e. [12/122]. Until progress values appear, show a "Preparing " notification. This only needs to apply when the showBuildStatus value is notification or progress, since swiftStatus already shows a message in the bar immediately.

This patch also only sets the showBuildStatus setting on a Task if it is coming from a user defined task. Previously it was being set on synthetic tasks which were being cached, so when the user updated the showBuildStatus setting it wouldn't take effect until they restarted the extension.

Issue: #1322

The build progress notification would only appear once the progress
values were shown in the output, i.e. [12/122]. Until progress values
appear, show a "Preparing <task>" notification. This only needs to apply
when the `showBuildStatus` value is `notification` or `progress`, since
`swiftStatus` already shows a message in the bar immediately.

This patch also only sets the `showBuildStatus` setting on a Task if it
is coming from a user defined task. Previously it was being set on
synthetic tasks which were being cached, so when the user updated the
`showBuildStatus` setting it wouldn't take effect until they restarted
the extension.

Issue: swiftlang#1322
@plemarquand
Copy link
Contributor Author

cc @MahdiBM

Copy link
Contributor

@MahdiBM MahdiBM left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you. A minor annoyance that will no longer exist!

src/ui/SwiftBuildStatus.ts Outdated Show resolved Hide resolved
src/tasks/SwiftTaskProvider.ts Show resolved Hide resolved
src/ui/SwiftBuildStatus.ts Outdated Show resolved Hide resolved
Copy link
Contributor

@award999 award999 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Some minor things

@plemarquand plemarquand merged commit d88a5c8 into swiftlang:main Jan 21, 2025
14 of 15 checks passed
@plemarquand plemarquand deleted the faster-build-progress-notification branch January 21, 2025 19:10
plemarquand added a commit to plemarquand/vscode-swift that referenced this pull request Jan 23, 2025
Previously we were waiting for output from the build, which could be
several seconds.

Issue: swiftlang#1323
award999 pushed a commit that referenced this pull request Jan 23, 2025
* Show build preparing status immediately

Previously we were waiting for output from the build, which could be
several seconds.

Issue: #1323

* Fixup test
plemarquand added a commit to plemarquand/vscode-swift that referenced this pull request Jan 23, 2025
award999 pushed a commit that referenced this pull request Jan 23, 2025
@award999
Copy link
Contributor

Verified with fa4d12c

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

Successfully merging this pull request may close these issues.

3 participants