diff --git a/CHANGELOG.md b/CHANGELOG.md index e994671f59..e43099392e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -21,6 +21,23 @@ * Bump tar-fs from 2.1.3 to 2.1.4 (PR: [#8661](https://github.com/dotnet/vscode-csharp/pull/8661)) * Add copilot setup steps (PR: [#8655](https://github.com/dotnet/vscode-csharp/pull/8655)) * Update pipeline and packaging excludes (PR: [#8654](https://github.com/dotnet/vscode-csharp/pull/8654)) +* Add new telemetry fields (PR: [#8673](https://github.com/dotnet/vscode-csharp/pull/8673)) +* Bump Roslyn to 5.1.0-1.25506.3 (PR: [#8673](https://github.com/dotnet/vscode-csharp/pull/8673)) + * Improve error recovery when object initializer uses ':' instead of '=' (PR: [#80553](https://github.com/dotnet/roslyn/pull/80553)) + * Support `field` keyword in EE. (PR: [#80515](https://github.com/dotnet/roslyn/pull/80515)) + * Log a debug message for ContentModified exceptions. (PR: [#80549](https://github.com/dotnet/roslyn/pull/80549)) + * Update proposal adjuster to acquire feature flags from VS (PR: [#80541](https://github.com/dotnet/roslyn/pull/80541)) + * Add telemetry indicating when file-based programs are used (PR: [#80538](https://github.com/dotnet/roslyn/pull/80538)) + * Fix thread safety issue in BuildServerConnection.TryCreateServer environment variable handling (PR: [#80498](https://github.com/dotnet/roslyn/pull/80498)) + * Extensions: refine tracking of used imports (PR: [#80485](https://github.com/dotnet/roslyn/pull/80485)) + * Disambiguate extension methods in "ambiguous call" error message when they have the same name but are from different assemblies (PR: [#80453](https://github.com/dotnet/roslyn/pull/80453)) + * Block file-local EmbeddedAttribute definitions. (PR: [#80501](https://github.com/dotnet/roslyn/pull/80501)) + * Extension block members do not have `this` parameter (PR: [#80457](https://github.com/dotnet/roslyn/pull/80457)) + * Handle some scenarios where attributes applied in local functions or lambdas within extension blocks were missing in metadata (PR: [#80464](https://github.com/dotnet/roslyn/pull/80464)) + * Unset other DOTNET_ROOT env vars when launching apphosts (PR: [#80492](https://github.com/dotnet/roslyn/pull/80492)) + * Add friendlier error message on an explicit implementation when the return type is wrong (PR: [#8037](https://github.com/dotnet/roslyn/pull/80376) + * Extensions: add Name property on embedded ExtensionMarkerAttribute (PR: [#80456](https://github.com/dotnet/roslyn/pull/80456)) + * Avoid implicit null checks while narrowing type for `or` patterns (PR: [#80348](https://github.com/dotnet/roslyn/pull/80348)) # 2.93.x * Bump Roslyn to 5.0.0-2.25472.11 (PR: [#8646](https://github.com/dotnet/vscode-csharp/pull/8646)) diff --git a/package.json b/package.json index c54eaf1a96..501e0d28c6 100644 --- a/package.json +++ b/package.json @@ -40,7 +40,7 @@ "workspace" ], "defaults": { - "roslyn": "5.1.0-1.25475.3", + "roslyn": "5.1.0-1.25506.3", "omniSharp": "1.39.14", "razor": "10.0.0-preview.25472.6", "razorOmnisharp": "7.0.0-preview.23363.1", diff --git a/src/shared/projectConfiguration.ts b/src/shared/projectConfiguration.ts index 8e5bb01335..e774cc24bb 100644 --- a/src/shared/projectConfiguration.ts +++ b/src/shared/projectConfiguration.ts @@ -19,6 +19,9 @@ export interface ProjectConfigurationMessage { FileExtensions: string[]; FileCounts: number[]; SdkStyleProject: boolean; + HasSolutionFile?: boolean; + IsFileBasedProgram?: boolean; + IsMiscellaneousFile?: boolean; } export function reportProjectConfigurationEvent( @@ -47,6 +50,18 @@ export function reportProjectConfigurationEvent( telemetryProps['NetSdkVersion'] = dotnetInfo?.Version ?? ''; telemetryProps['sdkStyleProject'] = projectConfig.SdkStyleProject.toString(); + if (projectConfig.HasSolutionFile != null) { + telemetryProps['HasSolutionFile'] = projectConfig.HasSolutionFile.toString(); + } + + if (projectConfig.IsFileBasedProgram != null) { + telemetryProps['IsFileBasedProgram'] = projectConfig.IsFileBasedProgram.toString(); + } + + if (projectConfig.IsMiscellaneousFile != null) { + telemetryProps['IsMiscellaneousFile'] = projectConfig.IsMiscellaneousFile.toString(); + } + if (useModernNet) { telemetryProps['useModernNet'] = useModernNet.toString(); } diff --git a/test/omnisharp/omnisharpUnitTests/logging/telemetryObserver.test.ts b/test/omnisharp/omnisharpUnitTests/logging/telemetryObserver.test.ts index 0110c87f9a..26b4bf3728 100644 --- a/test/omnisharp/omnisharpUnitTests/logging/telemetryObserver.test.ts +++ b/test/omnisharp/omnisharpUnitTests/logging/telemetryObserver.test.ts @@ -100,6 +100,9 @@ describe('TelemetryReporterObserver', () => { FileExtensions: fileExtensions, FileCounts: fileCounts, SdkStyleProject: sdkStyleProject, + HasSolutionFile: true, + IsFileBasedProgram: true, + IsMiscellaneousFile: true, }); await observer.post(event); @@ -114,6 +117,9 @@ describe('TelemetryReporterObserver', () => { expect(property['FileCounts']).toEqual('7|3'); expect(property['useModernNet']).toEqual('true'); expect(property['sdkStyleProject']).toEqual('true'); + expect(property['HasSolutionFile']).toEqual('true'); + expect(property['IsFileBasedProgram']).toEqual('true'); + expect(property['IsMiscellaneousFile']).toEqual('true'); }); [