Has anyone seen my memory? This is something I actually fixed 3 weeks ago as
part of https://issues.sonatype.org/browse/MECLIPSEWTP-184
The dev build is available from
http://download.jboss.org/jbosstools/builds/staging/m2eclipse-wtp-e37/all/repo/

Signs of old age are kinda frightening.

Regards,

Fred Bricon

2011/10/29 Fred Bricon <[email protected]>

> Hi,
>
> I reproduced the bug with m2e-wtp, this explains why it impacts STS.
> It thinks, wrongly, there's a duplicate dependency and tries to be clever
> (and utterly fails) in moving one of them in the target folder.
> I opened https://issues.sonatype.org/browse/MECLIPSEWTP-192 to keep track
> of this issue.
> I'll try to fix it this week-end so you can try a dev build ASAP.
>
> Regards,
>
> Fred Bricon
>
>
> 2011/10/29 Andrew Eisenberg <[email protected]>
>
>> I would be surprised if this problem has anything to do with STS, but
>> you never know and it would be good to try to reproduce the problem in
>> a vanilla Eclipse install.  FWIW, I tried to naively reproduce
>> jacquie's bug using this simple pom file, but could not.
>>
>> It would be very helpful if you could send over a failing project.
>>
>> Here's the pom that I used.  It correctly found the dependencies in
>> the .m2 directory.  Could there be something else going on with your
>> configuration causing maven to look for dependencies in odd places?
>>
>> <?xml version="1.0" encoding="UTF-8"?>
>> <project xmlns="http://maven.apache.org/POM/4.0.0";
>>        xsi:schemaLocation="http://maven.apache.org/POM/4.0.0
>> http://maven.apache.org/maven-v4_0_0.xsd";
>>        xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";>
>>        <modelVersion>4.0.0</modelVersion>
>>        <groupId>org.springframework.samples.spring</groupId>
>>        <artifactId>spring-jpa-utility</artifactId>
>>        <version>1.0.0.CI-SNAPSHOT</version>
>>        <name>Spring JPA Utility</name>
>>        <url>http://www.springframework.org</url>
>>        <description>
>>                <![CDATA[This project is a minimal jar utility with Spring
>> configuration for JPA usage.]]>
>>        </description>
>>        <properties>
>>                <maven.test.failure.ignore>true</maven.test.failure.ignore>
>>
>>  <spring.framework.version>3.0.6.RELEASE</spring.framework.version>
>>        </properties>
>>
>>        <dependencies>
>>                <dependency>
>>                        <groupId>org.springframework.security</groupId>
>>                        <artifactId>spring-security-core</artifactId>
>>                         <version>3.0.6.RELEASE</version>
>>                 </dependency>
>>                <dependency>
>>                        <groupId>org.springframework.security</groupId>
>>                        <artifactId>spring-security-core</artifactId>
>>                        <classifier>tests</classifier>
>>                         <version>3.0.6.RELEASE</version>
>>                </dependency>
>>        </dependencies>
>>
>> </project>
>>
>> On Fri, Oct 28, 2011 at 3:17 PM, Igor Fedorenko <[email protected]>
>> wrote:
>> > m2e never resolves dependencies from project target folders, so I
>> > suspect the observed behaviour is specific to STS. If can reproduce the
>> > problem using clean m2e installation (for example, "for java developers"
>> > Eclipse distribution from eclipse.org), please submit a bugreport in
>> m2e
>> > bugzilla and provide complete standalone project and steps to reproduce
>> > the problem.
>> >
>> > --
>> > Regards,
>> > Igor
>> >
>> > On 11-10-28 5:54 PM, jacquie wrote:
>> >>
>> >> Igor Fedorenko<igor<at>  ifedorenko.com>  writes:
>> >>
>> >>>
>> >>> Can you provide complete standalone project illustrate your setup?
>> >>>
>> >>> Maven has rather loose model for classified artifacts and if I
>> remember
>> >>> correctly all dependency resolution is done on the main dependency
>> >>> artifact. So your project is expected to have indirect dependencies of
>> >>> info.collide:sqlspaces-commons:3.10.0 and nothing else. Specifically,
>> it
>> >>> is NOT expected to have any dependencies defined in
>> >>> info.collide:sqlspaces-commons:3.10.0:jdk15 pom.
>> >>>
>> >>> --
>> >>> Regards,
>> >>> Igor
>> >>>
>> >>> On 11-10-11 9:17 AM, Eric Kolotyluk wrote:
>> >>>>
>> >>>> I recently added some dependencies with classifiers, for example,
>> >>>>
>> >>>> <dependency>
>> >>>> <groupId>info.collide</groupId>
>> >>>> <artifactId>sqlspaces-commons</artifactId>
>> >>>> <version>3.10.0</version>
>> >>>> <type>pom</type>
>> >>>> <classifier>jdk15</classifier>
>> >>>> </dependency>
>> >>>>
>> >>>> But my Eclipse build is broken now because this does not show up
>> >>>> properly in "Maven Dependencies"
>> >>>>
>> >>>> If I build from the command line things are OK, but I cannot seem to
>> >>>> configure Eclipse to work with classifiers.
>> >>>>
>> >>>> Does anyone have any suggestions?
>> >>>>
>> >>>> Cheers, Eric
>> >>>> _______________________________________________
>> >>>> m2e-users mailing list
>> >>>> m2e-users<at>  eclipse.org
>> >>>> https://dev.eclipse.org/mailman/listinfo/m2e-users
>> >>>
>> >>
>> >> I am seeing what I think is a similar problem:
>> >>
>> >> My environment was STS 2.8.0 with m2e 1.0
>> >>
>> >> We have the following dependencies:
>> >>
>> >>                <dependency>
>> >>                        <groupId>org.springframework.security</groupId>
>> >>                        <artifactId>spring-security-core</artifactId>
>> >>                </dependency>
>> >>                <dependency>
>> >>                        <groupId>org.springframework.security</groupId>
>> >>                        <artifactId>spring-security-core</artifactId>
>> >>                        <classifier>tests</classifier>
>> >>                </dependency>
>> >>
>> >> The second one (with the classifier tag) seemed to cause both jars to
>> be
>> >> placed
>> >> in the project's target folder, instead of being resolved from my .m2
>> >> repository, and then I got Eclipse compilation errors because the
>> classes
>> >> in
>> >> there could not be found.
>> >>
>> >> If I remove that second dependency then the first one is referenced
>> from
>> >> .m2 as
>> >> expected, but then of course my test code doesn't compile.
>> >>
>> >> These dependencies get their version from the dependencyManagement tags
>> in
>> >> the
>> >> parent project and it is 2.0.6.RELEASE.
>> >>
>> >> Maven builds the project quite happily.
>> >>
>> >> But as you edit the pom to include/exclude the spring-security-core
>> test
>> >> jar you
>> >> can see the path of the spring-security-core jar change from .m2 to the
>> >> target
>> >> folder in the list of Maven dependencies. And the jars do actually
>> appear
>> >> in the
>> >> target folder, but that's not where Eclipse expects to find them.
>> >>
>> >> This all works fine in Eclipse Helios with m2eclipse.  When I imported
>> the
>> >> projects into sts 2.8.0 I imported them as fresh projects from svn and
>> all
>> >> the
>> >> m2e requirements were present and correct.
>> >>
>> >>
>> > _______________________________________________
>> > m2e-users mailing list
>> > [email protected]
>> > https://dev.eclipse.org/mailman/listinfo/m2e-users
>> >
>> _______________________________________________
>> m2e-users mailing list
>> [email protected]
>> https://dev.eclipse.org/mailman/listinfo/m2e-users
>>
>
>
>
> --
> "Have you tried turning it off and on again" - The IT Crowd
>



-- 
"Have you tried turning it off and on again" - The IT Crowd
_______________________________________________
m2e-users mailing list
[email protected]
https://dev.eclipse.org/mailman/listinfo/m2e-users

Reply via email to