aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--mod/mod-ci-github-gh.hxx4
-rw-r--r--mod/mod-ci-github.cxx14
2 files changed, 10 insertions, 8 deletions
diff --git a/mod/mod-ci-github-gh.hxx b/mod/mod-ci-github-gh.hxx
index 4535622..6ede697 100644
--- a/mod/mod-ci-github-gh.hxx
+++ b/mod/mod-ci-github-gh.hxx
@@ -184,8 +184,8 @@ namespace brep
gh_pull_request pull_request;
- // The SHA of the most recent commit on the head branch before the pull
- // request. Only present if action is "synchronize".
+ // The SHA of the previous commit on the head branch before the current
+ // one. Only present if action is "synchronize".
//
optional<string> before;
diff --git a/mod/mod-ci-github.cxx b/mod/mod-ci-github.cxx
index 7037dfb..119968d 100644
--- a/mod/mod-ci-github.cxx
+++ b/mod/mod-ci-github.cxx
@@ -1511,21 +1511,23 @@ namespace brep
true /* ref_count */))
{
l3 ([&]{trace << "pull request " << pr.pull_request.node_id
- << ": canceled CI of previous head commit"
+ << ": attempted to cancel CI of previous head commit"
<< " (ref_count: " << ts->ref_count << ')';});
}
else
{
- error << "pull request " << pr.pull_request.node_id
- << ": failed to cancel CI of previous head commit "
- << "with tenant_service id " << sid;
+ // It's possible that there was no CI for the previous commit for
+ // various reasons (e.g., CI was not enabled).
+ //
+ l3 ([&]{trace << "pull request " << pr.pull_request.node_id
+ << ": failed to cancel CI of previous head commit "
+ << "with tenant_service id " << sid;});
}
}
else
{
error << "pull request " << pr.pull_request.node_id
- << ": `before` member is missing"
- << " so cannot cancel CI of previous head commit";
+ << ": before commit is missing in synchronize event";
}
}