gnodet commented on PR #14186:
URL: https://github.com/apache/maven/pull/14186#issuecomment-7294885969

   Thanks for the excellent reproducer @seregamorph! This was indeed a 
regression introduced by the push-based scheduling in this PR.
   
   **Root cause:** When `initReadyQueue()` runs the first time (while only 
processing the `parent` and `plugin` PLAN steps), it initializes 
`pendingPredecessors` for *all* lifecycle steps across all projects. Later, 
when `plan()` processes the `lib` and `app` PLAN steps and adds cross-project 
dependency ordering edges (via `requiresDependencyOrdering`), those new 
predecessors were not counted in the already-initialized `pendingPredecessors`. 
This caused steps to become "ready" too early — `testCompile` could run before 
`compile`, and `compile` could start before upstream dependencies had finished 
packaging.
   
   **Fix:** In `executeAfterUnchecked()`, if the step's `pendingPredecessors` 
has already been initialized and the new predecessor is not yet done, 
atomically increment the counter. Pushed as f82a02830b.
   
   _Fully automatic review from Claude Code_


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to