You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@buildstream.apache.org by tv...@apache.org on 2022/01/14 02:15:11 UTC

[buildstream] 02/03: testing/_update_cachekeys.py: Fixed to actually work.

This is an automated email from the ASF dual-hosted git repository.

tvb pushed a commit to branch tristan/fix-cache-key-test
in repository https://gitbox.apache.org/repos/asf/buildstream.git

commit 82a82907a13e7b20e31554ec1735baa7de999f3b
Author: Tristan van Berkom <tr...@codethink.co.uk>
AuthorDate: Fri Jan 14 11:11:40 2022 +0900

    testing/_update_cachekeys.py: Fixed to actually work.
    
    At some point we changed Cli() to create it's directory in order to simplify
    some code, but we didn't update this file which directly uses Cli().
---
 src/buildstream/testing/_update_cachekeys.py | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/src/buildstream/testing/_update_cachekeys.py b/src/buildstream/testing/_update_cachekeys.py
index 38ac755..232445a 100755
--- a/src/buildstream/testing/_update_cachekeys.py
+++ b/src/buildstream/testing/_update_cachekeys.py
@@ -45,8 +45,10 @@ def update_keys():
     project_dir = os.getcwd()
 
     with tempfile.TemporaryDirectory(dir=project_dir) as cache_dir:
+        directory = os.path.join(str(cache_dir), "cache")
+
         # Run bst show
-        cli = Cli(cache_dir, verbose=True)
+        cli = Cli(directory, verbose=True)
         result = cli.run(
             project=project_dir, silent=True, args=["--no-colors", "show", "--format", "%{name}::%{full-key}"],
         )