question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

ImageNotFound error if no :latest tag exists (version 2.2.1)

See original GitHub issue

Steps to reproduce:

import docker
client = docker.from_env()
target_img_tags = client.images.pull("deis/store-daemon").tags

Raises: docker.errors.ImageNotFound: 404 Client Error: Not Found ("No such image: deis/store-daemon")

doing a docker images | grep deis gives us:

deis/store-daemon                 v1.13.4                                    eb4b06970e51        2 months ago        120 MB
deis/store-daemon                 v1.13.3                                    68b109613922        7 months ago        394 MB
deis/store-daemon                 v1.13.2                                    f1d1a8456bba        9 months ago        394 MB
deis/store-daemon                 v1.13.1                                    ea7d19df6386        11 months ago       393 MB
deis/store-daemon                 v1.13.0                                    805a931c762a        12 months ago       393 MB
deis/store-daemon                 v1.12.3                                    6578514c16a4        13 months ago       380 MB
deis/store-daemon                 v1.12.2                                    eefcc52df297        16 months ago       380 MB
deis/store-daemon                 v1.12.1                                    1e071363779f        17 months ago       380 MB
deis/store-daemon                 v1.12.0                                    6260dcca6ebc        17 months ago       380 MB
deis/store-daemon                 v1.12.0-rc3                                6260dcca6ebc        17 months ago       380 MB
deis/store-daemon                 v1.12.0-rc2                                2933f901c9bc        17 months ago       380 MB
deis/store-daemon                 v1.12.0-rc1                                8e1c91b7f55f        17 months ago       380 MB
deis/store-daemon                 v1.11.2                                    62f342b7b23d        17 months ago       380 MB
deis/store-daemon                 v1.11.1                                    d6615a82e85f        18 months ago       380 MB
deis/store-daemon                 v1.11.0                                    352abf8cd7ed        18 months ago       379 MB
deis/store-daemon                 v1.11.0-rc1                                352abf8cd7ed        18 months ago       379 MB
deis/store-daemon                 v1.10.1                                    0e676a599ff9        18 months ago       380 MB
deis/store-daemon                 v1.10.0                                    b9b8f74b62fd        19 months ago       380 MB
deis/store-daemon                 v1.9.1                                     b86f33c1a7ff        19 months ago       379 MB
deis/store-daemon                 v1.9.0                                     e3132889f86d        20 months ago       379 MB
deis/store-daemon                 v1.8.0                                     f8197dfe2e41        21 months ago       379 MB
deis/store-daemon                 v1.7.3                                     2622ab04aa3a        22 months ago       375 MB
deis/store-daemon                 v1.7.2                                     ad79dfb60604        22 months ago       375 MB
deis/store-daemon                 v1.7.1                                     9e02aa838319        22 months ago       375 MB
deis/store-daemon                 v1.7.0                                     8a61029b06c1        22 months ago       363 MB
deis/store-daemon                 v1.6.1                                     34c0ebfd0849        23 months ago       365 MB
deis/store-daemon                 v1.6.0                                     cc3910403925        23 months ago       365 MB
deis/store-daemon                 v1.5.2                                     479356b8bd80        23 months ago       309 MB
deis/store-daemon                 v1.5.1                                     b2166ae3543a        24 months ago       309 MB
deis/store-daemon                 v1.5.0                                     ace85e5377ee        24 months ago       309 MB
deis/store-daemon                 v1.4.1                                     5a49fe94604b        2 years ago         309 MB
deis/store-daemon                 v1.4.0                                     642240140452        2 years ago         309 MB
deis/store-daemon                 v1.3.1                                     01362bcb8a76        2 years ago         309 MB
deis/store-daemon                 v1.3.0                                     05fb0710a65a        2 years ago         309 MB
deis/store-daemon                 v1.2.2                                     d9bcf549284c        2 years ago         309 MB
deis/store-daemon                 v1.2.0                                     5d1105c57523        2 years ago         309 MB
deis/store-daemon                 v1.2.1                                     5d1105c57523        2 years ago         309 MB
deis/store-daemon                 v1.1.1                                     13d86418a872        2 years ago         309 MB
deis/store-daemon                 v1.1.0                                     e3a488647436        2 years ago         309 MB
deis/store-daemon                 v1.0.2                                     93ff83b6fb02        2 years ago         309 MB
deis/store-daemon                 v1.0.1                                     e78fd233bfe0        2 years ago         309 MB
deis/store-daemon                 v1.0.0                                     8f53a2132059        2 years ago         309 MB
deis/store-daemon                 v0.15.1                                    0907a8407563        2 years ago         290 MB
deis/store-daemon                 v0.15.0                                    0217efa1a137        2 years ago         290 MB
deis/store-daemon                 v0.14.0                                    036230c75c5e        2 years ago         322 MB
deis/store-daemon                 v0.14.1                                    036230c75c5e        2 years ago         322 MB
deis/store-daemon                 v0.13.1                                    8af905a5d2ce        2 years ago         439 MB
deis/store-daemon                 v0.13.0                                    b48548def258        2 years ago         442 MB

So what’s the best way to get a list of image tags, if there’s no :latest tag? The pull downloads all this stuff, but it’s inaccessible via the Python SDK.

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:5

github_iconTop GitHub Comments

1reaction
ghostcommented, Apr 21, 2017

I’m having a similar issue - I try and pull an image using the following:

import docker client = docker.from_env() client.images.pull('bsidescbrctf/2017-crypto-docuprotect', tag='1')

Raises the following:

docker.errors.ImageNotFound: 404 Client Error: Not Found ("no such image: bsidescbrctf/2017-crypto-docuprotect: No such image: bsidescbrctf/2017-crypto-docuprotect:latest")

Not sure why the 1 tag is being replaced by latest.

I have found a way around it by doing:

test = client.images.list('bsidescbrctf/2017-crypto-docuprotect') actual_image = test[0]

But I would prefer to be able to pull the actual image itself.

0reactions
shin-commented, Jan 3, 2018

I agree! PRs are welcome 😃

Read more comments on GitHub >

github_iconTop Results From Across the Web

How do you fix a docker push error, tag does not exist?
I misspelled the tag, so when I tried to push with the correct tag name, it couldn't find it (because it didn't exist...
Read more >
Images — Docker SDK for Python 6.0.1 documentation
ImageNotFound – If the image does not exist. docker.errors. ... Pull the image tagged `latest` in the busybox repo >>> image = client.images.pull('busybox')....
Read more >
docker-sdk-python Documentation - Read the Docs
The latest stable version is available on PyPI. ... ImageNotFound – If the specified image does not exist. • docker.errors.
Read more >
Resolving a Missing Image Tag (Docker Installation)
Check for missing image tags any time that a test fails to run properly on a Private Location. A number of unexpected behaviors...
Read more >
How to push docker image tagged after git branch?
To make tracking of what image was build from what branch easier we tag ... Image not found: 404 Client Error: Not Found...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found