Skip to content
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

api, daemon: drop unused dependency on github.com/jessevdk/go-flags #10890

Merged
merged 2 commits into from Apr 8, 2020

Conversation

tklauser
Copy link
Member

@tklauser tklauser commented Apr 8, 2020

The package github.com/jessevdk/go-flags is pulled in because the
swagger server template (which seems to be based on [0] uses it by
default. However, we don't use any of the features of this package, i.e.
extracting flag descriptions from struct tags. These options are not
exposed as CLI flags directly, but are set using the values from the
option package.

[0] https://github.com/go-swagger/go-swagger/blob/master/generator/templates/server/server.gotmpl

Due to this, we end up pulling in an unused dependency. Modify the
template accordingly and regenerate code to drop this unused dependency.

First commit is a preparatory cleanup of a missed conversion in #10158.

This was missed in commit f7547a0 ("Replaced uses of 'syscall' with
'unix' pkg."), PR #10158.

Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
The package github.com/jessevdk/go-flags is pulled in because the
swagger server template (which seems to be based on [0] uses it by
default. However, we don't use any of the features of this package, i.e.
extracting flag descriptions from struct tags. These options are not
exposed as CLI flags directly, but are set using the values from the
`option` package.

  [0] https://github.com/go-swagger/go-swagger/blob/master/generator/templates/server/server.gotmpl

Due to this, we end up pulling in an unused dependency. Modify the
template accordingly and regenerate code to drop this unused dependency.

Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
@tklauser tklauser added pending-review kind/cleanup This includes no functional changes. release-note/misc This PR makes changes that have no direct user impact. labels Apr 8, 2020
@tklauser tklauser requested a review from a team April 8, 2020 11:54
@tklauser tklauser requested a review from a team as a code owner April 8, 2020 11:54
@tklauser tklauser requested a review from a team April 8, 2020 11:54
@tklauser tklauser requested review from a team as code owners April 8, 2020 11:54
@maintainer-s-little-helper maintainer-s-little-helper bot added this to In progress in 1.8.0 Apr 8, 2020
@tklauser
Copy link
Member Author

tklauser commented Apr 8, 2020

test-me-please

@coveralls
Copy link

Coverage Status

Coverage decreased (-0.03%) to 46.946% when pulling d183cf1 on pr/tklauser/drop-go-flags-dep into 418500b on master.

@tgraf tgraf merged commit e63a1d4 into master Apr 8, 2020
1.8.0 automation moved this from In progress to Merged Apr 8, 2020
@tgraf tgraf deleted the pr/tklauser/drop-go-flags-dep branch April 8, 2020 16:42
tklauser added a commit that referenced this pull request Apr 8, 2020
…time/flagext

Same case as for commit e63a1d4 ("api, daemon: drop unused
dependency on github.com/jessevdk/go-flags"), PR #10890.

The package is pulled in because the swagger server template uses it by
default.  However, we don't use any of the features of this package,
thus drop it.

Signed-off-by: Tobias Klauser <tklauser@distanz.ch>s
aanm pushed a commit that referenced this pull request Apr 9, 2020
…time/flagext

Same case as for commit e63a1d4 ("api, daemon: drop unused
dependency on github.com/jessevdk/go-flags"), PR #10890.

The package is pulled in because the swagger server template uses it by
default.  However, we don't use any of the features of this package,
thus drop it.

Signed-off-by: Tobias Klauser <tklauser@distanz.ch>s
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/cleanup This includes no functional changes. release-note/misc This PR makes changes that have no direct user impact.
Projects
No open projects
1.8.0
  
Merged
Development

Successfully merging this pull request may close these issues.

None yet

4 participants