Skip to content

[BUG] images.list() filter does not work properly #457

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

Closed
D3vil0p3r opened this issue Oct 24, 2024 · 0 comments · Fixed by #468
Closed

[BUG] images.list() filter does not work properly #457

D3vil0p3r opened this issue Oct 24, 2024 · 0 comments · Fixed by #468
Labels
bug Something isn't working good first issue Good for newcomers

Comments

@D3vil0p3r
Copy link
Contributor

D3vil0p3r commented Oct 24, 2024

I have an Arch Linux environment with the following podman pulled images:

docker.io/library/python:3.12.2-bullseye
docker.io/nwodtuhs/exegol:osint

I wrote a simple Python script to filter the images list by name:

import podman
from podman import PodmanClient

client = podman.from_env()
print("Podman client:", client)

image_name="nwodtuhs/exegol:osint"
images = client.images.list(name=image_name, filters={"dangling": False})
print(images)

but I get:

[<Image: 'docker.io/library/python:3.12.2-bullseye'>, <Image: 'docker.io/nwodtuhs/exegol:osint'>]

so, it does not filter the result by name.

@inknos inknos added bug Something isn't working good first issue Good for newcomers labels Oct 29, 2024
mwperina added a commit to mwperina/bluechi that referenced this issue Dec 5, 2024
We have been using `filters` parameter for `images.list()` in podman-py
to search for bluechi-image container. But podman-py 5.3 changed the
behaviour of `filters` paramater as a part of
containers/podman-py#457 , so we need to use
`name` parameter for searching.

Signed-off-by: Martin Perina <[email protected]>
mwperina added a commit to mwperina/bluechi that referenced this issue Dec 5, 2024
We have been using `filters` parameter for `images.list()` in podman-py
to search for bluechi-image container. But podman-py 5.3 changed the
behaviour of `filters` paramater as a part of
containers/podman-py#457 , so we need to use
`name` parameter for searching.

Signed-off-by: Martin Perina <[email protected]>
engelmi pushed a commit to eclipse-bluechi/bluechi that referenced this issue Dec 5, 2024
We have been using `filters` parameter for `images.list()` in podman-py
to search for bluechi-image container. But podman-py 5.3 changed the
behaviour of `filters` paramater as a part of
containers/podman-py#457 , so we need to use
`name` parameter for searching.

Signed-off-by: Martin Perina <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working good first issue Good for newcomers
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants