Using Destination
with StringSliceFlags break DisableSliceFlagSeparator and SliceFlagSeperator controls
#2069
Labels
area/v2
relates to / is being considered for v2
kind/bug
describes or fixes a bug
status/triage
maintainers still need to look into this
My urfave/cli version is
v2.27.5
Checklist
Dependency Management
Describe the bug
I've tracked this down to how the flags are defined. Specifically, if a StringSliceFlag is given a
Destination
to store the StringSlice, the settings for flag seperators are not carried over when processing this Slice.To reproduce
I've created a simple golang program to replicate this issue.
CODE
Describe the steps or code required to reproduce the behavior
Observed behavior
Running above code with
Produces
What did you see happen immediately after the reproduction steps
above?
Expected behavior
DisableSliceFlagSeparator
is respected on all Destination valuesAdditional context
I work on k3s and we are attempting to migrate from v1 to v2. During this process, we have had difficulty with the changes around StringSliceFlag. Specifically issues with using the
DisableSliceFlagSeparator
option, as we pass flag values that contain,
into embedded collectables.Add any other context about the problem here.
If the issue relates to a specific open source GitHub repo, please
link that repo here.
If you can reproduce this issue with a public CI system, please
link a failing build here.
Want to fix this yourself?
Not sure where to start.
We'd love to have more contributors on this project! If the fix for
this bug is easily explained and very small, feel free to create a
pull request for it.
Run
go version
and paste its output hereRun
go env
and paste its output hereThe text was updated successfully, but these errors were encountered: