diff --git a/src/ci/azure-pipelines/pr.yml b/src/ci/azure-pipelines/pr.yml index 62e23efe1ef16..bd4ba352fe61b 100644 --- a/src/ci/azure-pipelines/pr.yml +++ b/src/ci/azure-pipelines/pr.yml @@ -32,4 +32,5 @@ jobs: parameters: only_on_updated_submodules: 'yes' variables: + FORCE_FAIL_TOOLSTATE: true IMAGE: x86_64-gnu-tools diff --git a/src/ci/docker/x86_64-gnu-tools/checktools.sh b/src/ci/docker/x86_64-gnu-tools/checktools.sh index 4243effdf9b4b..1548d85d52b3e 100755 --- a/src/ci/docker/x86_64-gnu-tools/checktools.sh +++ b/src/ci/docker/x86_64-gnu-tools/checktools.sh @@ -56,7 +56,16 @@ verify_submodule_changed() { echo "If you do NOT intend to update '$1', please ensure you did not accidentally" echo "change the submodule at '$2'. You may ask your reviewer for the" echo "proper steps." - exit 3 + # exit if we're in beta week, otherwise we don't want to, + # it's fine to land changes/regressions to toolstate + if [ $SIX_WEEK_CYCLE -ge 35 ]; then + exit 3 + fi + # we want the PR builder to error out even though the auto branch + # builder will not + if [ -n "$FORCE_FAIL_TOOLSTATE" ]; then + exit 3 + fi fi fi } @@ -105,21 +114,11 @@ status_check() { status_check "submodule_changed" -CHECK_NOT="$(readlink -f "$(dirname $0)/checkregression.py")" # This callback is called by `commit_toolstate_change`, see `repo.sh`. change_toolstate() { - # only update the history - if python2.7 "$CHECK_NOT" "$OS" "$TOOLSTATE_FILE" "_data/latest.json" changed; then - echo 'Toolstate is not changed. Not updating.' - else - if [ $SIX_WEEK_CYCLE -ge 35 ]; then - # Reject any regressions during the week before beta cutoff. - python2.7 "$CHECK_NOT" "$OS" "$TOOLSTATE_FILE" "_data/latest.json" regressed - fi - sed -i "1 a\\ + sed -i "1 a\\ $COMMIT\t$(cat "$TOOLSTATE_FILE") " "history/$OS.tsv" - fi } if [ "$RUST_RELEASE_CHANNEL" = nightly ]; then