diff --git a/src/Runner.Worker/Handlers/CompositeActionHandler.cs b/src/Runner.Worker/Handlers/CompositeActionHandler.cs index e6ac600d5..e83b5fb67 100644 --- a/src/Runner.Worker/Handlers/CompositeActionHandler.cs +++ b/src/Runner.Worker/Handlers/CompositeActionHandler.cs @@ -61,7 +61,7 @@ namespace GitHub.Runner.Worker.Handlers var compositeGitHubContext = new GitHubContext(); foreach (var pair in githubContext) { - compositeGitHubContext[pair.Key] = pair.Value.Clone(); + compositeGitHubContext[pair.Key] = pair.Value; } foreach (Pipelines.ActionStep actionStep in actionSteps) diff --git a/src/Runner.Worker/StepsRunner.cs b/src/Runner.Worker/StepsRunner.cs index 40430b694..8de680309 100644 --- a/src/Runner.Worker/StepsRunner.cs +++ b/src/Runner.Worker/StepsRunner.cs @@ -108,11 +108,11 @@ namespace GitHub.Runner.Worker // the server will never send an empty context name. Generated context names start with "__" if (step.ExecutionContext.Global.Variables.GetBoolean("DistributedTask.UseContextNameForGITHUBACTION") ?? false) { - step.ExecutionContext.SetGitHubContext("action", actionStep.Action.Name); + step.ExecutionContext.SetGitHubContext("action", step.ExecutionContext.GetFullyQualifiedContextName()); } else { - step.ExecutionContext.SetGitHubContext("action", step.ExecutionContext.GetFullyQualifiedContextName()); + step.ExecutionContext.SetGitHubContext("action", actionStep.Action.Name); } try