Skip to content

unexpected initialization order of settings overridden in source dependencies #3850

@jastice

Description

@jastice

Overriding settings of a source dependency build seems to happen in the wrong order.
When a source dependency explicitly defines a setting, it is not possible to override it from the build.sbt of the project consuming the dependency.

steps

Clone project: https://github.com/jastice/buildref1
This project contains the main project buildref1 which depends on another project buildref2.
buildref2 defines a value for the setting ideaDownloadDirectory which is provided by a plugin.
buildref1 attempts to override this value in it's build.sbt

problem

sbt:parentBuild> {file:/Users/jast/playspace/buildref1/buildref2/}/ideaDownloadDirectory
[info] set in buildref2
sbt:parentBuild> {file:/Users/jast/playspace/buildref1/buildref2/}otherRoot/ideaDownloadDirectory
[info] set in buildref2

expectation

sbt:parentBuild> {file:/Users/jast/playspace/buildref1/buildref2/}/ideaDownloadDirectory
[info] set in buildref1 for otherBuild
sbt:parentBuild> {file:/Users/jast/playspace/buildref1/buildref2/}otherRoot/ideaDownloadDirectory
[info]set in buildref1 for otherRoot

notes

sbt version: 1.0.4

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions