| OK, I think I understand it. Posting here to help others understand similar issues. The dependency chain (without test dependencies) was: stashNotifier -> git 2.0 -> git-client 1.4.4 -> ssh-agent 1.3 -> sshd-core 0.8.0 Now it is: stashNotifier 1.19 -> git 3.0.0 -> git-client 2.0.0 git-client 2.0.0 doesn't depend on ssh-agent, so that cuts the non-test dependency chain and stops the bundling. The version of sshd-core (0.14.0) was determined by a shorter chain that involved test dependencies: stashNotifier 1.19 => plugin 3.40 -> jenkins-war 2.60.3 ~> sshd 1.11 -> sshd-core 0.14.0 I'm using => for a child-parent relationship (which doesn't count towards the length of the dependency chain) and ~> for a test dependency. mvn dependency:tree was showing a shorter dependency chain, but with the scope based on analyzing the whole tree, which made it look like a test dependency was pulling in a compile dependency. I don't see a way to make maven omit test dependencies or to show all paths leading to a transitive dependency. It would have helped with debugging the issue. |