incubator-devlake icon indicating copy to clipboard operation
incubator-devlake copied to clipboard

[Feature][Bitbucket] Collect Pull Request Reviewer Status (Approved / Changes Requested) for metrics

Open oguzgu opened this issue 3 months ago • 0 comments

Search before asking

  • [x] I had searched in the issues and found no similar feature requirement.

Use case

No response

Description

Currently, the Bitbucket Cloud plugin collects Pull Request metadata (title, author, merge status), but it does not collect the reviewer status (e.g., APPROVED, CHANGES_REQUESTED / NEEDS_WORK).

I am trying to calculate metrics like "Review Quality" or "Change Request Rate" (percentage of PRs that required changes before merging). However, checking the database reveals that this data is missing in both raw and tool layers.

The Problem I checked the _tool_bitbucket_pull_requests table, and there is no column for reviewer status.

I checked the _raw_bitbucket_api_pull_requests table to see the raw JSON response. The data column contains author, closed_by, and comment_count, but it does NOT contain the reviewers or participants list with their statuses.

{
  "type": "pullrequest",
  "id": 2441,
  "state": "MERGED",
  "author": { ... },
  "closed_by": { ... },
  "comment_count": 11
  // "reviewers" or "participants" array is missing here
}

Related issues

No response

Are you willing to submit a PR?

  • [ ] Yes I am willing to submit a PR!

Code of Conduct

oguzgu avatar Dec 10 '25 07:12 oguzgu