Open szabi opened 11 months ago
It's probably going to be a breaking change to change the output on the CLI. Perhaps a better solution would be to change it on the Docker Hub side like you said. Let me transfer this issue to the Docker Hub issue tracker directly.
The original issue description was filled for CLI, thanks @thaJeztah for transferring.
On the Hub the solution could be to change
Description
Both DockerHub and the download progress info when executing "docker build" and pulling an image display "GB".
However, when doing "docker build" from a Dockerfile, the CLI displays indeed true Gigabytes, but DockerHub, while also using "GB" as a unit, is actually providing Gibibytes.
Example:
https://hub.docker.com/layers/pytorch/pytorch/2.0.1-cuda11.7-cudnn8-runtime/images/sha256-82e0d379a5dedd6303c89eda57bcc434c40be11f249ddfadfd5673b84351e806?context=explore is displayed as having "2.93 GB" size.
When building an image, download progresses above 2.93, and the process finishes when it reaches 3.14 GB.
Where does the discrepancy come from? The numbers are consistent with 3.14 GB = 2.93 GiB. (but note that DockerHub incorrectly displays GB as a unit).
Reproduce
go to https://hub.docker.com/layers/pytorch/pytorch/2.0.1-cuda11.7-cudnn8-runtime/images/sha256-82e0d379a5dedd6303c89eda57bcc434c40be11f249ddfadfd5673b84351e806?context=explore, note the displayed size (supposedly in "GB"). (='2.93 GB')
build an image with a dockerfile
FROM pytorch/pytorch:2.0.1-cuda11.7-cudnn8-runtime
Expected behavior
To make the experience consistent and not make the user puzzle ("why is it still downloading? We are exceeding image size!"), either:
docker version
docker info
Additional Info
No response