GeezerVisonThe World Wide Web, restored to 800 pixels of glory. | |||||||||
| Home|About|Gaming cabinet|Archives|How it works|Starter sites | |||||||||
GeezerVison is showing github.com — feat(scm): add bitbucket cloud scm and action support by mcwarman · Pull Request #2847 · updatecli/updatecli Conversation
Member
Add support for Bitbucket Cloud:
Also updates documentation for stash to make it clearer its Bitbucket Server. TestTo test this pull request, you can run the following commands: go build -o bin/updatecli ./bin/updatecli diff --config ./e2e/updatecli.d/success.d/bitbucket/scm.yaml Additional InformationTradeoffBitbucket doesn't support any HTML in PR descriptions, so I had to add Markdown only views. There's a potential the format could be improved going forward Potential improvementMarkdown format of PRs.
Sorry, something went wrong. Uh oh!
There was an error while loading. Please reload this page. All reactions
Member
Author
All reactions
Sorry, something went wrong. Uh oh!
There was an error while loading. Please reload this page.
Member
All reactions
Sorry, something went wrong. Uh oh!
There was an error while loading. Please reload this page.
|
There was an error while loading. Please reload this page.
Yeah I've started using Bitbucket in my new role, its not my favourite user experience. It also doesn't support HTML comments so we couldn't get clever with hiding information in them either. |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
6ff7c57 to
1d2248d
Compare
|
@mcwarman I just open a pullrequest on your fork, to update the e2e tests Apparently, I already created a Bitbucket account, and we can have up to 5 people on that workspace |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
|
I just tested this pullrequest and it seems to work great 🎉 |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
|
Could I ask to also add a documentation page to the website next to https://github.com/updatecli/website/tree/master/content/en/docs/plugins/scm |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
|
I don't have access to see that repo on bitbucket (if you added I'll add the docs for using it. |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
|
We either need to make the test repo public, or set BITBUCKET_TOKEN for the e2e generated from the repo: Ref: https://support.atlassian.com/bitbucket-cloud/docs/access-tokens/ |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
Well I thought it already made it public, I'll check that later |
Sorry, something went wrong.
There was an error while loading. Please reload this page.
There was a problem hiding this comment.
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the pull request, it looks great.
Sorry, something went wrong.
There was an error while loading. Please reload this page.
… action isRemoteBranchesExist() fetched all remote branches via a paginated list scan (Page: 1, Size: 30 with no follow-through) to check whether the source and target branches exist. On repositories with more than 30 branches this silently returned false, causing CreateAction to log "skipping pull request creation" at Debug level and exit with nil — the job appeared green with no PR and no visible explanation. Replace the list scan with two direct FindBranch calls (one per branch). This mirrors the approach used by GitHub's GraphQL implementation and is O(1) regardless of repository branch count. A 404 response from FindBranch is treated as a missing branch and logged at Warning level so the failure is visible without --debug. Also fix isPullRequestExist() which had the same Size: 30 truncation: it now paginates using resp.Page.Next until all open pull requests have been checked. Fixes the same class of bug as updatecli#1905 (GitLab) which was introduced when the Bitbucket Cloud plugin was added in updatecli#2847.
… action (#8584) isRemoteBranchesExist() fetched all remote branches via a paginated list scan (Page: 1, Size: 30 with no follow-through) to check whether the source and target branches exist. On repositories with more than 30 branches this silently returned false, causing CreateAction to log "skipping pull request creation" at Debug level and exit with nil — the job appeared green with no PR and no visible explanation. Replace the list scan with two direct FindBranch calls (one per branch). This mirrors the approach used by GitHub's GraphQL implementation and is O(1) regardless of repository branch count. A 404 response from FindBranch is treated as a missing branch and logged at Warning level so the failure is visible without --debug. Also fix isPullRequestExist() which had the same Size: 30 truncation: it now paginates using resp.Page.Next until all open pull requests have been checked. Fixes the same class of bug as #1905 (GitLab) which was introduced when the Bitbucket Cloud plugin was added in #2847. Co-authored-by: Olivier Vernin <[email protected]>
There was an error while loading. Please reload this page.
Successfully merging this pull request may close these issues.
There was an error while loading. Please reload this page.