diff options
author | Utku Demir <me@utdemir.com> | 2020-06-21 12:18:28 +1200 |
---|---|---|
committer | Utku Demir <me@utdemir.com> | 2020-06-21 12:35:39 +1200 |
commit | fe71abfc12ede6700f599a08c7528fe66461486f (patch) | |
tree | c1f344a8b2fb30c1cfa9427fdcb87759acf4d0e8 /pkgs/build-support | |
parent | 87a538e149cbf41361afda3b417eac1632f00c5b (diff) |
stream_layered_image: Clarify assertion failure
Diffstat (limited to 'pkgs/build-support')
-rw-r--r-- | pkgs/build-support/docker/stream_layered_image.py | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/pkgs/build-support/docker/stream_layered_image.py b/pkgs/build-support/docker/stream_layered_image.py index bbad5f5023c48..5d251e8bfb057 100644 --- a/pkgs/build-support/docker/stream_layered_image.py +++ b/pkgs/build-support/docker/stream_layered_image.py @@ -146,7 +146,9 @@ def add_layer_dir(tar, paths, mtime, add_nix=True, filter=None): the layer added. """ - assert all(i.startswith("/nix/store/") for i in paths) + invalid_paths = [i for i in paths if not i.startswith("/nix/store/")] + assert len(invalid_paths) == 0, \ + "Expecting absolute store paths, but got: {invalid_paths}" # First, calculate the tarball checksum and the size. extract_checksum = ExtractChecksum() |