Skip to content

Merge 'main' into Unions#82433

Merged
AlekseyTs merged 104 commits into
dotnet:features/Unionsfrom
AlekseyTs:Unions_17
Feb 17, 2026
Merged

Merge 'main' into Unions#82433
AlekseyTs merged 104 commits into
dotnet:features/Unionsfrom
AlekseyTs:Unions_17

Conversation

@AlekseyTs

Copy link
Copy Markdown
Contributor

No description provided.

Copilot AI and others added 30 commits December 10, 2025 00:30
Co-authored-by: dibarbet <5749229+dibarbet@users.noreply.github.com>
… acronym

Co-authored-by: dibarbet <5749229+dibarbet@users.noreply.github.com>
…irectory location, fix resource extraction guidance

Co-authored-by: dibarbet <5749229+dibarbet@users.noreply.github.com>
Co-authored-by: dibarbet <5749229+dibarbet@users.noreply.github.com>
Co-authored-by: dibarbet <5749229+dibarbet@users.noreply.github.com>
Co-authored-by: jasonmalinowski <201340+jasonmalinowski@users.noreply.github.com>
When we start a solution sync, we base it on the last synced 'primary'
solution if that solution has the same ID and path, or otherwise we'll
synchronize the solution over from scratch. During solution load this
isn't ideal -- we might have not synchronized the primary solution
over fully, but might have still done a partial sync that has some
information that's usable, and it's better to use that rather than
do another sync from scratch. So before we decide to do a from-scratch
sync, see if we can reuse something else.
This makes a few general changes to how we cache drivers so we don't
re-initialize them multiple times when we're first loading a solution.

1. Rather than the cache being a ProjectId -> cached driver map,
   we instead hold that map in the SolutionCompilationState, where it
   nicely fits with our other maps holding onto generator-related
   state.
2. Rather than clearing out the cached driver once we think we won't
   need it, we just continually refresh the cached driver with the
   latest version. This simplifies the logic and also ensures we won't
   ever clear something out that we would need later, but still
   keeps us from holding onto old state.
3. Rather than explicitly clearing out the initialized driver when we
   have to rerun generators, we keep it around, and insetad create a
   new driver cache for the new snapshot.
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
```
2026-02-04T23:22:30.633Z [DEBUG] LSP csharp server for C:\Users\dabarbet\source\repos\aspire: [stderr] Unhandled exception. System.NullReferenceException: Object reference not set to an instance of an object.
   at Microsoft.CodeAnalysis.LanguageServer.HostWorkspace.FileWatching.DefaultFileChangeWatcher.FileChangeContext.Microsoft.CodeAnalysis.LanguageServer.HostWorkspace.FileWatching.DefaultFileChangeWatcher.IEventRaiser.RaiseEvent(Object sender, FileSystemEventArgs e) in /_/src/LanguageServer/Microsoft.CodeAnalysis.LanguageServer/HostWorkspace/FileWatching/DefaultFileChangeWatcher.FileChangeContext.cs:line 60
   at System.IO.FileSystemWatcher.NotifyFileSystemEventArgs(WatcherChangeTypes changeType, ReadOnlySpan`1 name)
   at System.IO.FileSystemWatcher.ParseEventBufferAndNotifyForEach(ReadOnlySpan`1 buffer)
   at System.IO.FileSystemWatcher.ReadDirectoryChangesCallback(UInt32 errorCode, UInt32 numBytes, AsyncReadState state)
   at System.IO.FileSystemWatcher.<>c.<StartRaisingEvents>b__84_0(UInt32 errorCode, UInt32 numBytes, NativeOverlapped* overlappedPointer)
   at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state)
--- End of stack trace from previous location ---
   at System.Threading.ExecutionContext.RunInternal(ExecutionContext executionContext, ContextCallback callback, Object state)
   at System.Threading.ThreadPoolTypedWorkItemQueue.System.Threading.IThreadPoolWorkItem.Execute()
   at System.Threading.ThreadPoolWorkQueue.Dispatch()
   at System.Threading.PortableThreadPool.WorkerThread.WorkerThreadStart()
   at System.Threading.Thread.StartCallback()
```
Excludes the test resources assembly from signing by setting
CertificateName="None" since this is a non-shipping test utility
assembl, it does not require signing. Also removes the dlls from the
test resources since they're no longer used by any tests.
Followup to dotnet#82251

Co-authored-by: Cyrus Najmabadi <Cyrus Najmabadi>
dibarbet and others added 18 commits February 13, 2026 10:34
…net#82359)

While investigating a report of ServiceHub consuming a large amount of
memory, I noticed the unit testing solution crawler queue was quite
large, and (at least at the point of the dump) it was running source
generators to add the source generated files to the queue. When chatting
with the unit testing team, it's not clear that's really a scenario we
need to support in the first place, so as a performance test we'd like
to simply disable that.

This defines a new setting to disable this, and wires it up to a feature
flag for us to experiment with this. The core code change is minimial --
most of this is defining a new roslyn setting that's not language
specific, and passing the boolean around.
Adds an instruction to set the DOTNET_CLI_WORKLOAD_UPDATE_NOTIFY_DISABLE
before any dotnet command.
… itself to check for existence of a setter/getter (dotnet#82390)

GetOwnOrInheritedSetMethod/GetOwnOrInheritedGetMethod are used when
compiler decides whether read/write operations are possible for a
property.

Fixes dotnet#82122
Co-authored-by: dibarbet <5749229+dibarbet@users.noreply.github.com>
…Language Server (dotnet#82411)

Starred completions in the Language Server were implemented as a special
IntelliCode extension integration path. Since that extension path is
deprecated, this PR removes the StarredCompletions-specific code and
simplifies startup/configuration and extension loading.

- **Removed StarredCompletions feature implementation**
  - Deleted `Services/StarredCompletions/StarredCompletionProvider.cs`
- Deleted
`Services/StarredCompletions/StarredCompletionsAssemblyHelper.cs`

- **Removed server startup/configuration plumbing**
  - Dropped `--starredCompletionComponentPath` from `Program.cs`
- Removed `StarredCompletionAssemblyHelper.InitializeInstance(...)` call
- Removed `StarredCompletionsPath` from `ServerConfiguration`
(`ServerConfigurationFactory.cs`)
- Updated test configuration construction to stop passing
`StarredCompletionsPath`

- **Simplified extension assembly loading**
- Removed the special-case IntelliCode load-context hack in
`ExtensionAssemblyManager.Create(...)`
- Extension loading now only processes explicit extension assembly paths

Example of the config simplification:

```csharp
internal sealed record class ServerConfiguration(
    bool LaunchDebugger,
    LogConfiguration LogConfiguration,
    string? TelemetryLevel,
    string? SessionId,
    IEnumerable<string> ExtensionAssemblyPaths,
    string? DevKitDependencyPath,
    string? RazorDesignTimePath,
    string? CSharpDesignTimePath,
    string? ServerPipeName,
    bool UseStdIo,
    string? ExtensionLogDirectory,
    bool AutoLoadProjects,
    SourceGeneratorExecutionPreference SourceGeneratorExecutionPreference,
    int? ClientProcessId);
```

> [!WARNING]
>
> <details>
> <summary>Firewall rules blocked me from connecting to one or more
addresses (expand for details)</summary>
>
> #### I tried to connect to the following addresses, but was blocked by
firewall rules:
>
> - `vb4vsblobprodcus33.vsblob.vsassets.io`
> - Triggering command: `/usr/share/dotnet/dotnet dotnet test
src/LanguageServer/ProtocolUnitTests/Microsoft.CodeAnalysis.LanguageServer.Protocol.UnitTests.csproj
-v minimal` (dns block)
>
> If you need me to access, download, or install something from one of
these locations, you can either:
>
> - Configure [Actions setup
steps](https://gh.io/copilot/actions-setup-steps) to set up my
environment, which run before the firewall is enabled
> - Add the appropriate URLs or hosts to the custom allowlist in this
repository's [Copilot coding agent
settings](https://github.com/dotnet/roslyn/settings/copilot/coding_agent)
(admins only)
>
> </details>

<!-- START COPILOT CODING AGENT TIPS -->
---

✨ Let Copilot coding agent [set things up for
you](https://github.com/dotnet/roslyn/issues/new?title=✨+Set+up+Copilot+instructions&body=Configure%20instructions%20for%20this%20repository%20as%20documented%20in%20%5BBest%20practices%20for%20Copilot%20coding%20agent%20in%20your%20repository%5D%28https://gh.io/copilot-coding-agent-tips%29%2E%0A%0A%3COnboard%20this%20repo%3E&assignees=copilot)
— coding agent works faster and does higher quality work when set up for
your repo.
…otnet#82376)

This has a few miscellaneous changes to improve process lifecycle stuff.

1. Update the support for named pipe as a process argument (LSP spec
details -
https://microsoft.github.io/language-server-protocol/specifications/lsp/3.17/specification/#implementationConsiderations)
to work better with the VSCode client
2. Ensure service broker bridge cancels properly if we need to stop the
process on our side to prevent lingering processes
3. Ensure the process reports errors when we encounter an exception in
the LSP queue that takes down the server. Previously the process would
cleanly exit even if we decided to shutdown due to an issue in the LSP
queue loop.

Needs to be paired with
dotnet/vscode-csharp#8982
@AlekseyTs AlekseyTs requested a review from a team as a code owner February 17, 2026 19:52
@AlekseyTs AlekseyTs requested review from a team as code owners February 17, 2026 19:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.