Skip to content

Conversation

@CyrusNajmabadi
Copy link
Member

Backport #78146 and #78353 to dev17.14

@CyrusNajmabadi CyrusNajmabadi requested review from a team as code owners May 7, 2025 21:51
@ghost ghost added Area-IDE untriaged Issues and PRs which have not yet been triaged by a lead labels May 7, 2025
Followup to dotnet#78356.

Needed so we can access IDiagAnalyzerService in OOP. Currently one
cannot as it attempts to access the Workspace of a document passed into
it. We block WOrkspace access like for safety/clarity concerns (we don't
want a stateless OOP api call to have access to the mutable workspace
API).

This also cleans up some ugly initialization code IDiagAnalyzerService
had.
@dibarbet
Copy link
Member

dibarbet commented May 9, 2025

/azp run roslyn-integration-CI

@azure-pipelines
Copy link

Azure Pipelines successfully started running 1 pipeline(s).

Copy link
Contributor

@maryamariyan maryamariyan left a comment

Choose a reason for hiding this comment

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

I skimmed through both the original PRs and this backport, and everything looks good to me. Is there a reason this backport wasn't done as a routine cherry-pick? Just wanted to confirm in case this was a manual backport, as that can make cross-referencing a bit trickier.

Let me know if there are specific files you'd like me to review more closely, especially if any parts of the backport were non-trivial

@CyrusNajmabadi
Copy link
Member Author

@maryamariyan I'm not sure what you mean. This was done with cherry picking the four prs related to this feature from main. Could you clarify what you mean?

workspace.TryApplyChanges(workspace.CurrentSolution.WithAnalyzerReferences([analyzerReference]));

var diagnosticService = workspace.GetService<IDiagnosticAnalyzerService>();
var diagnosticService = workspace.Services.GetRequiredService<IDiagnosticAnalyzerService>();
Copy link
Member

Choose a reason for hiding this comment

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

seems no longer necessary in all the tests with the CodeFixService no longer taking it as a param?

@CyrusNajmabadi CyrusNajmabadi deleted the backportCopilotAnalysis branch July 1, 2025 19:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Area-IDE untriaged Issues and PRs which have not yet been triaged by a lead VSCode

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants