While adding a new repository to existing build plan (with existing repositories) I was faced with the issue that "Test connection" button results in "We couldn't connect to the repository. The details you provided were invalid." and also under the "Username" input field a messages appears stating "Invalid username." which doesn't make much sense to me as with this credentials I'm able to see repositories in the dropdown.
After realizing there is an issue with new repository I tried to "Test Connection" with existing repositories and it results in the same behavior, even though last repository was added just few days ago without problems.
Also, when I run the build (with checkouts from existing repositories) it runs successfully, so the credentials by fact are correct.
In logs nothing interesting
Thank you so much for reaching out to the Atlassian Community.
The Bitbucket Cloud REST APIs were recently updated to comply with GDPR privacy regulations. Part of these updates removed a variable containing information that Bamboo expects in the JSON response from Bitbucket.
This change resulted in the creation of new Linked repositories of type “Bitbucket Cloud” failing with 401 (Unauthorized) exceptions. You may see an “Invalid username” error message in the Bamboo UI, errors in the logs, or issues with the repository lists populating.
For more information, please follow our public bug report:
We have been working with the Bamboo developers to create a hotfix for this issue, which we expect will be ready next week.
We sincerely apologize for any inconvenience this may cause. Please let me know if you have any questions or concerns.
Elias Zeidan | Bamboo Senior Support Engineer
I'm seeing the same issue, but in atlassian-bamboo.log I see this when I hit test connection
2019-05-31 12:55:24,557 WARN [http-nio-80-exec-18] [RESTCall] Response from GET https://api.bitbucket.org/2.0/teams/<shared credentials account name>/ (404)
The shared credentials account is correct as I'm able to use it to list out repos and branches, but test connection fails and then the repository won't save.
Thanks for your comments! This looks like a new issue related to Bitbucket Cloud API updates. We've published a new Article about this issue which can be found here:
Bitbucket Cloud now uses the Workspaces API, and requires use of the Bitbucket username instead of email address for authentication.
@Matt Hubble the error logs from the more recent issue match what you posted in your comment. Is the <shared credentials account name> an email address? If you are able to upgrade, Bamboo 6.10.6 and 7.0.3 use the new Workspace API by default.
I hope this helps!
Elias | Bamboo Senior Support Engineer
G’day Community! As we gear up to introduce Bamboo Data Center to the world, we wanted to make sure that we shared a bit more about Bamboo, the product. Our team has put together an overview video ...
Connect with like-minded Atlassian users at free events near you!Find an event
Connect with like-minded Atlassian users at free events near you!
Unfortunately there are no Community Events near you at the moment.Host an event
You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events