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 Pythia when item is being committed #54964

Merged
merged 2 commits into from
Jul 22, 2021
Merged

Conversation

genlu
Copy link
Member

@genlu genlu commented Jul 20, 2021

Address #53712

Question for @dibarbet @allisonchou If/how this can be hooked up in LSP?

@genlu genlu requested a review from a team as a code owner July 20, 2021 01:01
@genlu
Copy link
Member Author

genlu commented Jul 21, 2021

Sync'd with Intellicode team, LSP support for this callback can be added in future.
@dotnet/roslyn-ide could someone please take a look? thx!

// Make sure the notification isn't sent on UI thread.
await TaskScheduler.Default;
await notifyProvider.NotifyCommittingItemAsync(document, roslynItem, commitCharacter, cancellationToken).ConfigureAwait(false);
});
Copy link
Member

Choose a reason for hiding this comment

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

should we track exceptions with a reportnonfatalerror since this is fire and forget?

Also for tests, should this also be covered under an async listener - it also might make the test simpler as you can just wait for the async operation to complete

Copy link
Member Author

Choose a reason for hiding this comment

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

Makes sense, fixed. As of the test, since there's only one, I will just keep it as is.

@genlu genlu merged commit f6c6a6f into dotnet:main Jul 22, 2021
@ghost ghost added this to the Next milestone Jul 22, 2021
@genlu genlu deleted the NotifyCommit branch July 22, 2021 17:36
@allisonchou allisonchou modified the milestones: Next, 17.0.P3 Jul 27, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants