From d6d53e65d4d84daf97939a4edfa79cc38c0bba72 Mon Sep 17 00:00:00 2001 From: Julian Oes Date: Wed, 14 Feb 2024 10:25:34 +1300 Subject: [PATCH] setup: fix version for setuptools=66 We need to append the git hash with a +. Signed-off-by: Julian Oes --- setup.py | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/setup.py b/setup.py index 097f2960..ff704d3f 100644 --- a/setup.py +++ b/setup.py @@ -120,11 +120,14 @@ def download_mavsdk_server(self): def version(): process = subprocess.Popen(["git", "describe", "--tags"], stdout=subprocess.PIPE) - (output, err) = process.communicate() + output, _ = process.communicate() exit_code = process.wait() if exit_code != 0: raise RuntimeError(f"git describe command exited with: {exit_code}") - return output.decode("utf-8").strip() + git_describe_str = output.decode("utf-8").strip() + git_describe_str = git_describe_str.replace("-g", "+g") + print(git_describe_str) + return git_describe_str setup(