aboutsummaryrefslogtreecommitdiff
path: root/test/functional/interface_bitcoin_cli.py
diff options
context:
space:
mode:
authorRyan Ofsky <ryan@ofsky.org>2023-10-03 08:43:16 -0400
committerRyan Ofsky <ryan@ofsky.org>2023-10-05 11:00:15 -0400
commit88c8e3a0e4d6bee015a348536c6e12a2c7835896 (patch)
tree76fe4742d1231edb1fc46b695ddfba7b40b8f7f5 /test/functional/interface_bitcoin_cli.py
parent693a7cfc6c5f631af7feb74beec5695647f87bab (diff)
github actions: Fix test-one-commit when parent of head is merge commit
Instead of figuring out the commit *after* the last merge and rebasing on that with a ~1 suffix, just figure out the last merge commit directly and rebase on it. This way, if HEAD happens to be a merge commit, the rebase just succeeds immediately without blank variables or errors. From https://github.com/bitcoin/bitcoin/pull/28497#issuecomment-1743430631: The problem is that the PR only contains a one commit after the last merge, so the job _should_ be skipped, but the `pull_request.commits != 1` check is not smart enough to skip it because the PR is based on another PR and has merge ancestor commits. So specifically what happens is that after HEAD~ is checked out, the new HEAD is a merge commit, so the range `$(git log --merges -1 --format=%H)..HEAD` is equivalent to HEAD..HEAD, which is empty, so the `COMMIT_AFTER_LAST_MERGE` variable is empty and the rebase command fails.
Diffstat (limited to 'test/functional/interface_bitcoin_cli.py')
0 files changed, 0 insertions, 0 deletions