CI: Old versions of git can't handle merges #26163

issue luke-jr opened this issue on September 23, 2022
  1. luke-jr commented at 5:52 PM on September 23, 2022: member

    It appears git versions older than 2.33 can't handle some simple merges, and many of our CI tasks use such old versions.

    The simplest fix is probably to just use GitHub's generated merge branch rather than trying to merge in each CI instance, but I haven't tested it.

  2. luke-jr added the label Bug on Sep 23, 2022
  3. MarcoFalke commented at 1:17 PM on September 24, 2022: member
  4. MarcoFalke commented at 6:25 PM on September 28, 2022: member

    Though, I am not sure if the added complexity to the CI system is worth the rare edge cases.

  5. luke-jr commented at 7:12 PM on September 28, 2022: member

    If it's simply a matter of using origin-pull/N/merge instead of origin-pull/N/head, it doesn't seem that complex?

  6. MarcoFalke commented at 7:30 PM on September 28, 2022: member

    what is the ref called? This doesn't work:

    diff --git a/.cirrus.yml b/.cirrus.yml
    index ae962f2906..6cb7253162 100644
    --- a/.cirrus.yml
    +++ b/.cirrus.yml
    @@ -30,8 +30,8 @@ base_template: &BASE_TEMPLATE
         - git config --global user.email "ci@ci.ci"
         - git config --global user.name "ci"
         - if [ "$CIRRUS_PR" = "" ]; then exit 0; fi
    -    - git fetch $CIRRUS_REPO_CLONE_URL $CIRRUS_BASE_BRANCH
    -    - git merge FETCH_HEAD  # Merge base to detect silent merge conflicts
    +    - git fetch $CIRRUS_REPO_CLONE_URL "${CIRRUS_PR}/merge"
    +    - git checkout FETCH_HEAD  # Use merged changes to detect silent merge conflicts
     
     main_template: &MAIN_TEMPLATE
       timeout_in: 120m  # https://cirrus-ci.org/faq/#instance-timed-out
    
  7. luke-jr commented at 7:55 PM on September 28, 2022: member

    Try "pull/${CIRRUS_PR}/merge"

  8. MarcoFalke closed this on Sep 29, 2022

  9. MarcoFalke reopened this on Sep 29, 2022

  10. MarcoFalke closed this on Sep 29, 2022

  11. sidhujag referenced this in commit a44a60a549 on Sep 30, 2022
  12. bitcoin locked this on Sep 29, 2023

github-metadata-mirror

This is a metadata mirror of the GitHub repository bitcoin/bitcoin. This site is not affiliated with GitHub. Content is generated from a GitHub metadata backup.
generated: 2026-04-14 15:13 UTC

This site is hosted by @0xB10C
More mirrored repositories can be found on mirror.b10c.me