Skip to content

Broken functionality of LYD_PARSE_STORE_ONLY flag on union type #2428

@steweg

Description

@steweg

Hi,

I when I accidentally pull latest version of devel/master, I noticed that some of the features that worked for me before stopped working. I have pin point it to commit b89b5ae. I am kind of surprised to see that even saying that it is fixing some issue in different project. Unfortunately there is no unit test which would provide some level of details in how this potential issue can happen or what it causes to that other project

Anyway on my side, now I have a problem because when I use arbitrary value which shall work or was working before, I am getting errors that my value is not valid due to pattern, length etc... which was exactly what I wanted to avoid by using this special flag. I fully agree that in case of union type that selected subtype might be wrong, but this is kind of expected as the value that was given with STORE_ONLY is just kind of arbitrary or temporary one. So it is also expected to be replaced with completely valid once available, or not being used at all in the final set.

I am not sure for what reason someone else is using this FLAG, but current state is definitely not ok as union types are now exception in behavior when compared with other built-in types.

So can you please share some light to root cause, so we can find some reasonable alternative that will work for all parties involved? Thanks

Metadata

Metadata

Assignees

No one assigned

    Labels

    is:enhancementRequest for adding new feature or enahncing functionality.status:completedFrom the developer perspective, the issue was solved (bug fixed, question answered,...)

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions