-
Notifications
You must be signed in to change notification settings - Fork 187
kola: add new tracker_list field for denylist #2330
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
Conversation
In openshift/os#595 and openshift/os#599, I found myself mixed up with the support of the `tracker` field. It's defined as a string, so magically hoping that a slice of strings would be supported was misguided. Decided to try adding support for a new `tracker_list` field for those times when one issue just doesn't cut it. This seemed more straight-forward than trying to manually unmarshal the YAML or trying to find all the denylist documents in use.
|
Skipping CI for Draft Pull Request. |
|
Looking for feedback if this is desirable or not. |
cgwalters
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm fine with this, but it's not clear we benefit from an explicit list, e.g. we can also use space-separated strings, or have one entry be canonical and the other a comment e.g.
saqibali-2k
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The new functionality makes sense to me 👍
| Tracker string `yaml:"tracker"` | ||
| TrackerList []string `yaml:"tracker_list"` |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
| Tracker string `yaml:"tracker"` | |
| TrackerList []string `yaml:"tracker_list"` | |
| Tracker []string `yaml:"tracker"` |
I think we can change Tracker to []string from string rather than adding a TrackerList which seems to be closer to the assumed functionality in the linked PRs. If we prefer to have a separate field, that works too!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I tried the wholesale change from string to []string, but the YAML module is strict about the type (well, all of Golang is strictly typed...) so it blows up trying to unmarhsal the data:
cannot unmarshal !!seq into main.DenyListObj
See this example snippet I was playing with - https://play.golang.org/p/WxafbrQGuNe
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yep you're right that functionality isn't present, ignore the above suggestion.
I like the idea of a single entry being canonical and having others as comments. |
|
Going to withdraw this suggestion; let's just a use single canonical URL for the tracker and add additional links as comments. |
In openshift/os#595 and openshift/os#599, I found myself mixed up with
the support of the
trackerfield. It's defined as a string, somagically hoping that a slice of strings would be supported was
misguided.
Decided to try adding support for a new
tracker_listfield for thosetimes when one issue just doesn't cut it.
This seemed more straight-forward than trying to manually unmarshal
the YAML or trying to find all the denylist documents in use.