From 0d0ddf2e587dc12f15f47beba4858f2448a3b367 Mon Sep 17 00:00:00 2001 From: whitequark Date: Thu, 20 Apr 2017 16:40:10 +0000 Subject: [PATCH] conda: limit git hashes in build numbers to 8 chars exactly. Before this commit, a nasty edge case was possible where repositories on different builders have had different sets of objects fetched into them, and so git-describe selected different lengths for abbreviating hashes. See also https://github.com/conda/conda-build/issues/1940. --- conda/artiq-dev/meta.yaml | 2 +- conda/artiq-kc705-nist_clock/meta.yaml | 2 +- conda/artiq-kc705-nist_qc2/meta.yaml | 2 +- conda/artiq-kc705-phaser/meta.yaml | 2 +- conda/artiq-pipistrello-demo/meta.yaml | 2 +- conda/artiq/meta.yaml | 2 +- 6 files changed, 6 insertions(+), 6 deletions(-) diff --git a/conda/artiq-dev/meta.yaml b/conda/artiq-dev/meta.yaml index a08765fa5..6fa20a18a 100644 --- a/conda/artiq-dev/meta.yaml +++ b/conda/artiq-dev/meta.yaml @@ -8,7 +8,7 @@ source: build: noarch_python: true number: {{ environ.get("GIT_DESCRIBE_NUMBER", 0) }} - string: py_{{ environ.get("GIT_DESCRIBE_NUMBER", 0) }}+git{{ environ.get("GIT_DESCRIBE_HASH", "")[1:] }} + string: py_{{ environ.get("GIT_DESCRIBE_NUMBER", 0) }}+git{{ environ.get("GIT_DESCRIBE_HASH", "")[1:9] }} requirements: run: diff --git a/conda/artiq-kc705-nist_clock/meta.yaml b/conda/artiq-kc705-nist_clock/meta.yaml index 5028ad009..e158a5623 100644 --- a/conda/artiq-kc705-nist_clock/meta.yaml +++ b/conda/artiq-kc705-nist_clock/meta.yaml @@ -8,7 +8,7 @@ source: build: noarch_python: true number: {{ environ.get("GIT_DESCRIBE_NUMBER", 0) }} - string: py_{{ environ.get("GIT_DESCRIBE_NUMBER", 0) }}+git{{ environ.get("GIT_DESCRIBE_HASH", "")[1:] }} + string: py_{{ environ.get("GIT_DESCRIBE_NUMBER", 0) }}+git{{ environ.get("GIT_DESCRIBE_HASH", "")[1:9] }} requirements: build: diff --git a/conda/artiq-kc705-nist_qc2/meta.yaml b/conda/artiq-kc705-nist_qc2/meta.yaml index 76032bbaa..ae7946985 100644 --- a/conda/artiq-kc705-nist_qc2/meta.yaml +++ b/conda/artiq-kc705-nist_qc2/meta.yaml @@ -8,7 +8,7 @@ source: build: noarch_python: true number: {{ environ.get("GIT_DESCRIBE_NUMBER", 0) }} - string: py_{{ environ.get("GIT_DESCRIBE_NUMBER", 0) }}+git{{ environ.get("GIT_DESCRIBE_HASH", "")[1:] }} + string: py_{{ environ.get("GIT_DESCRIBE_NUMBER", 0) }}+git{{ environ.get("GIT_DESCRIBE_HASH", "")[1:9] }} requirements: build: diff --git a/conda/artiq-kc705-phaser/meta.yaml b/conda/artiq-kc705-phaser/meta.yaml index 8697b88d0..c9aca8755 100644 --- a/conda/artiq-kc705-phaser/meta.yaml +++ b/conda/artiq-kc705-phaser/meta.yaml @@ -8,7 +8,7 @@ source: build: noarch_python: true number: {{ environ.get("GIT_DESCRIBE_NUMBER", 0) }} - string: py_{{ environ.get("GIT_DESCRIBE_NUMBER", 0) }}+git{{ environ.get("GIT_DESCRIBE_HASH", "")[1:] }} + string: py_{{ environ.get("GIT_DESCRIBE_NUMBER", 0) }}+git{{ environ.get("GIT_DESCRIBE_HASH", "")[1:9] }} requirements: build: diff --git a/conda/artiq-pipistrello-demo/meta.yaml b/conda/artiq-pipistrello-demo/meta.yaml index d2fec0824..66d02b166 100644 --- a/conda/artiq-pipistrello-demo/meta.yaml +++ b/conda/artiq-pipistrello-demo/meta.yaml @@ -8,7 +8,7 @@ source: build: noarch_python: true number: {{ environ.get("GIT_DESCRIBE_NUMBER", 0) }} - string: py_{{ environ.get("GIT_DESCRIBE_NUMBER", 0) }}+git{{ environ.get("GIT_DESCRIBE_HASH", "")[1:] }} + string: py_{{ environ.get("GIT_DESCRIBE_NUMBER", 0) }}+git{{ environ.get("GIT_DESCRIBE_HASH", "")[1:9] }} requirements: build: diff --git a/conda/artiq/meta.yaml b/conda/artiq/meta.yaml index 4bebcdc53..d73c90270 100644 --- a/conda/artiq/meta.yaml +++ b/conda/artiq/meta.yaml @@ -8,7 +8,7 @@ source: build: noarch_python: true number: {{ environ.get("GIT_DESCRIBE_NUMBER", 0) }} - string: py_{{ environ.get("GIT_DESCRIBE_NUMBER", 0) }}+git{{ environ.get("GIT_DESCRIBE_HASH", "")[1:] }} + string: py_{{ environ.get("GIT_DESCRIBE_NUMBER", 0) }}+git{{ environ.get("GIT_DESCRIBE_HASH", "")[1:9] }} requirements: build: