Uploaded image for project: 'Ivy'
  1. Ivy
  2. IVY-999

Ivy deliver fails to replace dynamic revision

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • 2.0-RC2, 2.0
    • 2.1.0-RC1
    • Core
    • None
    • windows xp
      java 1.6
      ant 1.7.1

    Description

      Sometimes ivy:deliver does not replace the dynamic revision correctly.

      My Repository contains four module: junit in revision 3.8 and 4.4. A Modul A that depends on junit 4.4 and a module B that depends on junit "3.8.+". (A Zip with this setup will be appended).

      I do now resolve and deliver the following ivy:
      <?xml version="1.0" encoding="UTF-8"?>
      <ivy-module version="1.4">
      <info organisation="test" module="c"/>
      <publications/>
      <dependencies>
      <!-- THE ORDER OF THIS DEPENDENCIES IS IMPORTEND TO REPRODUCE THE BUG -->
      <dependency org="test" name="a" rev="latest.integration"/>
      <dependency org="test" name="b" rev="latest.integration"/>
      <dependency org="junit" name="junit" conf="default" rev="latest.integration"/>
      </dependencies>
      </ivy-module>

      The delivered Ivy File does not replace the dynamic revision for junit:

      <dependency org="junit" name="junit" conf="default" rev="latest.integration"/>

      The expected outcome would be:
      <dependency org="junit" name="junit" conf="default" rev="4.4" revConstraint="latest.integration"/>

      Please note that moving the dependency to junit on line higher (above "b") leads to the epected outcome.

      The bug was reproduced with rc2 and a private build from trunk.

      The ant log:
      D:\sources.java\Research\ivytest>ant test -v
      Apache Ant version 1.7.1 compiled on June 27 2008
      Buildfile: build.xml
      Detected Java version: 1.6 in: C:\Programme\Java\jdk1.6.0_05\jre
      Detected OS: Windows XP
      parsing buildfile D:\sources.java\Research\ivytest\build.xml with URI = file:/D:/sources.java/Research/ivytest/build.xml
      Project base dir set to: D:\sources.java\Research\ivytest
      Build sequence for target(s) `test' is [init_ivy, test]
      Complete build sequence is [init_ivy, test, ]

      init_ivy:
      [antlib:org.apache.tools.ant] Could not load definitions from resource org/apache/tools/ant/antlib.xml. It could not be found.
      parsing buildfile jar:file:/C:/Dokumente%20und%20Einstellungen/fickerm/.ant/lib/ivy-2.0.0-rc2.jar!/org/apache/ivy/ant/antlib.xml with URI = jar:file:/C:/Dokumente%20und%20Einstellungen/fickerm/.ant/li
      b/ivy-2.0.0-rc2.jar!/org/apache/ivy/ant/antlib.xml
      parsing buildfile jar:file:/D:/sources.java/Research/ivytest/ivy-2.1.x.jar!/org/apache/ivy/ant/antlib.xml with URI = jar:file:/D:/sources.java/Research/ivytest/ivy-2.1.x.jar!/org/apache/ivy/ant/antlib
      .xml
      parsing buildfile jar:file:/C:/Dokumente%20und%20Einstellungen/fickerm/.ant/lib/ivy-2.0.0-rc2.jar!/org/apache/ivy/ant/antlib.xml with URI = jar:file:/C:/Dokumente%20und%20Einstellungen/fickerm/.ant/li
      b/ivy-2.0.0-rc2.jar!/org/apache/ivy/ant/antlib.xml
      Loading jar:file:/C:/Dokumente%20und%20Einstellungen/fickerm/.ant/lib/ivy-2.0.0-rc2.jar!/org/apache/ivy/core/settings/ivy.properties
      [ivy:configure] :: Ivy 2.0.0-rc2 - 20081028224207 :: http://ant.apache.org/ivy/ ::
      :: loading settings :: file = D:\sources.java\Research\ivytest\ivysettings.xml
      no default ivy user dir defined: set to C:\Dokumente und Einstellungen\fickerm\.ivy2
      DEPRECATED: 'ivyconf' element is deprecated, use 'ivysettings' instead (file:/D:/sources.java/Research/ivytest/ivysettings.xml)
      no default cache defined: set to C:\Dokumente und Einstellungen\fickerm\.ivy2\cache
      settings loaded (79ms)
      default cache: C:\Dokumente und Einstellungen\fickerm\.ivy2\cache
      default resolver: local
      – 1 resolvers:
      local [file]

      test:
      [ivy:resolve] using ivy parser to parse file:/D:/sources.java/Research/ivytest/ivy-c.xml
      [ivy:resolve] :: resolving dependencies :: test#c;working@MARTIN
      [ivy:resolve] confs: [default]
      [ivy:resolve] validate = true
      [ivy:resolve] refresh = false
      [ivy:resolve] resolving dependencies for configuration 'default'
      [ivy:resolve] == resolving dependencies for test#c;working@MARTIN [default]
      [ivy:resolve] == resolving dependencies test#c;working@MARTIN->test#a;latest.integration [default->*]
      [ivy:resolve] no cached resolved revision for test#a;latest.integration
      [ivy:resolve] tried D:\sources.java\Research\ivytest/testrepo/test/a/ivy-[revision].xml
      [ivy:resolve] local do not support transaction. ivy pattern does not use revision as a directory
      [ivy:resolve] local: found md file for test#a;latest.integration
      [ivy:resolve] => D:\sources.java\Research\ivytest\testrepo\test\a\ivy-1.xml (1)
      [ivy:resolve] default-cache: revision in cache: test#a;1
      [ivy:resolve] found test#a;1 in local
      [ivy:resolve] [1] test#a;latest.integration
      [ivy:resolve] == resolving dependencies test#a;latest.integration->junit#junit;4.4 [default->*]
      [ivy:resolve] == resolving dependencies test#c;working@MARTIN->test#a;latest.integration [default->default]
      [ivy:resolve] == resolving dependencies test#c;working@MARTIN->test#b;latest.integration [default->*]
      [ivy:resolve] no cached resolved revision for test#b;latest.integration
      [ivy:resolve] tried D:\sources.java\Research\ivytest/testrepo/test/b/ivy-[revision].xml
      [ivy:resolve] local: found md file for test#b;latest.integration
      [ivy:resolve] => D:\sources.java\Research\ivytest\testrepo\test\b\ivy-1.5.xml (1.5)
      [ivy:resolve] default-cache: revision in cache: test#b;1.5
      [ivy:resolve] found test#b;1.5 in local
      [ivy:resolve] [1.5] test#b;latest.integration
      [ivy:resolve] == resolving dependencies test#b;latest.integration->junit#junit;3.8+ [default->default]
      [ivy:resolve] no cached resolved revision for junit#junit;3.8+
      [ivy:resolve] tried D:\sources.java\Research\ivytest/testrepo/junit/junit/ivy-[revision].xml
      [ivy:resolve] local: found md file for junit#junit;3.8+
      [ivy:resolve] => D:\sources.java\Research\ivytest\testrepo\junit\junit\ivy-3.8.xml (3.8)
      [ivy:resolve] default-cache: revision in cache: junit#junit;3.8
      [ivy:resolve] found junit#junit;3.8 in local
      [ivy:resolve] [3.8] junit#junit;3.8+
      [ivy:resolve] == resolving dependencies test#c;working@MARTIN->test#b;latest.integration [default->default]
      [ivy:resolve] == resolving dependencies test#c;working@MARTIN->junit#junit;latest.integration [default->default]
      [ivy:resolve] == resolving dependencies test#c;working@MARTIN->junit#junit;3.8+ [default->default]
      [ivy:resolve] resolved ivy file produced in C:\Dokumente und Einstellungen\fickerm\.ivy2\cache\resolved-test-c-working@MARTIN.xml
      [ivy:resolve] :: downloading artifacts ::
      [ivy:resolve] :: resolution report :: resolve 250ms :: artifacts dl 0ms
      [ivy:resolve] :: evicted modules:
      [ivy:resolve] junit#junit;4.4 by junit#junit;latest.integration in [default]
      [ivy:resolve] in test#c;working@MARTIN with latest-revision
      [ivy:resolve] junit#junit;latest.integration by junit#junit;3.8 in [default]
      [ivy:resolve] in test#c;working@MARTIN with latest-revision
      ---------------------------------------------------------------------

        modules artifacts
      conf number search dwnlded evicted number dwnlded

      ---------------------------------------------------------------------

      default 5 3 0 2 0 0

      ---------------------------------------------------------------------
      [ivy:resolve] report for test#c;working@MARTIN default produced in C:\Dokumente und Einstellungen\fickerm\.ivy2\cache\test-c-default.xml
      [ivy:resolve] resolve done (250ms resolve - 0ms download)
      Overriding previous definition of property "ivy.version"
      [property] Loading C:\DOKUME~1\fickerm\LOKALE~1\Temp\delivery.properties
      [property] Unable to find property file: C:\DOKUME~1\fickerm\LOKALE~1\Temp\delivery.properties
      :: delivering :: test#c;working@MARTIN :: 20090109101230 :: integration :: Fri Jan 09 10:12:30 CET 2009
      delivering ivy file to D:\sources.java\Research\ivytest\distrib\ivys\ivy-20090109101230.xml

      BUILD SUCCESSFUL

      Attachments

        1. Ivy-999-test.patch
          8 kB
          Martin Eigenbrodt
        2. ivy-999.zip
          4 kB
          Martin Eigenbrodt

        Activity

          People

            maartenc Maarten Coene
            martineigenbrodt Martin Eigenbrodt
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: