Skip to content

Unable to find image #3299

Open
Open
@jonathan-boudreau-work

Description

Steps to reproduce

  • On macos (non-arm) with docker for mac
  • Pull down image with docker pull aghost7/nodejs-dev:noble
  • From python, run the following code client.images.get('aghost7/nodejs-dev:noble').

Expected behaviour

get returns the image model.

Actual behaviour

I get the following exception:

Traceback (most recent call last):
  File "/Users/jonathanboudreau/Library/Caches/pypoetry/virtualenvs/slipway-axL3wFL9-py3.12/lib/python3.12/site-packages/docker/api/client.py", line 275, in _raise_for_status
    response.raise_for_status()
  File "/Users/jonathanboudreau/Library/Caches/pypoetry/virtualenvs/slipway-axL3wFL9-py3.12/lib/python3.12/site-packages/requests/models.py", line 1024, in raise_for_status
    raise HTTPError(http_error_msg, response=self)
requests.exceptions.HTTPError: 404 Client Error: Not Found for url: http+docker://localhost/v1.41/images/aghost7/nodejs-dev:noble/json

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/Users/jonathanboudreau/Library/Caches/pypoetry/virtualenvs/slipway-axL3wFL9-py3.12/lib/python3.12/site-packages/docker/models/images.py", line 333, in get
    return self.prepare_model(self.client.api.inspect_image(name))
                              ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/jonathanboudreau/Library/Caches/pypoetry/virtualenvs/slipway-axL3wFL9-py3.12/lib/python3.12/site-packages/docker/utils/decorators.py", line 19, in wrapped
    return f(self, resource_id, *args, **kwargs)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/jonathanboudreau/Library/Caches/pypoetry/virtualenvs/slipway-axL3wFL9-py3.12/lib/python3.12/site-packages/docker/api/image.py", line 251, in inspect_image
    return self._result(
           ^^^^^^^^^^^^^
  File "/Users/jonathanboudreau/Library/Caches/pypoetry/virtualenvs/slipway-axL3wFL9-py3.12/lib/python3.12/site-packages/docker/api/client.py", line 281, in _result
    self._raise_for_status(response)
  File "/Users/jonathanboudreau/Library/Caches/pypoetry/virtualenvs/slipway-axL3wFL9-py3.12/lib/python3.12/site-packages/docker/api/client.py", line 277, in _raise_for_status
    raise create_api_error_from_http_exception(e) from e
          ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/Users/jonathanboudreau/Library/Caches/pypoetry/virtualenvs/slipway-axL3wFL9-py3.12/lib/python3.12/site-packages/docker/errors.py", line 39, in create_api_error_from_http_exception
    raise cls(e, response=response, explanation=explanation) from e
docker.errors.ImageNotFound: 404 Client Error for http+docker://localhost/v1.41/images/aghost7/nodejs-dev:noble/json: Not Found ("failed to find image aghost7/nodejs-dev:noble: docker.io/aghost7/nodejs-dev:noble: No such image")

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions