Skip to content

Conversation

sunnymoon
Copy link

When rendering a parsed ConfigObject, in a scenario where there is a configuration like

@config-file1.conf
include file("values.conf")
outer {
include file("config-file2.conf")
}

@config-file2.conf
inner = ${value.url}

@values.conf
value {
url = "http://localhost"
}

the rendered ConfigObject after just Parseable.newFile("config-file2.conf").parse() has:

value {
url = "http://localhost"
}
outer {
inner = ${ outer.value.url }
}

instead of what was actually read :

value {
url = "http://localhost"
}
outer {
inner = ${ value.url }
}

This means that if parsed back again and then later resolved, it will break because there is no outer.value.url.
However, if resolved from the original file, it resolves correcly as inner=http://localhost (as expected).

…() ) ) != parse() which shouldn't be the case
@lightbend-cla-validator
Copy link
Collaborator

Hi @sunnymoon,

Thank you for your contribution! We really value the time you've taken to put this together.

Before we proceed with reviewing this pull request, please sign the Lightbend Contributors License Agreement:

http://www.lightbend.com/contribute/cla

@sunnymoon
Copy link
Author

Hi @sunnymoon,

Thank you for your contribution! We really value the time you've taken to put this together.

Before we proceed with reviewing this pull request, please sign the Lightbend Contributors License Agreement:

http://www.lightbend.com/contribute/cla

Already signed

@guerrillalg
Copy link

@lightbend-cla-validator
Any progress on this PR?

@kastoestoramadus
Copy link

Hi @sunnymoon we invite you to a living fork:
https://github.com/ekrich/sconfig
where changes can be made.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants