You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Unsure exact repro steps. Open .razor file and begin editing.
Description of the problem:
I routinely get invalid red and yellow squigglies when editing .razor files in VSCode. The application builds and runs fine, but the VSCode editor shows red and yellow underlines that are incorrect. If I hover over them they will say things like " Type or namespace could not be found", "Found markup with unexpected name", etc. Again, the app will build and run, so I know the problem is not the code.
Sometimes it gets really confused and the errors will be on old lines of code (ie if I add lines, the highlighting will not be on the correct line completely). Sometimes it ends up highlighting the entire document red. This makes it very frustrating to edit Blazor in VSCode.
I suspect it is the Language Service Provider. It's as though it's cached an old version of the code and not updating. Some other nuance/details that may or may not be relevant:
I am referencing a "Shared" blazor ui library project from multiple other blazor projects. Some of the issue seems to be it not recognizing shared components etc from the shared library.
I'm on a M1 MacBook
I use CoPilot. Sometimes the problem starts as CoPilot is applying it's diff.
Expected behavior:
If the app builds and is valid, no red squigglies show, and only valid yellow ones. If there are errors, they are highlighted in the correct place. In the event things to get out of wack, some way to completely reset the LSP (if that will fix it)
Actual behavior:
Red squigglies when the code is valid, yellow ones that are wrong.
Logs
OmniSharp
Not present
Razor
Expand
-- Starting Issue Data Collection--
Notifying document '/Users/anonymous/Code/MAPPNetwork/mappnetwork/MAPP.AdminPortal.WebUI/Components/Leads/LeadsGrid.razor' changed 'opened' with '0' changes.
64 - Synchronizing '/Users/anonymous/Code/MAPPNetwork/mappnetwork/MAPP.AdminPortal.WebUI/Components/Leads/LeadsGrid.razor__virtual.cs':
Currently at 12, synchronizing to version '13'.'
64 - Projected document not in sync with host document, waiting for update...
Current host document sync version: 12
65 - Synchronizing '/Users/anonymous/Code/MAPPNetwork/mappnetwork/MAPP.AdminPortal.WebUI/Components/Leads/LeadsGrid.razor__virtual.html':
Currently at 12, synchronizing to version '13'.'
65 - Projected document not in sync with host document, waiting for update...
Current host document sync version: 12
Updating the HTML document for Razor file '/Users/anonymous/Code/MAPPNetwork/mappnetwork/MAPP.AdminPortal.WebUI/Components/Leads/LeadsGrid.razor' (13)
Notifying document '/Users/anonymous/Code/MAPPNetwork/mappnetwork/MAPP.AdminPortal.WebUI/Components/Leads/LeadsGrid.razor' changed 'htmlChanged' with '0' changes.
65 - Projected document in sync with host document
65 - Projected text document not in sync with data type, waiting for update...
Current projected text document sync version: 12
Updating the C# document for Razor file '/Users/anonymous/Code/MAPPNetwork/mappnetwork/MAPP.AdminPortal.WebUI/Components/Leads/LeadsGrid.razor' (13)
Notifying document '/Users/anonymous/Code/MAPPNetwork/mappnetwork/MAPP.AdminPortal.WebUI/Components/Leads/LeadsGrid.razor' changed 'csharpChanged' with '0' changes.
64 - Projected document in sync with host document
64 - Projected text document not in sync with data type, waiting for update...
Current projected text document sync version: 12
66 - Synchronizing '/Users/anonymous/Code/MAPPNetwork/mappnetwork/MAPP.AdminPortal.WebUI/Components/Leads/LeadsGrid.razor__virtual.cs':
Currently at 13, synchronizing to version '13'.'
66 - Projected document in sync with host document
66 - Projected text document not in sync with data type, waiting for update...
Current projected text document sync version: 12
67 - Synchronizing '/Users/anonymous/Code/MAPPNetwork/mappnetwork/MAPP.AdminPortal.WebUI/Components/Leads/LeadsGrid.razor__virtual.cs':
Currently at 13, synchronizing to version '13'.'
67 - Projected document in sync with host document
67 - Projected text document not in sync with data type, waiting for update...
Current projected text document sync version: 12
65 - Projected text document synchronized to 13.
65 - Projected text document in sync with data type
65 - Synchronization successful!
64 - Projected text document synchronized to 13.
66 - Projected text document synchronized to 13.
67 - Projected text document synchronized to 13.
64 - Projected text document in sync with data type
64 - Synchronization successful!
66 - Projected text document in sync with data type
66 - Synchronization successful!
67 - Projected text document in sync with data type
67 - Synchronization successful!
68 - Synchronizing '/Users/anonymous/Code/MAPPNetwork/mappnetwork/MAPP.AdminPortal.WebUI/Components/Leads/LeadsGrid.razor__virtual.cs':
Currently at 13, synchronizing to version '13'.'
68 - Projected document in sync with host document
68 - Projected text document in sync with data type
68 - Synchronization successful!
69 - Synchronizing '/Users/anonymous/Code/MAPPNetwork/mappnetwork/MAPP.AdminPortal.WebUI/Components/Leads/LeadsGrid.razor__virtual.cs':
Currently at 13, synchronizing to version '13'.'
69 - Projected document in sync with host document
69 - Projected text document in sync with data type
69 - Synchronization successful!
70 - Synchronizing '/Users/anonymous/Code/MAPPNetwork/mappnetwork/MAPP.AdminPortal.WebUI/Components/Leads/LeadsGrid.razor__virtual.cs':
Currently at 13, synchronizing to version '13'.'
70 - Projected document in sync with host document
70 - Projected text document in sync with data type
70 - Synchronization successful!
71 - Synchronizing '/Users/anonymous/Code/MAPPNetwork/mappnetwork/MAPP.AdminPortal.WebUI/Components/Leads/LeadsGrid.razor__virtual.cs':
Currently at 13, synchronizing to version '13'.'
71 - Projected document in sync with host document
71 - Projected text document in sync with data type
71 - Synchronization successful!
72 - Synchronizing '/Users/anonymous/Code/MAPPNetwork/mappnetwork/MAPP.AdminPortal.WebUI/Components/Leads/LeadsGrid.razor__virtual.html':
Currently at 13, synchronizing to version '13'.'
72 - Projected document in sync with host document
72 - Projected text document in sync with data type
72 - Synchronization successful!
73 - Synchronizing '/Users/anonymous/Code/MAPPNetwork/mappnetwork/MAPP.AdminPortal.WebUI/Components/Leads/LeadsGrid.razor__virtual.cs':
Currently at 13, synchronizing to version '13'.'
73 - Projected document in sync with host document
73 - Projected text document in sync with data type
73 - Synchronization successful!
74 - Synchronizing '/Users/anonymous/Code/MAPPNetwork/mappnetwork/MAPP.AdminPortal.WebUI/Components/Leads/LeadsGrid.razor__virtual.cs':
Currently at 13, synchronizing to version '13'.'
74 - Projected document in sync with host document
74 - Projected text document in sync with data type
74 - Synchronization successful!
75 - Synchronizing '/Users/anonymous/Code/MAPPNetwork/mappnetwork/MAPP.AdminPortal.WebUI/Components/Leads/LeadsGrid.razor__virtual.cs':
Currently at 13, synchronizing to version '13'.'
75 - Projected document in sync with host document
75 - Projected text document in sync with data type
75 - Synchronization successful!
76 - Synchronizing '/Users/anonymous/Code/MAPPNetwork/mappnetwork/MAPP.AdminPortal.WebUI/Components/Leads/LeadsGrid.razor__virtual.cs':
Currently at 13, synchronizing to version '13'.'
76 - Projected document in sync with host document
76 - Projected text document in sync with data type
76 - Synchronization successful!
77 - Synchronizing '/Users/anonymous/Code/MAPPNetwork/mappnetwork/MAPP.AdminPortal.WebUI/Components/Leads/LeadsGrid.razor__virtual.cs':
Currently at 13, synchronizing to version '13'.'
77 - Projected document in sync with host document
77 - Projected text document in sync with data type
77 - Synchronization successful!
78 - Synchronizing '/Users/anonymous/Code/MAPPNetwork/mappnetwork/MAPP.AdminPortal.WebUI/Components/Leads/LeadsGrid.razor__virtual.cs':
Currently at 13, synchronizing to version '13'.'
78 - Projected document in sync with host document
78 - Projected text document in sync with data type
78 - Synchronization successful!
79 - Synchronizing '/Users/anonymous/Code/MAPPNetwork/mappnetwork/MAPP.AdminPortal.WebUI/Components/Leads/LeadsGrid.razor__virtual.cs':
Currently at 13, synchronizing to version '13'.'
79 - Projected document in sync with host document
79 - Projected text document in sync with data type
79 - Synchronization successful!
80 - Synchronizing '/Users/anonymous/Code/MAPPNetwork/mappnetwork/MAPP.AdminPortal.WebUI/Components/Leads/LeadsGrid.razor__virtual.cs':
Currently at 13, synchronizing to version '13'.'
80 - Projected document in sync with host document
80 - Projected text document in sync with data type
80 - Synchronization successful!
81 - Synchronizing '/Users/anonymous/Code/MAPPNetwork/mappnetwork/MAPP.AdminPortal.WebUI/Components/Leads/LeadsGrid.razor__virtual.cs':
Currently at 13, synchronizing to version '13'.'
81 - Projected document in sync with host document
81 - Projected text document in sync with data type
81 - Synchronization successful!
82 - Synchronizing '/Users/anonymous/Code/MAPPNetwork/mappnetwork/MAPP.AdminPortal.WebUI/Components/Leads/LeadsGrid.razor__virtual.cs':
Currently at 13, synchronizing to version '13'.'
82 - Projected document in sync with host document
82 - Projected text document in sync with data type
82 - Synchronization successful!
83 - Synchronizing '/Users/anonymous/Code/MAPPNetwork/mappnetwork/MAPP.AdminPortal.WebUI/Components/Leads/LeadsGrid.razor__virtual.cs':
Currently at 13, synchronizing to version '13'.'
83 - Projected document in sync with host document
83 - Projected text document in sync with data type
83 - Synchronization successful!
84 - Synchronizing '/Users/anonymous/Code/MAPPNetwork/mappnetwork/MAPP.AdminPortal.WebUI/Components/Leads/LeadsGrid.razor__virtual.cs':
Currently at 13, synchronizing to version '13'.'
84 - Projected document in sync with host document
84 - Projected text document in sync with data type
84 - Synchronization successful!
85 - Synchronizing '/Users/anonymous/Code/MAPPNetwork/mappnetwork/MAPP.AdminPortal.WebUI/Components/Leads/LeadsGrid.razor__virtual.cs':
Currently at 13, synchronizing to version '13'.'
85 - Projected document in sync with host document
85 - Projected text document in sync with data type
85 - Synchronization successful!
86 - Synchronizing '/Users/anonymous/Code/MAPPNetwork/mappnetwork/MAPP.AdminPortal.WebUI/Components/Leads/LeadsGrid.razor__virtual.cs':
Currently at 13, synchronizing to version '13'.'
86 - Projected document in sync with host document
86 - Projected text document in sync with data type
86 - Synchronization successful!
87 - Synchronizing '/Users/anonymous/Code/MAPPNetwork/mappnetwork/MAPP.AdminPortal.WebUI/Components/Leads/LeadsGrid.razor__virtual.cs':
Currently at 13, synchronizing to version '13'.'
87 - Projected document in sync with host document
87 - Projected text document in sync with data type
87 - Synchronization successful!
88 - Synchronizing '/Users/anonymous/Code/MAPPNetwork/mappnetwork/MAPP.AdminPortal.WebUI/Components/Leads/LeadsGrid.razor__virtual.cs':
Currently at 13, synchronizing to version '13'.'
88 - Projected document in sync with host document
88 - Projected text document in sync with data type
88 - Synchronization successful!
89 - Synchronizing '/Users/anonymous/Code/MAPPNetwork/mappnetwork/MAPP.AdminPortal.WebUI/Components/Leads/LeadsGrid.razor__virtual.cs':
Currently at 13, synchronizing to version '13'.'
89 - Projected document in sync with host document
89 - Projected text document in sync with data type
89 - Synchronization successful!
90 - Synchronizing '/Users/anonymous/Code/MAPPNetwork/mappnetwork/MAPP.AdminPortal.WebUI/Components/Leads/LeadsGrid.razor__virtual.cs':
Currently at 13, synchronizing to version '13'.'
90 - Projected document in sync with host document
90 - Projected text document in sync with data type
90 - Synchronization successful!
91 - Synchronizing '/Users/anonymous/Code/MAPPNetwork/mappnetwork/MAPP.AdminPortal.WebUI/Components/Leads/LeadsGrid.razor__virtual.cs':
Currently at 13, synchronizing to version '13'.'
91 - Projected document in sync with host document
91 - Projected text document in sync with data type
91 - Synchronization successful!
92 - Synchronizing '/Users/anonymous/Code/MAPPNetwork/mappnetwork/MAPP.AdminPortal.WebUI/Components/Leads/LeadsGrid.razor__virtual.cs':
Currently at 13, synchronizing to version '13'.'
92 - Projected document in sync with host document
92 - Projected text document in sync with data type
92 - Synchronization successful!
93 - Synchronizing '/Users/anonymous/Code/MAPPNetwork/mappnetwork/MAPP.AdminPortal.WebUI/Components/Leads/LeadsGrid.razor__virtual.cs':
Currently at 13, synchronizing to version '13'.'
93 - Projected document in sync with host document
93 - Projected text document in sync with data type
93 - Synchronization successful!
94 - Synchronizing '/Users/anonymous/Code/MAPPNetwork/mappnetwork/MAPP.AdminPortal.WebUI/Components/Leads/LeadsGrid.razor__virtual.cs':
Currently at 13, synchronizing to version '13'.'
94 - Projected document in sync with host document
94 - Projected text document in sync with data type
94 - Synchronization successful!
95 - Synchronizing '/Users/anonymous/Code/MAPPNetwork/mappnetwork/MAPP.AdminPortal.WebUI/Components/Leads/LeadsGrid.razor__virtual.cs':
Currently at 13, synchronizing to version '13'.'
95 - Projected document in sync with host document
95 - Projected text document in sync with data type
95 - Synchronization successful!
96 - Synchronizing '/Users/anonymous/Code/MAPPNetwork/mappnetwork/MAPP.AdminPortal.WebUI/Components/Leads/LeadsGrid.razor__virtual.cs':
Currently at 13, synchronizing to version '13'.'
96 - Projected document in sync with host document
96 - Projected text document in sync with data type
96 - Synchronization successful!
97 - Synchronizing '/Users/anonymous/Code/MAPPNetwork/mappnetwork/MAPP.AdminPortal.WebUI/Components/Leads/LeadsGrid.razor__virtual.cs':
Currently at 13, synchronizing to version '13'.'
97 - Projected document in sync with host document
97 - Projected text document in sync with data type
97 - Synchronization successful!
98 - Synchronizing '/Users/anonymous/Code/MAPPNetwork/mappnetwork/MAPP.AdminPortal.WebUI/Components/Leads/LeadsGrid.razor__virtual.cs':
Currently at 13, synchronizing to version '13'.'
98 - Projected document in sync with host document
98 - Projected text document in sync with data type
98 - Synchronization successful!
99 - Synchronizing '/Users/anonymous/Code/MAPPNetwork/mappnetwork/MAPP.AdminPortal.WebUI/Components/Leads/LeadsGrid.razor__virtual.cs':
Currently at 13, synchronizing to version '13'.'
99 - Projected document in sync with host document
99 - Projected text document in sync with data type
99 - Synchronization successful!
100 - Synchronizing '/Users/anonymous/Code/MAPPNetwork/mappnetwork/MAPP.AdminPortal.WebUI/Components/Leads/LeadsGrid.razor__virtual.cs':
Currently at 13, synchronizing to version '13'.'
100 - Projected document in sync with host document
100 - Projected text document in sync with data type
100 - Synchronization successful!
101 - Synchronizing '/Users/anonymous/Code/MAPPNetwork/mappnetwork/MAPP.AdminPortal.WebUI/Components/Leads/LeadsGrid.razor__virtual.cs':
Currently at 13, synchronizing to version '13'.'
101 - Projected document in sync with host document
101 - Projected text document in sync with data type
101 - Synchronization successful!
102 - Synchronizing '/Users/anonymous/Code/MAPPNetwork/mappnetwork/MAPP.AdminPortal.WebUI/Components/Leads/LeadsGrid.razor__virtual.cs':
Currently at 13, synchronizing to version '13'.'
102 - Projected document in sync with host document
102 - Projected text document in sync with data type
102 - Synchronization successful!
103 - Synchronizing '/Users/anonymous/Code/MAPPNetwork/mappnetwork/MAPP.AdminPortal.WebUI/Components/Leads/LeadsGrid.razor__virtual.cs':
Currently at 13, synchronizing to version '13'.'
103 - Projected document in sync with host document
103 - Projected text document in sync with data type
103 - Synchronization successful!
Unable to remap file /Users/anonymous/Code/MAPPNetwork/mappnetwork/MAPP.ProfessionalPortal.WebUI/Components/Leads/LeadsGrid.razor__virtual.cs at [983:19, 983:39].
104 - Synchronizing '/Users/anonymous/Code/MAPPNetwork/mappnetwork/MAPP.AdminPortal.WebUI/Components/Leads/LeadsGrid.razor__virtual.cs':
Currently at 13, synchronizing to version '13'.'
104 - Projected document in sync with host document
104 - Projected text document in sync with data type
104 - Synchronization successful!
105 - Synchronizing '/Users/anonymous/Code/MAPPNetwork/mappnetwork/MAPP.AdminPortal.WebUI/Components/Leads/LeadsGrid.razor__virtual.cs':
Currently at 13, synchronizing to version '13'.'
105 - Projected document in sync with host document
105 - Projected text document in sync with data type
105 - Synchronization successful!
-- Stopping Issue Data Collection--
Is this a Bug or Feature request?:
Bug
Steps to reproduce:
Unsure exact repro steps. Open .razor file and begin editing.
Description of the problem:
I routinely get invalid red and yellow squigglies when editing .razor files in VSCode. The application builds and runs fine, but the VSCode editor shows red and yellow underlines that are incorrect. If I hover over them they will say things like " Type or namespace could not be found", "Found markup with unexpected name", etc. Again, the app will build and run, so I know the problem is not the code.
Sometimes it gets really confused and the errors will be on old lines of code (ie if I add lines, the highlighting will not be on the correct line completely). Sometimes it ends up highlighting the entire document red. This makes it very frustrating to edit Blazor in VSCode.
I suspect it is the Language Service Provider. It's as though it's cached an old version of the code and not updating. Some other nuance/details that may or may not be relevant:
Expected behavior:
If the app builds and is valid, no red squigglies show, and only valid yellow ones. If there are errors, they are highlighted in the correct place. In the event things to get out of wack, some way to completely reset the LSP (if that will fix it)
Actual behavior:

Red squigglies when the code is valid, yellow ones that are wrong.
Logs
OmniSharp
Not present
Razor
Expand
Workspace information
Razor document:
(Omitted - too long for github)
Machine information
VSCode version: 1.100.0
Razor.VSCode version: 2.76.27
dotnet --info
Expand
Extensions
Expand
The text was updated successfully, but these errors were encountered: