Skip to content

fix(pipeline): add missing mutex locks in matrix executor#556

Open
nextlevelshit wants to merge 1 commit intomainfrom
fix-matrix-race-condition
Open

fix(pipeline): add missing mutex locks in matrix executor#556
nextlevelshit wants to merge 1 commit intomainfrom
fix-matrix-race-condition

Conversation

@nextlevelshit
Copy link
Collaborator

Summary

  • aggregateResults() and the zero-items code path in matrix.go wrote to execution.Results and execution.WorkspacePaths without holding execution.mu
  • This could cause data corruption or panics during concurrent matrix execution
  • Applied the same execution.mu.Lock()/Unlock() pattern used in concurrency.go

Test plan

  • go test -race ./internal/pipeline/ passes
  • go test ./... passes

aggregateResults() and the zero-items code path wrote to
execution.Results and execution.WorkspacePaths without holding
execution.mu. This could cause data corruption during concurrent
matrix execution. Apply the same locking pattern used in
concurrency.go.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant