Clarify error message for ERROR_ON_CLONE=True
If ERROR_ON_CLONE is set to True which is case for all the devstack based job, devstack does not clone the repo instead raise error. From current error message, it is difficult to know that ERROR_ON_CLONE is True until we traceback the code or check devstack-base job set ERROR_ON_CLONE to True. Current error message is like: ------- + functions-common:git_clone:560 : echo 'The /opt/stack/oslo.limit project was not found; if this is a gate job, add' The /opt/stack/oslo.limit project was not found; if this is a gate job, add + functions-common:git_clone:561 : echo 'the project to the $PROJECTS variable in the job definition.' the project to the $PROJECTS variable in the job definition. + functions-common:git_clone:562 : die 562 'Cloning not allowed in this configuration' -------- Adding ERROR_ON_CLONE info in error message will help to know the reason of devstack not cloning the repo. Change-Id: I9e9852f046fefb299b4ef4446323e9c86437212f
This commit is contained in:
parent
82facd6edf
commit
325792d9b9
|
@ -547,7 +547,7 @@ function git_clone {
|
|||
if [[ "$ERROR_ON_CLONE" = "True" ]]; then
|
||||
echo "The $git_dest project was not found; if this is a gate job, add"
|
||||
echo "the project to 'required-projects' in the job definition."
|
||||
die $LINENO "Cloning not allowed in this configuration"
|
||||
die $LINENO "ERROR_ON_CLONE is set to True so cloning not allowed in this configuration"
|
||||
fi
|
||||
git_timed clone $git_clone_flags $git_remote $git_dest
|
||||
fi
|
||||
|
@ -559,7 +559,7 @@ function git_clone {
|
|||
if [[ "$ERROR_ON_CLONE" = "True" ]]; then
|
||||
echo "The $git_dest project was not found; if this is a gate job, add"
|
||||
echo "the project to the \$PROJECTS variable in the job definition."
|
||||
die $LINENO "Cloning not allowed in this configuration"
|
||||
die $LINENO "ERROR_ON_CLONE is set to True so cloning not allowed in this configuration"
|
||||
fi
|
||||
# '--branch' can also take tags
|
||||
git_timed clone $git_clone_flags $git_remote $git_dest --branch $git_ref
|
||||
|
|
Loading…
Reference in New Issue