Ensure tag can be looked up outside cgit

Under the very special cases where a release still need to happen
for a deliverable which contained releases of a deprecated
repository, the release would fail.

A deprecated repository has its ACL changed and therefore the
interface to cgit disappears. We cannot reliably use cgit for
discovering references.

Because all the repositories should have been already staged
in workdir, we could directly fetch the reference there.
And because a tag is a reference like a commit, we re-use
the same code to discover the presence of the tag.

Change-Id: Idad096e334ba444d28faf064b7d7f2d3d163ca8e
This commit is contained in:
Jean-Philippe Evrard
2017-09-29 09:15:43 +00:00
parent 7b7bb69839
commit 2f9bf8068e

View File

@@ -423,8 +423,9 @@ def validate_releases(deliverable_info, zuul_layout,
# doesn't exist.
continue
version_exists = gitutils.tag_exists(
project['repo'], release['version'],
# Check the presence of tag in the references
version_exists = gitutils.commit_exists(
workdir, project['repo'], release['version'],
)
# Check that the sdist name and tarball-base name match.