actions / runner-images

GitHub Actions runner images
MIT License
10.01k stars 3.02k forks source link

windows-2022. Visual Studio: System.ArgumentException : The parameter is incorrect. (Exception from HRESULT: 0x80070057 (E_INVALIDARG)) #10644

Open sorokinva opened 1 week ago

sorokinva commented 1 week ago

Description

Im using https://github.com/microsoft/vs-extension-testing for integration tests of Visual Studio extension in azure pipelines, when azure updated windows-2022 image to 20240912.1.0 it started to fail, It went normally on 20240811.1.0

[xUnit.net 00:30:35.00]   Finished:    VisualStudioPluginIntegrationTests
  Failed VisualStudioPluginIntegrationTests.Tests.ExtensionSmokeTests.TestExtensionStarts_Async (VS2022) [1 ms]
  Error Message:
   System.InvalidOperationException : Test execution was skipped due to a prior exception in the harness.
---- System.ArgumentException : The parameter is incorrect. (Exception from HRESULT: 0x80070057 (E_INVALIDARG))
  Stack Trace:
     at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
----- Inner Stack Trace -----
   at EnvDTE.Commands.Item(Object index, Int32 ID)
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at System.Runtime.CompilerServices.ConfiguredTaskAwaitable.ConfiguredTaskAwaiter.GetResult()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at System.Runtime.CompilerServices.ConfiguredTaskAwaitable`1.ConfiguredTaskAwaiter.GetResult()
  Passed Xunit.Instances.VisualStudio (VS2022, Exp) [1 ms]

Platforms affected

Runner images affected

Image version and build link

20240912.1.0

Is it regression?

20240811.1.0

Expected behavior

Tests passed

Actual behavior

Tests failed

Repro steps

  1. Create xunit test project with https://github.com/microsoft/vs-extension-testing
  2. Run in azure pipeline targeting vs2022
kishorekumar-anchala commented 1 week ago

Hi @sorokinva ,

Thank you for bringing this issue to us. We are looking into this issue and will update you on this issue after investigating.

mrmundt commented 1 week ago

This may be related based on Google searches (and if it's not - I'll happily open an issue), but we started getting this error after the Windows image update:

Building in 'C:\Users\RUNNER~1\AppData\Local\Temp\tmpv678cbu_'
ERROR: DistutilsPlatformError: Microsoft Visual C++ 14.0 or greater is
required. Get it with "Microsoft C++ Build Tools":
https://visualstudio.microsoft.com/visual-cpp-build-tools/

See example run: https://github.com/Pyomo/pyomo/actions/runs/10942938274/job/30381198414?pr=3373 (Windows jobs)