-
Notifications
You must be signed in to change notification settings - Fork 2.4k
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
Usability: prevent "-l" with arguments #7633
Usability: prevent "-l" with arguments #7633
Conversation
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: edsantiago The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
5250745
to
3f387d8
Compare
cmd/podman/containers/top.go
Outdated
if len(args) > 0 && topOptions.Latest { | ||
return errors.Errorf("--latest and containers cannot be used together") | ||
} |
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.
podman top
shouldn't check this. This is valid:
$ bin/podman top -l pid user
PID USER
1 root
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.
Good catch, thank you. Fixed.
cmd/podman/pods/top.go
Outdated
if len(args) > 0 && topOptions.Latest { | ||
return errors.Errorf("--latest and pods cannot be used together") | ||
} |
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.
Same here.
Add new system check confirming that "podman foo -l arg" throws an error; and fix lots of instances where code was not doing this check. I'll probably need to add something similar for --all but that can wait. Signed-off-by: Ed Santiago <[email protected]>
3f387d8
to
2583948
Compare
LGTM |
LGTM |
/lgtm |
PR containers#7633 disallowed "-l" (--latest) with container args. PR containers#7630 made changes to the "podman wait" command. The error message it issues is inconsistent (and incompatible) with the one required by the new BATS --help test. Fix that. This is entirely my fault. I was aware of containers#7630, and I was careful to check the output message format, but I was not careful enough (I trusted my eyes, not my code). Signed-off-by: Ed Santiago <[email protected]>
Add new system check confirming that "podman foo -l arg"
throws an error; and fix lots of instances where code
was not doing this check.
I'll probably need to add something similar for --all but
that can wait.
Signed-off-by: Ed Santiago [email protected]