[ http://jira.codehaus.org/browse/MASSEMBLY-324?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=182981#action_182981 ]
Dennis Homann commented on MASSEMBLY-324: ----------------------------------------- I have the same issue with 2.2-beta-3 and 2.2-beta-4. In my case, I am running the assembly plug-in on project A which has a compile dependency on project B. B has a compile dependency on project C. I do not want C to show up in my assembly, so I have added dependency C with scope "provided" in A's pom. (exactly the same as described with javax.servlet:servlet-api above). The assembly descriptor looks like the one in the description of this issue. maven-dependency-plugin 2.0 shows the C resolved to "provided" as expected (the -X debug output gives a more detailed description of what's going on, and the behavior is correct). When I run assembly:single as part of my build, the -X debug output states correctly, that C should not be included: {noformat} [DEBUG] Statistics for Scope filter [null-scope=true, compile=true, runtime=true, test=false, provided=false, system=false] [DEBUG] The following scope filters were not used: o System [DEBUG] The following artifacts were removed by this filter: ....<C is listed here>.... {noformat} Then, further down, the output shows that C is being added to the artifact. > DependencySet scope runtime includes jars that are scope provided > ----------------------------------------------------------------- > > Key: MASSEMBLY-324 > URL: http://jira.codehaus.org/browse/MASSEMBLY-324 > Project: Maven 2.x Assembly Plugin > Issue Type: Bug > Affects Versions: 2.2-beta-2 > Reporter: Michael Mattox > > I use some jars in provided scope: > <dependency> > <groupId>javax.servlet</groupId> > <artifactId>servlet-api</artifactId> > <version>2.5</version> > <scope>provided</scope> > </dependency> > in my assembly, I specify scope as runtime: > <dependencySet> > <outputDirectory>WEB-INF/lib</outputDirectory> > <unpack>false</unpack> > <scope>runtime</scope> > </dependencySet> > Yet I still find the servlet-api-2.5.jar in my WAR. SInce the servlet-api is > scope provided, it should be provided by the container and not included in > the WAR. -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira