ant-notifications mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From xav...@apache.org
Subject svn commit: r619939 - in /ant/ivy/core/trunk: ./ src/java/org/apache/ivy/core/resolve/ test/java/org/apache/ivy/core/resolve/ test/repositories/IVY-729/ test/repositories/IVY-729/a/ test/repositories/IVY-729/a/1/ test/repositories/IVY-729/a/1/jars/ tes...
Date Fri, 08 Feb 2008 17:00:13 GMT
Author: xavier
Date: Fri Feb  8 09:00:10 2008
New Revision: 619939

URL: http://svn.apache.org/viewvc?rev=619939&view=rev
Log:
FIX: Bad conflict resolution leads to bad "configuration(s) not found" error (IVY-729)

Added:
    ant/ivy/core/trunk/test/repositories/IVY-729/
    ant/ivy/core/trunk/test/repositories/IVY-729/a/
    ant/ivy/core/trunk/test/repositories/IVY-729/a/1/
    ant/ivy/core/trunk/test/repositories/IVY-729/a/1/jars/
    ant/ivy/core/trunk/test/repositories/IVY-729/a/1/jars/a-1.jar   (with props)
    ant/ivy/core/trunk/test/repositories/IVY-729/b/
    ant/ivy/core/trunk/test/repositories/IVY-729/b/1/
    ant/ivy/core/trunk/test/repositories/IVY-729/b/1/ivy.xml   (with props)
    ant/ivy/core/trunk/test/repositories/IVY-729/b/1/jars/
    ant/ivy/core/trunk/test/repositories/IVY-729/b/1/jars/b-1.jar   (with props)
    ant/ivy/core/trunk/test/repositories/IVY-729/c/
    ant/ivy/core/trunk/test/repositories/IVY-729/c/1/
    ant/ivy/core/trunk/test/repositories/IVY-729/c/1/ivy.xml   (with props)
    ant/ivy/core/trunk/test/repositories/IVY-729/c/1/jars/
    ant/ivy/core/trunk/test/repositories/IVY-729/c/1/jars/c-1.jar   (with props)
    ant/ivy/core/trunk/test/repositories/IVY-729/ivy.xml   (with props)
    ant/ivy/core/trunk/test/repositories/IVY-729/ivysettings.xml   (with props)
Modified:
    ant/ivy/core/trunk/CHANGES.txt
    ant/ivy/core/trunk/src/java/org/apache/ivy/core/resolve/ResolveEngine.java
    ant/ivy/core/trunk/test/java/org/apache/ivy/core/resolve/ResolveTest.java

Modified: ant/ivy/core/trunk/CHANGES.txt
URL: http://svn.apache.org/viewvc/ant/ivy/core/trunk/CHANGES.txt?rev=619939&r1=619938&r2=619939&view=diff
==============================================================================
--- ant/ivy/core/trunk/CHANGES.txt (original)
+++ ant/ivy/core/trunk/CHANGES.txt Fri Feb  8 09:00:10 2008
@@ -78,6 +78,7 @@
 - IMPROVEMENT: Downgrade Ant version requirement to 1.6 to build Ivy (IVY-687)
 - IMPROVEMENT: In the ResolveReport class, add the possibility to filter the evicted module
while getting the list of DownloadArtifact (IVY-704) (thanks to Nicolas Lalevée)
 
+- FIX: Bad conflict resolution leads to bad "configuration(s) not found" error (IVY-729)
 - FIX: Resolving for muyltiple configurations when one is not in the list of available configurations
does not abort the build (IVY-720)
 - FIX: Branch attribute considered as both a standard and extra attribute on module info
(IVY-726)
 - FIX: Branch attribute not set on deliver when using a non default branch (IVY-724)

Modified: ant/ivy/core/trunk/src/java/org/apache/ivy/core/resolve/ResolveEngine.java
URL: http://svn.apache.org/viewvc/ant/ivy/core/trunk/src/java/org/apache/ivy/core/resolve/ResolveEngine.java?rev=619939&r1=619938&r2=619939&view=diff
==============================================================================
--- ant/ivy/core/trunk/src/java/org/apache/ivy/core/resolve/ResolveEngine.java (original)
+++ ant/ivy/core/trunk/src/java/org/apache/ivy/core/resolve/ResolveEngine.java Fri Feb  8
09:00:10 2008
@@ -908,7 +908,8 @@
         } else if (resolvedNodes.isEmpty() && node.getParent() != ancestor) {
             //Conflict must only be computed per root configuration at this step.
             Collection ancestorDepIvyNodes = node.getParent().getNode()
-                        .getDependencies(node.getRootModuleConf(), new String[] {conf});
+                        .getDependencies(node.getRootModuleConf(), 
+                            new String[] {node.getParentConf()});
             for (Iterator it = ancestorDepIvyNodes.iterator(); it.hasNext();) {
                 IvyNode ancestorDep = (IvyNode) it.next();
                 if (ancestorDep.getModuleId().equals(node.getModuleId())) {

Modified: ant/ivy/core/trunk/test/java/org/apache/ivy/core/resolve/ResolveTest.java
URL: http://svn.apache.org/viewvc/ant/ivy/core/trunk/test/java/org/apache/ivy/core/resolve/ResolveTest.java?rev=619939&r1=619938&r2=619939&view=diff
==============================================================================
--- ant/ivy/core/trunk/test/java/org/apache/ivy/core/resolve/ResolveTest.java (original)
+++ ant/ivy/core/trunk/test/java/org/apache/ivy/core/resolve/ResolveTest.java Fri Feb  8 09:00:10
2008
@@ -2604,6 +2604,16 @@
                 .getArtifactsNumber());
     }
 
+    public void testIVY729() throws Exception {
+        Ivy ivy = new Ivy();
+        ivy.configure(new File("test/repositories/IVY-729/ivysettings.xml"));
+
+        ResolveReport report = ivy.resolve(new File(
+                "test/repositories/IVY-729/ivy.xml").toURL(), 
+                getResolveOptions(new String[] {"*"}));
+        assertFalse(report.hasError());
+    }
+
     public void testCircular() throws Exception {
         // mod6.3 depends on mod6.2, which itself depends on mod6.3
 

Added: ant/ivy/core/trunk/test/repositories/IVY-729/a/1/jars/a-1.jar
URL: http://svn.apache.org/viewvc/ant/ivy/core/trunk/test/repositories/IVY-729/a/1/jars/a-1.jar?rev=619939&view=auto
==============================================================================
Binary file - no diff available.

Propchange: ant/ivy/core/trunk/test/repositories/IVY-729/a/1/jars/a-1.jar
------------------------------------------------------------------------------
    svn:mime-type = application/octet-stream

Added: ant/ivy/core/trunk/test/repositories/IVY-729/b/1/ivy.xml
URL: http://svn.apache.org/viewvc/ant/ivy/core/trunk/test/repositories/IVY-729/b/1/ivy.xml?rev=619939&view=auto
==============================================================================
--- ant/ivy/core/trunk/test/repositories/IVY-729/b/1/ivy.xml (added)
+++ ant/ivy/core/trunk/test/repositories/IVY-729/b/1/ivy.xml Fri Feb  8 09:00:10 2008
@@ -0,0 +1,10 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<ivy-module version="2.0">
+	<info organisation="test" module="b" revision="1" status="release"/>
+	<configurations>
+		<conf name="compile"/>
+	</configurations>
+	<publications>
+		<artifact name="b" type="jar" conf="compile"/>
+	</publications>
+</ivy-module>

Propchange: ant/ivy/core/trunk/test/repositories/IVY-729/b/1/ivy.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Added: ant/ivy/core/trunk/test/repositories/IVY-729/b/1/jars/b-1.jar
URL: http://svn.apache.org/viewvc/ant/ivy/core/trunk/test/repositories/IVY-729/b/1/jars/b-1.jar?rev=619939&view=auto
==============================================================================
Binary file - no diff available.

Propchange: ant/ivy/core/trunk/test/repositories/IVY-729/b/1/jars/b-1.jar
------------------------------------------------------------------------------
    svn:mime-type = application/octet-stream

Added: ant/ivy/core/trunk/test/repositories/IVY-729/c/1/ivy.xml
URL: http://svn.apache.org/viewvc/ant/ivy/core/trunk/test/repositories/IVY-729/c/1/ivy.xml?rev=619939&view=auto
==============================================================================
--- ant/ivy/core/trunk/test/repositories/IVY-729/c/1/ivy.xml (added)
+++ ant/ivy/core/trunk/test/repositories/IVY-729/c/1/ivy.xml Fri Feb  8 09:00:10 2008
@@ -0,0 +1,14 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<ivy-module version="2.0">
+	<info organisation="test" module="c" revision="1" status="release"/>
+	<configurations>
+		<conf name="compile"/>
+	</configurations>
+	<publications>
+		<artifact name="c" type="jar" conf="compile"/>
+	</publications>
+	<dependencies>
+		<dependency org="test" name="a" rev="1" conf="compile->*"/>
+		<dependency org="test" name="b" rev="1" conf="%->@"/>
+	</dependencies>
+</ivy-module>

Propchange: ant/ivy/core/trunk/test/repositories/IVY-729/c/1/ivy.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Added: ant/ivy/core/trunk/test/repositories/IVY-729/c/1/jars/c-1.jar
URL: http://svn.apache.org/viewvc/ant/ivy/core/trunk/test/repositories/IVY-729/c/1/jars/c-1.jar?rev=619939&view=auto
==============================================================================
Binary file - no diff available.

Propchange: ant/ivy/core/trunk/test/repositories/IVY-729/c/1/jars/c-1.jar
------------------------------------------------------------------------------
    svn:mime-type = application/octet-stream

Added: ant/ivy/core/trunk/test/repositories/IVY-729/ivy.xml
URL: http://svn.apache.org/viewvc/ant/ivy/core/trunk/test/repositories/IVY-729/ivy.xml?rev=619939&view=auto
==============================================================================
--- ant/ivy/core/trunk/test/repositories/IVY-729/ivy.xml (added)
+++ ant/ivy/core/trunk/test/repositories/IVY-729/ivy.xml Fri Feb  8 09:00:10 2008
@@ -0,0 +1,42 @@
+<ivy-module
+version="2.0"
+xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+
+
+xsi:noNamespaceSchemaLocation="http://ant.apache.org/ivy/schemas/ivy.xsd">
+
+<info
+organisation="test"
+module="test"/>
+
+<configurations>
+
+
+<conf
+name="conf1"/>
+
+
+<conf
+name="conf2"/>
+
+</configurations>
+
+<dependencies>
+
+
+<dependency
+org="test"
+name="a"
+rev="1"
+conf="conf1->*"/>
+
+
+<dependency
+org="test"
+name="c"
+rev="1"
+conf="conf2->compile"/>
+
+</dependencies>
+</ivy-module>
+

Propchange: ant/ivy/core/trunk/test/repositories/IVY-729/ivy.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Added: ant/ivy/core/trunk/test/repositories/IVY-729/ivysettings.xml
URL: http://svn.apache.org/viewvc/ant/ivy/core/trunk/test/repositories/IVY-729/ivysettings.xml?rev=619939&view=auto
==============================================================================
--- ant/ivy/core/trunk/test/repositories/IVY-729/ivysettings.xml (added)
+++ ant/ivy/core/trunk/test/repositories/IVY-729/ivysettings.xml Fri Feb  8 09:00:10 2008
@@ -0,0 +1,9 @@
+<ivysettings>
+    <settings defaultResolver="test"/>
+    <resolvers>
+        <filesystem name="test">
+            <ivy pattern="${ivy.settings.dir}/[module]/[revision]/ivy.xml" />
+            <artifact pattern="${ivy.settings.dir}/[module]/[revision]/[type]s/[artifact]-[revision].[ext]"
/>
+        </filesystem>
+    </resolvers>
+</ivysettings>
\ No newline at end of file

Propchange: ant/ivy/core/trunk/test/repositories/IVY-729/ivysettings.xml
------------------------------------------------------------------------------
    svn:eol-style = native



Mime
View raw message