Teardown error: System.InvalidOperationException: The context data has not been setup.
at Cake.Core.CakeDataService.Get[TData]() in C:\projects\cake\src\Cake.Core\CakeDataService.cs:line 32
at Cake.Core.CakeEngineActions.<>c__DisplayClass21_0`1.<RegisterTeardown>b__0(ITeardownContext context) in C:\projects\cake\src\Cake.Core\CakeEngineActions.cs:line 64
at Cake.Core.DefaultExecutionStrategy.PerformTeardown(Action`1 action, ITeardownContext teardownContext) in C:\projects\cake\src\Cake.Core\DefaultExecutionStrategy.cs:line 67
at Cake.Core.CakeEngine.PerformTeardown(IExecutionStrategy strategy, ICakeContext context, Stopwatch stopWatch, CakeReport report, Boolean exceptionWasThrown, Exception thrownException) in C:\projects\cake\src\Cake.Core\CakeEngine.cs:line 494
Error: One or more errors occurred. (The type initializer for 'LibGit2Sharp.Core.NativeMethods' threw an exception.)
The type initializer for 'LibGit2Sharp.Core.NativeMethods' threw an exception.
Error: Process completed with exit code 1.
The underlying problem here is that the CodeQL workflow is based on ubuntu-latest which currently is an alias for ubuntu-20.04 which has known issues running libgit2sharp. The fix would be to pin the workflow to ubuntu-18.04
The error is:
The underlying problem here is that the CodeQL workflow is based on
ubuntu-latest
which currently is an alias forubuntu-20.04
which has known issues running libgit2sharp. The fix would be to pin the workflow toubuntu-18.04