From 64b34aa2e230f1cfb8db328799647564e8f96d8f Mon Sep 17 00:00:00 2001 From: Rainer Sigwald Date: Tue, 31 May 2022 16:57:34 -0500 Subject: [PATCH 1/8] Avoid AssemblyName.KeyPair on .NET It throws on .NET 6 and wasn't helpful before anyway: (from https://docs.microsoft.com/en-us/dotnet/api/system.reflection.assemblyname.keypair?view=net-5.0#remarks): > When the runtime loads an assembly, it does not set the KeyPair property. The getter for the property is only useful if the user set the property before using the AssemblyName object to create a dynamic assembly, and subsequently wants to retrieve the key pair. --- eng/Versions.props | 2 +- src/Shared/AssemblyNameExtension.cs | 6 ++++++ 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/eng/Versions.props b/eng/Versions.props index 0b1046359b4..1335af339e3 100644 --- a/eng/Versions.props +++ b/eng/Versions.props @@ -2,7 +2,7 @@ - 16.9.2release + 16.9.3release 15.1.0.0 preview true diff --git a/src/Shared/AssemblyNameExtension.cs b/src/Shared/AssemblyNameExtension.cs index 1d4f2a4bf71..40684d749f9 100644 --- a/src/Shared/AssemblyNameExtension.cs +++ b/src/Shared/AssemblyNameExtension.cs @@ -147,7 +147,9 @@ private AssemblyNameExtension(SerializationInfo info, StreamingContext context) var hashAlgorithm = (System.Configuration.Assemblies.AssemblyHashAlgorithm) info.GetInt32("hashAlg"); var versionCompatibility = (AssemblyVersionCompatibility) info.GetInt32("verCompat"); var codeBase = info.GetString("codebase"); +#if NETFRAMEWORK var keyPair = (StrongNameKeyPair) info.GetValue("keypair", typeof(StrongNameKeyPair)); +#endif asAssemblyName = new AssemblyName { @@ -159,7 +161,9 @@ private AssemblyNameExtension(SerializationInfo info, StreamingContext context) HashAlgorithm = hashAlgorithm, VersionCompatibility = versionCompatibility, CodeBase = codeBase, +#if NETFRAMEWORK KeyPair = keyPair +#endif }; asAssemblyName.SetPublicKey(publicKey); @@ -984,7 +988,9 @@ public void GetObjectData(SerializationInfo info, StreamingContext context) info.AddValue("hashAlg", asAssemblyName.HashAlgorithm); info.AddValue("verCompat", asAssemblyName.VersionCompatibility); info.AddValue("codebase", asAssemblyName.CodeBase); +#if NETFRAMEWORK info.AddValue("keypair", asAssemblyName.KeyPair); +#endif } info.AddValue("asStr", asString); From d19ce0349f73ba3b927f233518574eaec7f33063 Mon Sep 17 00:00:00 2001 From: Forgind Date: Tue, 31 May 2022 15:36:58 -0700 Subject: [PATCH 2/8] Update version numbers Maybe just kill mono? --- .vsts-dotnet-ci.yml | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/.vsts-dotnet-ci.yml b/.vsts-dotnet-ci.yml index df5f8f2bc6d..8f786e35d58 100644 --- a/.vsts-dotnet-ci.yml +++ b/.vsts-dotnet-ci.yml @@ -147,7 +147,7 @@ jobs: - job: CoreBootstrappedOnLinux displayName: "Linux Core" pool: - vmImage: 'ubuntu-16.04' + vmImage: 'ubuntu-latest' steps: - bash: . 'eng/cibuild_bootstrapped_msbuild.sh' displayName: CI Build @@ -179,7 +179,7 @@ jobs: - job: CoreOnMac displayName: "macOS Core" pool: - vmImage: 'macOS-10.14' + vmImage: 'macOS-latest' steps: - bash: . 'eng/cibuild_bootstrapped_msbuild.sh' displayName: CI Build @@ -211,7 +211,7 @@ jobs: - job: MonoOnMac displayName: "macOS Mono" pool: - vmImage: 'macOS-10.14' + vmImage: 'macOS-latest' steps: # https://docs.microsoft.com/en-us/azure/devops/pipelines/agents/hosted?view=azure-devops&tabs=yaml#mono - bash: | From 25fa0bf145c1109c3e043f1795eddd21bc5abb16 Mon Sep 17 00:00:00 2001 From: Forgind Date: Tue, 31 May 2022 17:14:00 -0700 Subject: [PATCH 3/8] Up SDK's version, too? --- global.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/global.json b/global.json index f3705522809..2205bf5fcf5 100644 --- a/global.json +++ b/global.json @@ -1,6 +1,6 @@ { "tools": { - "dotnet": "3.1.100", + "dotnet": "3.1.120", "runtimes": { "dotnet/x64": [ "2.1.7" From e69b3b00d73546e3a6ec96e910b6c3e0cb884935 Mon Sep 17 00:00:00 2001 From: Rainer Sigwald Date: Wed, 1 Jun 2022 09:29:59 -0500 Subject: [PATCH 4/8] Bump CLI version, too --- eng/Versions.props | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/eng/Versions.props b/eng/Versions.props index 1335af339e3..d8fcccfe207 100644 --- a/eng/Versions.props +++ b/eng/Versions.props @@ -23,7 +23,7 @@ - 3.1.100 + 3.1.120 3.3.1-beta3-final 5.9.0-preview.3.7016 From d7d19ef4f3d9f72628fdf2d1ad430ab46abca3f0 Mon Sep 17 00:00:00 2001 From: Rainer Sigwald Date: Wed, 1 Jun 2022 10:20:04 -0500 Subject: [PATCH 5/8] Try updating to Ubuntu 18 --- .vsts-dotnet-ci.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.vsts-dotnet-ci.yml b/.vsts-dotnet-ci.yml index 8f786e35d58..da8fc07f429 100644 --- a/.vsts-dotnet-ci.yml +++ b/.vsts-dotnet-ci.yml @@ -147,7 +147,7 @@ jobs: - job: CoreBootstrappedOnLinux displayName: "Linux Core" pool: - vmImage: 'ubuntu-latest' + vmImage: 'ubuntu-18.04' steps: - bash: . 'eng/cibuild_bootstrapped_msbuild.sh' displayName: CI Build From 5989a87d5114574506edce5bc44461e8c42023a8 Mon Sep 17 00:00:00 2001 From: Rainer Sigwald Date: Wed, 1 Jun 2022 10:34:50 -0500 Subject: [PATCH 6/8] Update official build pool name --- .vsts-dotnet.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.vsts-dotnet.yml b/.vsts-dotnet.yml index 0fac47de3ad..f5aed8b785a 100644 --- a/.vsts-dotnet.yml +++ b/.vsts-dotnet.yml @@ -28,7 +28,7 @@ stages: jobs: - job: Windows_NT pool: - name: VSEng-MicroBuildVS2019 + name: VSEngSS-MicroBuild2019-1ES demands: - agent.os -equals Windows_NT From 9a40e59399f06d94ba7b665d6737dd888fb5581e Mon Sep 17 00:00:00 2001 From: Rainer Sigwald Date: Wed, 1 Jun 2022 11:22:33 -0500 Subject: [PATCH 7/8] Disable optprof --- .vsts-dotnet.yml | 76 ++++++++++++++++++++++++------------------------ 1 file changed, 38 insertions(+), 38 deletions(-) diff --git a/.vsts-dotnet.yml b/.vsts-dotnet.yml index f5aed8b785a..40f8fe1bfe1 100644 --- a/.vsts-dotnet.yml +++ b/.vsts-dotnet.yml @@ -99,46 +99,46 @@ stages: condition: succeeded() # Publish OptProf configuration files - - task: ms-vscs-artifact.build-tasks.artifactDropTask-1.artifactDropTask@0 - inputs: - dropServiceURI: 'https://devdiv.artifacts.visualstudio.com' - buildNumber: 'ProfilingInputs/DevDiv/$(Build.Repository.Name)/$(Build.SourceBranchName)/$(Build.BuildNumber)' - sourcePath: '$(Build.SourcesDirectory)\artifacts\OptProf\$(BuildConfiguration)\Data' - toLowerCase: false - usePat: false - displayName: 'OptProf - Publish to Artifact Services - ProfilingInputs' - condition: succeeded() + # - task: ms-vscs-artifact.build-tasks.artifactDropTask-1.artifactDropTask@0 + # inputs: + # dropServiceURI: 'https://devdiv.artifacts.visualstudio.com' + # buildNumber: 'ProfilingInputs/DevDiv/$(Build.Repository.Name)/$(Build.SourceBranchName)/$(Build.BuildNumber)' + # sourcePath: '$(Build.SourcesDirectory)\artifacts\OptProf\$(BuildConfiguration)\Data' + # toLowerCase: false + # usePat: false + # displayName: 'OptProf - Publish to Artifact Services - ProfilingInputs' + # condition: succeeded() # Build VS bootstrapper # Generates $(Build.StagingDirectory)\MicroBuild\Output\BootstrapperInfo.json - - task: ms-vseng.MicroBuildTasks.0e9d0d4d-71ec-4e4e-ae40-db9896f1ae74.MicroBuildBuildVSBootstrapper@2 - inputs: - vsMajorVersion: $(VisualStudio.MajorVersion) - channelName: $(VisualStudio.ChannelName) - manifests: $(VisualStudio.SetupManifestList) - outputFolder: '$(Build.SourcesDirectory)\artifacts\VSSetup\$(BuildConfiguration)\Insertion' - displayName: 'OptProf - Build VS bootstrapper' - condition: succeeded() + # - task: ms-vseng.MicroBuildTasks.0e9d0d4d-71ec-4e4e-ae40-db9896f1ae74.MicroBuildBuildVSBootstrapper@2 + # inputs: + # vsMajorVersion: $(VisualStudio.MajorVersion) + # channelName: $(VisualStudio.ChannelName) + # manifests: $(VisualStudio.SetupManifestList) + # outputFolder: '$(Build.SourcesDirectory)\artifacts\VSSetup\$(BuildConfiguration)\Insertion' + # displayName: 'OptProf - Build VS bootstrapper' + # condition: succeeded() # Publish run settings - - task: PowerShell@2 - inputs: - filePath: eng\common\sdk-task.ps1 - arguments: -configuration $(BuildConfiguration) - -task VisualStudio.BuildIbcTrainingSettings - /p:VisualStudioDropName=$(VisualStudio.DropName) - /p:BootstrapperInfoPath=$(Build.StagingDirectory)\MicroBuild\Output\BootstrapperInfo.json - displayName: 'OptProf - Build IBC training settings' - condition: succeeded() + # - task: PowerShell@2 + # inputs: + # filePath: eng\common\sdk-task.ps1 + # arguments: -configuration $(BuildConfiguration) + # -task VisualStudio.BuildIbcTrainingSettings + # /p:VisualStudioDropName=$(VisualStudio.DropName) + # /p:BootstrapperInfoPath=$(Build.StagingDirectory)\MicroBuild\Output\BootstrapperInfo.json + # displayName: 'OptProf - Build IBC training settings' + # condition: succeeded() # Publish bootstrapper info - - task: PublishBuildArtifacts@1 - inputs: - PathtoPublish: $(Build.StagingDirectory)\MicroBuild\Output - ArtifactName: MicroBuildOutputs - ArtifactType: Container - displayName: 'OptProf - Publish Artifact: MicroBuildOutputs' - condition: succeeded() + # - task: PublishBuildArtifacts@1 + # inputs: + # PathtoPublish: $(Build.StagingDirectory)\MicroBuild\Output + # ArtifactName: MicroBuildOutputs + # ArtifactType: Container + # displayName: 'OptProf - Publish Artifact: MicroBuildOutputs' + # condition: succeeded() - task: PublishBuildArtifacts@1 displayName: 'Publish Artifact: logs' @@ -199,11 +199,11 @@ stages: condition: succeeded() # Tag the build at the very end when we know it's been successful. - - task: colinsalmcorner.colinsalmcorner-buildtasks.tag-build-task.tagBuildOrRelease@0 - displayName: Tag build as ready for optimization training - inputs: - tags: 'ready-for-training' - condition: succeeded() + # - task: colinsalmcorner.colinsalmcorner-buildtasks.tag-build-task.tagBuildOrRelease@0 + # displayName: Tag build as ready for optimization training + # inputs: + # tags: 'ready-for-training' + # condition: succeeded() - task: ms-vseng.MicroBuildTasks.521a94ea-9e68-468a-8167-6dcf361ea776.MicroBuildCleanup@1 displayName: Execute cleanup tasks From d24333d24ba37eaadbb12d62535de10d5e72bf07 Mon Sep 17 00:00:00 2001 From: Rainer Sigwald Date: Wed, 1 Jun 2022 11:52:39 -0500 Subject: [PATCH 8/8] Disable more VS build stuff --- .vsts-dotnet.yml | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/.vsts-dotnet.yml b/.vsts-dotnet.yml index 40f8fe1bfe1..fc5a7ebf2da 100644 --- a/.vsts-dotnet.yml +++ b/.vsts-dotnet.yml @@ -156,12 +156,12 @@ stages: # Publishes setup VSIXes to a drop. # Note: The insertion tool looks for the display name of this task in the logs. - - task: ms-vseng.MicroBuildTasks.4305a8de-ba66-4d8b-b2d1-0dc4ecbbf5e8.MicroBuildUploadVstsDropFolder@1 - displayName: Upload VSTS Drop - inputs: - DropName: $(VisualStudio.DropName) - DropFolder: 'artifacts\VSSetup\$(BuildConfiguration)\Insertion' - condition: succeeded() + # - task: ms-vseng.MicroBuildTasks.4305a8de-ba66-4d8b-b2d1-0dc4ecbbf5e8.MicroBuildUploadVstsDropFolder@1 + # displayName: Upload VSTS Drop + # inputs: + # DropName: $(VisualStudio.DropName) + # DropFolder: 'artifacts\VSSetup\$(BuildConfiguration)\Insertion' + # condition: succeeded() # Publish an artifact that the RoslynInsertionTool is able to find by its name. - task: PublishBuildArtifacts@1