-
Notifications
You must be signed in to change notification settings - Fork 2.6k
Fixes the issue of losing the array if an empty forceList element or a tag is in the middle or the end #1039
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: master
Are you sure you want to change the base?
Fixes the issue of losing the array if an empty forceList element or a tag is in the middle or the end #1039
Conversation
…a tag is in the middle or the end
|
Good catch, this is a real bug in
|
|
Also, there is an existing issue where the first entry is empty. Currently it is being dropped, but the non-forceList behavior is to insert an initial empty string. The issues are:
Note: if you don't want to address this as being out of scope, let me know, and I will open a new issue to fix it. [stleary update 1/30/2026] A new issue was added for this: #1040 |
|
I think I would also lean more towards preserving the empty value and have user filter it out as and when needed, because consistency becomes an expectation of the user, if I purely think from a DX point of view.
I don't have a strong preference here, but I think a new issue would be helpful to reason about the changes. I can pick that up as well. |
|
Please add this test case to the unit tests. This captures what I was trying to explain in the comments. |
b897d59 to
510a03a
Compare
|
|
@stleary I have added the fix for #1040 , but since the resulting json, though might be a valid JSON with mixed types, it is not very type-safe unmarshalling friendly. I understand that changing that will result in a big hit to backwards-compatibility, but maybe in |
|
What problem does this code solve? Does the code still compile with Java6? Risks Changes to the API? Will this require a new release? Should the documentation be updated? Does it break the unit tests? Was any code refactored in this commit? Review status Starting 3-day comment window |
Good point. Config entries for tags with default values can be added, but I consider this a corner case with an available reasonable workaround where the developer can filter out or modify the non-compliant values. Will address it if someone raises an issue. |
|
Makes sense, modifying them to |



Fixes #1032
Currently the snippets of codes in question don't honour the array whose collection is already in progress. The proposed solution is to make sure the context is checked before the array is initialized.