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

Fix provisional completion corrupting generated C# documents #10806

Merged

Conversation

davidwengier
Copy link
Contributor

Fixes #10759

Initially when investigating this I was digging into buffer versions and race conditions, but now that the editor fix is in, and we are self versioned, the bug stood out much more obviously: A character offset was being passed in to a parameter that expected a length 🤦‍♂️

Sadly none of the RazorCustomMessageTarget code is testable. Cohosting will make this trivial though, as we would simply create a new Document with the provisional change, and drop it on the floor when we're finished.

@davidwengier davidwengier requested a review from a team as a code owner August 28, 2024 06:57
@davidwengier davidwengier changed the base branch from main to release/dev17.12 August 28, 2024 06:59
@davidwengier
Copy link
Contributor Author

davidwengier commented Aug 28, 2024

@phil-allen-msft I think we should take this for 17.12 Preview 2. It was broken in Preview 1, and it's pretty easy to hit. Essentially depending on where you type it, typing a . in a Razor file will break sync with Roslyn until the document is closed.

@phil-allen-msft phil-allen-msft merged commit 8e11180 into dotnet:release/dev17.12 Aug 28, 2024
12 checks passed
@JoelleMarcChua
Copy link

Verified this issue does not repro in VS 17.12 Preview 2 now

@DustinCampbell
Copy link
Member

My bad on this one 😢

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.

Editor went and remained in a completely out of sync/broken state
4 participants