Skip to content

Fix #13230: make 'install' and 'deploy' depend on 'verify' in the lifecycle DAG - #13231

Merged
gnodet merged 1 commit into
apache:maven-4.0.xfrom
gnodet:fix/13230-install-deploy-depend-on-verify
Sep 24, 2026
Merged

gnodet merged 1 commit into
apache:maven-4.0.xfrom
gnodet:fix/13230-install-deploy-depend-on-verify

Conversation

@gnodet

@gnodet gnodet commented Sep 21, 2026

Copy link
Copy Markdown
Contributor

Summary

Fix #13230: make install and deploy depend on verify in the concurrent lifecycle DAG.

Root Cause

In the phase tree introduced for Maven 4, INSTALL and DEPLOY declared a dependency on PACKAGE only, not on VERIFY:

// Before (broken)
phase(INSTALL, after(PACKAGE)),
phase(DEPLOY, after(PACKAGE))

This caused the concurrent builder (-b concurrent) to silently skip the VERIFY phase when running mvn install, because there was no declared edge between INSTALL and VERIFY in the DAG.

The sequential builder was unaffected only by accident: its phase flattening happened to preserve the order, but this was not a semantic guarantee.

Fix

Change INSTALL and DEPLOY to declare after(VERIFY) instead of after(PACKAGE):

// After (correct)
phase(INSTALL, after(VERIFY)),
phase(DEPLOY, after(VERIFY))

VERIFY already depends transitively on BUILD (and therefore PACKAGE), so the full build order is preserved. This is also semantically correct: an artifact should not be installed or deployed before it has been verified.

Hermes Agent (Claude Sonnet 4.6) on behalf of Guillaume Nodet

…he concurrent lifecycle DAG

In the phase tree introduced for Maven 4, INSTALL and DEPLOY declared
a dependency on PACKAGE only, not on VERIFY. This caused the concurrent
builder (-b concurrent) to skip the VERIFY phase (unit tests, integration
tests) when running 'mvn install', since no explicit edge existed between
INSTALL and VERIFY in the DAG.

The sequential builder was unaffected only by accident: its phase
flattening happened to preserve the order, but this was not a semantic
guarantee.

Fix: change INSTALL and DEPLOY to declare after(VERIFY) instead of
after(PACKAGE). VERIFY already depends transitively on BUILD (and
therefore PACKAGE), so the full build order is preserved.

Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
@gnodet
gnodet force-pushed the fix/13230-install-deploy-depend-on-verify branch from f3b13e6 to 97d2c3e Compare September 22, 2026 14:28
@gnodet
gnodet marked this pull request as ready for review September 23, 2026 10:35
@gnodet gnodet added the bug Something isn't working label Sep 24, 2026
@gnodet gnodet added this to the 4.0.0 milestone Sep 24, 2026
@gnodet
gnodet merged commit f3caba1 into apache:maven-4.0.x Sep 24, 2026
22 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants