You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Example that reproduces the problem uploaded to Github
Full description of the issue provided (see below)
It looks like it's impossible to have a null value for a give configuration property in the application.yml as it is converted to an empty string. I think the problem is in YamlPropertySourceLoader.java which is responsible for loading properties from the YAML. It calls an underline spring method which flattens the input map and somehow converts a null value to an empty string.
Steps to Reproduce
Create a new Grails 4.0.3 application.
Define a property test: null in the application.yml
In the BootStrap.groovy add an assert to verify that the value is null as:
Task List
It looks like it's impossible to have a
null
value for a give configuration property in theapplication.yml
as it is converted to an empty string. I think the problem is in YamlPropertySourceLoader.java which is responsible for loading properties from the YAML. It calls an underline spring method which flattens the input map and somehow converts anull
value to an empty string.Steps to Reproduce
test: null
in the application.ymlExpected Behaviour
The value of the config property should be null.
Actual Behaviour
The assertion would fail as the value is an empty String.
Environment Information
Example Application
https://github.com/puneetbehl/grails-config-problem.git
The text was updated successfully, but these errors were encountered: