Uploaded image for project: 'Bitbucket Cloud'
  1. Bitbucket Cloud
  2. BCLOUD-21201

Pull request updated webhook payload has a different commit hash size than other webhooks

      Issue Summary

      The PR:updated or PR:created webhooks truncate commit hashes instead of giving you the full commit hash.

      This is a problem mainly with workflows that require git fetch to be executed - Git fetch requires the full commit hash, so this limitation actively breaks certain workflows

      Steps to Reproduce

      1. Create a webhook that has PR:updated or PR:Created as its event
      2. Trigger the PR:updated/PR:createdevent by updating a Pull request
      3. You should be able to see that the payload truncates the commit SHA field to have only the first 12 characters of the commit SHA

      Expected Results

      The complete commit SHA should be sent on the payload, like this:

      [...]
      {"commitId":"abc15321e9fa3485898703e88d3a72a6161adf4b",
      [...]
      

      Actual Results

      Only the first 12 characters of the commit SHA are sent on the PR:Updated or PR:Created events:

      [...]
      {"commitId":"abc15321e9fa",
      [...]
      

      Workaround

      Currently, there is no way to work around this, in case you require the hook payload to run Git fetch.
      A workaround will be added here when available

            [BCLOUD-21201] Pull request updated webhook payload has a different commit hash size than other webhooks

            SET Analytics Bot made changes -
            UIS Original: 1833 New: 1834
            SET Analytics Bot made changes -
            UIS Original: 1832 New: 1833
            SET Analytics Bot made changes -
            UIS Original: 1830 New: 1832
            SET Analytics Bot made changes -
            UIS Original: 1829 New: 1830
            SET Analytics Bot made changes -
            UIS Original: 1828 New: 1829
            SET Analytics Bot made changes -
            UIS Original: 1827 New: 1828
            SET Analytics Bot made changes -
            UIS Original: 1826 New: 1827
            SET Analytics Bot made changes -
            UIS Original: 1825 New: 1826
            SET Analytics Bot made changes -
            UIS Original: 1826 New: 1825
            SET Analytics Bot made changes -
            UIS Original: 1825 New: 1826

              Unassigned Unassigned
              lmontiel@atlassian.com Leonardo M
              Affected customers:
              5 This affects my team
              Watchers:
              8 Start watching this issue

                Created:
                Updated: