Skip to content
This repository has been archived by the owner on Dec 8, 2020. It is now read-only.

Bitbucket API: "username" deprecated #36

Open
kmoe opened this issue Jun 18, 2019 · 1 comment
Open

Bitbucket API: "username" deprecated #36

kmoe opened this issue Jun 18, 2019 · 1 comment
Assignees

Comments

@kmoe
Copy link
Member

kmoe commented Jun 18, 2019

As of 29th April 2019, the username field in the Bitbucket API is deprecated:

https://developer.atlassian.com/cloud/bitbucket/bitbucket-api-changes-gdpr/#removal-of-usernames-from-user-referencing-apis

The Bitbucket Terraform Provider currently uses usernames to specify the following resource attributes in Terraform configuration:

bitbucket_respository.owner

Used in requests to the /2.0/repositories/{username} endpoint.

As of 18th June 2019, this still works.

Recommendation

Deprecate bitbucket_repository.owner with a warning and add new attribute bitbucket_repository.owner_uuid. Either owner or owner_uuid must be specified.

bitbucket_default_reviewers.owner

Used in requests to the /2.0/repositories/{username}/{repo_slug}/default-reviewers endpoint .

As of 18th June 2019, this still works.

Recommendation

Deprecate bitbucket_default_reviewers.owner with a warning and add new attribute bitbucket_default_reviewers.owner_uuid. Either owner or owner_uuid must be specified.

bitbucket_default_reviewers.reviewers

Used in requests to the /2.0/repositories/{username}/{repo_slug}/default-reviewers/{target_username} endpoint, and responses from GET /2.0/repositories/{username}/{repo_slug}/default-reviewers.

Only UUIDs, and not usernames, are returned when requesting the default reviewers.

Recommendation

Specifying default reviewers via username is now broken. See #37 for details.

bitbucket_hook.owner

Used in requests to the /2.0/repositories/{username}/{repo_slug}/hooks endpoint.

As of 18th June 2019, this still works.

Recommendation

Deprecate bitbucket_hook.owner with a warning and add new attribute bitbucket_hook.owner_uuid. Either owner or owner_uuid must be specified.

@kmoe
Copy link
Member Author

kmoe commented Jun 18, 2019

@cwood This is the result into my investigation into the new acceptance test failure in #35. Would you mind taking a look and letting me know if you agree with the analysis?

@kmoe kmoe changed the title BitBucket API: "username" deprecated Bitbucket API: "username" deprecated Jun 18, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants