Skip to content

Use AND to combine different volume filter keys#28413

Open
simonbrauner wants to merge 1 commit intocontainers:mainfrom
simonbrauner:issue-26786
Open

Use AND to combine different volume filter keys#28413
simonbrauner wants to merge 1 commit intocontainers:mainfrom
simonbrauner:issue-26786

Conversation

@simonbrauner
Copy link
Copy Markdown
Contributor

@simonbrauner simonbrauner commented Mar 30, 2026

Fixes: #26786

Checklist

Ensure you have completed the following checklist for your pull request to be reviewed:

  • Certify you wrote the patch or otherwise have the right to pass it on as an open-source patch by signing all
    commits. (git commit -s). (If needed, use git commit -s --amend). The author email must match
    the sign-off email address. See CONTRIBUTING.md
    for more information.
  • Referenced issues using Fixes: #00000 in commit message (if applicable)
  • Tests have been added/updated (or no tests are needed)
  • Documentation has been updated (or no documentation changes are needed)
  • All commits pass make validatepr (format/lint checks)
  • Release note entered in the section below (or None if no user-facing changes)

Does this PR introduce a user-facing change?

Volume filters with different keys are combined with AND instead of OR

@packit-as-a-service
Copy link
Copy Markdown

[NON-BLOCKING] Packit jobs failed. @containers/packit-build please check. Everyone else, feel free to ignore.

@simonbrauner
Copy link
Copy Markdown
Contributor Author

simonbrauner commented Mar 30, 2026

OR is currently used, and by changing it to AND would make it consistent with Docker.

@simonbrauner simonbrauner force-pushed the issue-26786 branch 4 times, most recently from 1fc2319 to 9efd4d8 Compare March 31, 2026 11:12
@packit-as-a-service
Copy link
Copy Markdown

Cockpit tests failed for commit 9efd4d8. @martinpitt, @jelly, @mvollmer please check.

@simonbrauner simonbrauner force-pushed the issue-26786 branch 2 times, most recently from f5f69e7 to 9e080c1 Compare March 31, 2026 12:23
@packit-as-a-service
Copy link
Copy Markdown

[NON-BLOCKING] Packit jobs failed. @containers/packit-build please check. Everyone else, feel free to ignore.

@simonbrauner simonbrauner force-pushed the issue-26786 branch 6 times, most recently from 80ec8e2 to afbea92 Compare March 31, 2026 14:53
@mheon
Copy link
Copy Markdown
Member

mheon commented Mar 31, 2026

Frankly this is making me regret ever merging label!= support

@simonbrauner simonbrauner force-pushed the issue-26786 branch 2 times, most recently from 54712bf to f8b2d28 Compare April 1, 2026 14:09
@simonbrauner simonbrauner changed the title Fix filtering in volume prune and ls Use AND to combine different volume filter keys Apr 1, 2026
@Luap99
Copy link
Copy Markdown
Member

Luap99 commented Apr 1, 2026

How does it behave with containers, images? Whatever we end up it must be consistent for all filtering.

Fixes: containers#26786

Signed-off-by: Šimon Brauner <sbrauner@redhat.com>
@simonbrauner
Copy link
Copy Markdown
Contributor Author

How does it behave with containers, images? Whatever we end up it must be consistent for all filtering.

AND is also used for filters of different keys when filtering images, containers, and pods.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

podman volume prune/ls combines filters with OR instead of AND.

3 participants