Update from upstream #11

Closed
soksanichenko wants to merge 158 commits from a8_updated into a8
2 changed files with 14 additions and 3 deletions
Showing only changes of commit 980c7ba8fb - Show all commits

View File

@ -272,7 +272,7 @@ def main():
logger, opts.skip_phase + conf.get("skip_phases", []), opts.just_phase
):
sys.exit(1)
errors, warnings = pungi.checks.validate(conf)
errors, warnings = pungi.checks.validate(conf, offline=True)
if not opts.quiet:
# TODO: workaround for config files containing skip_phase = productimg
@ -328,6 +328,13 @@ def main():
logger=logger,
notifier=notifier,
)
errors, warnings = pungi.checks.validate(conf, offline=False)
if errors:
for error in errors:
logger.error("Config validation failed with the error: %s" % error)
fail_to_start("Config validation failed", errors=errors)
sys.exit(1)
notifier.compose = compose
COMPOSE = compose
try:

View File

@ -288,8 +288,12 @@ def resolve_git_ref(repourl, ref):
if re.match(r"^[a-f0-9]{40}$", ref):
# This looks like a commit ID already.
return ref
try:
_, output = git_ls_remote(repourl, ref)
except RuntimeError as e:
raise GitUrlResolveError(
"ref does not exist in remote repo %s with the error %s" % (repourl, e)
)
lines = []
for line in output.split("\n"):