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

Prototype extension API support #5884

Merged
merged 12 commits into from
Jul 22, 2023
Merged

Prototype extension API support #5884

merged 12 commits into from
Jul 22, 2023

Conversation

333fred
Copy link
Member

@333fred 333fred commented Jul 1, 2023

Adds a new experimental API to the C# extension that allows other extensions to communicate with the C# language server. This API is not yet finalized and may change in the future. Relates to dotnet/roslyn#68696.

Adds a new experimental API to the C# extension that allows other extensions to communicate with the C# language server. This API is not yet finalized and may change in the future. Relates to dotnet/roslyn#68696.
@333fred 333fred requested a review from a team as a code owner July 1, 2023 21:27
@jasonmalinowski jasonmalinowski self-requested a review July 6, 2023 00:08
src/csharpExtensionExports.ts Outdated Show resolved Hide resolved
src/csharpExtensionExports.ts Outdated Show resolved Hide resolved
@333fred
Copy link
Member Author

333fred commented Jul 12, 2023

@jasonmalinowski @dibarbet any further feedback?

* upstream/main: (26 commits)
  Update Roslyn server (#5925)
  Add call to setupTelemetryEnvironmentAsync (#5922)
  Fix static variables used in determineBrowserType (#5919)
  Update debugger packages to 2.0.2 (#5914)
  Bump semver from 5.6.0 to 5.7.2
  Add determineBrowserType to CSharpExtensionExports (#5911)
  Remove pwa- prefix from BlazorDebug (#5908)
  Update roslyn
  Try a less recent Razor version
  deleted extra space in readme
  small edits to readme
  Update regexes
  Remove unsupported feature
  Add task for updating Razor deps
  Allow updatePackageDependencies to work with Razor (well, with prerelease packages)
  Bump Razor to 7.0.0-preview.23328.2
  Update README.md to make runtime extension note numbered
  Update README.md to notify user about .NET Runtime Tool
  Add write permissions to job
  Update release-ci.yml
  ...
src/lsptoolshost/roslynLanguageServer.ts Outdated Show resolved Hide resolved
src/lsptoolshost/roslynLanguageServer.ts Outdated Show resolved Hide resolved
return vscode.extensions.all.flatMap((extension) => {
const loadPaths = extension.packageJSON.contributes?.['csharpExtensionLoadPaths'];
if (loadPaths === undefined || loadPaths === null) {
_traceChannel.appendLine(`Extension ${extension.id} does not contribute csharpExtensionLoadPaths`);
Copy link
Member

Choose a reason for hiding this comment

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

Given this is the common case, just skip the logging here?

Copy link
Member Author

Choose a reason for hiding this comment

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

I figure that's what trace logging is for: the common case that someone is trying to debug what's happening.

Copy link
Member

Choose a reason for hiding this comment

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

Is the _traceChannel though the LSP channel? @dibarbet?

src/lsptoolshost/roslynLanguageServer.ts Outdated Show resolved Hide resolved
src/lsptoolshost/roslynLanguageServer.ts Show resolved Hide resolved
src/lsptoolshost/roslynLanguageServer.ts Show resolved Hide resolved
src/main.ts Outdated Show resolved Hide resolved
return vscode.extensions.all.flatMap((extension) => {
const loadPaths = extension.packageJSON.contributes?.['csharpExtensionLoadPaths'];
if (loadPaths === undefined || loadPaths === null) {
_traceChannel.appendLine(`Extension ${extension.id} does not contribute csharpExtensionLoadPaths`);
Copy link
Member

Choose a reason for hiding this comment

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

Is the _traceChannel though the LSP channel? @dibarbet?

@333fred 333fred merged commit 19b4bfc into main Jul 22, 2023
4 checks passed
@333fred 333fred deleted the add-experimental-api branch July 22, 2023 00:14
@spouliot
Copy link

spouliot commented Aug 9, 2023

@333fred just to let you know that I can see/access the experimental API from the latest released extensions. Looking forward to documentation on how we can use it to replace our O# hooks 😄

@333fred
Copy link
Member Author

333fred commented Aug 21, 2023

@spouliot that's fine. Just note that any api in there will definitely change, even if we ship it for real as is, since we will need to move it from the experimental accessor to the real accessor.

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.

4 participants