Uploaded image for project: 'Gradle'
  1. Gradle
  2. GRADLE-2477

support nested configuration resolution

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Resolved
    • Resolution: Fixed
    • Affects Version/s: 1.2
    • Fix Version/s: 1.5-rc-1

      Description

      If a dependency resolution trigger another dependency resolution, the org.gradle.initialization.DependencyResolutionLogger class throw an IllegalStateException.

      This happen for instance with the following script

      repositories {
      	flatDir {
      		dirs "."
      	}
      }
      
      configurations {
      	fragments
      }
      
      repositories {
      	flatDir {
      		dirs configurations.fragments
      	}
      }
      
      configurations {
      	compile
      }
      
      dependencies {
      	compile name:'foo'
      }
      
      task foo << {
      	println configurations.compile.files
      }
      

      Mainly the directories of a flatDir repository are resolved as dependencies.

      Running gradle foo throws an IllegalStateException

      If the fragments configuration is resolved "a-priori", it works correctly. For instance by adding to the script:

      afterEvaluate {
      	configurations.fragments.files
      }
      

        Attachments

          Activity

            People

            • Assignee:
              szczepiq Szczepan Faber
              Reporter:
              mleclercq Matthieu Leclercq
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: