From 92d726f50927347a004211b9d3f4806bbb9be31c Mon Sep 17 00:00:00 2001 From: Mantavya Dhingra Date: Fri, 20 Dec 2024 17:39:16 +0530 Subject: [PATCH] Correcting the execution context --- src/Agent.Worker/ExecutionContext.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Agent.Worker/ExecutionContext.cs b/src/Agent.Worker/ExecutionContext.cs index fcaf04f43b..1137a20dbd 100644 --- a/src/Agent.Worker/ExecutionContext.cs +++ b/src/Agent.Worker/ExecutionContext.cs @@ -719,7 +719,7 @@ private string GetWorkspaceIdentifier(Pipelines.AgentJobRequestMessage message) Variables.TryGetValue(Constants.Variables.System.DefinitionId, out string definitionId); var repoTrackingInfos = message.Resources.Repositories.Select(repo => new Build.RepositoryTrackingInfo(repo, "/")).ToList(); // Determine the hash algorithm based on the knob value - var workspaceIdentifier = Build.TrackingConfigHashAlgorithm.ComputeHash(collectionId, definitionId, repoTrackingInfos, AgentKnobs.UseSha256InComputeHash.GetValue(_parentExecutionContext).AsBoolean()); + var workspaceIdentifier = Build.TrackingConfigHashAlgorithm.ComputeHash(collectionId, definitionId, repoTrackingInfos, AgentKnobs.UseSha256InComputeHash.GetValue(this).AsBoolean()); Trace.Info($"WorkspaceIdentifier '{workspaceIdentifier}' created for repos {String.Join(',', repoTrackingInfos)}"); return workspaceIdentifier;