Pull Request Comments
You can read and write comments in the pull request diff viewer, in the standard code editor (for files that belong to an open pull request), and in the Discussions tab of the details panel.
Viewing Comments
You can control how comments are displayed and which comments are shown, independently for the diff viewer, the standard editor, and the Discussions tab.
In the diff viewer
Right-click the diff gutter to toggle either option:
- Show Comments Inline — display comment threads expanded directly in the diff. When turned off, comments are collapsed to gutter icons that you click to open. This preference is global and also available as Show comments inline in diff in Settings | Bitbucket Integration Pro.
- Show Comments from Earlier Commits — when you have filtered the diff to a specific commit or commit range, comments made against other commits are hidden by default. Turn this on to show them in the current diff. Also available from the Comments in Diff Visibility menu on the diff viewer toolbar.
In the standard editor
For a file that belongs to an open pull request, right-click the editor gutter and use the Show Comments submenu to choose how comments appear:
- Inline — show comment threads expanded in the editor.
- Gutter icons — show a clickable icon in the gutter (default).
- Don't show — hide comments in the standard editor.
This preference is global and also available as Show comments in Settings | Bitbucket Integration Pro.
In the Discussions tab
Use the Comments Visibility menu on the Discussions tab toolbar to toggle Show Outdated Comments — comments attached to lines that later commits have changed. They are shown by default; clear this option to hide them from the timeline.
Creating Comments
To add a comment on a line, click the gutter icon in the diff viewer or use the Create Comment for Line action. Click on another line to select the range of lines to create a multi-line comment. On Bitbucket Data Center, multi-line comments require version 9.2 or later.
The comment editor has two buttons:
- Submit — sends the comment to Bitbucket immediately.
- Save Draft — saves the comment locally without submitting. Drafts are only visible to you. You can submit all saved drafts at once using Submit All Drafts in the toolbar.
Reviews
You can batch multiple comments into a single review so the pull request author receives one notification instead of many. On Bitbucket Data Center, reviews require version 7.7 or later.
Check Start review when creating your first comment. All subsequent comments will be added to the review automatically. When you are done, click Finish review to publish all review comments at once. You can also set your review status when finishing:
- Approve
- Request Changes (Cloud) / Needs Work (Data Center)
Tasks
Tasks act as a checklist for the pull request — each task can be resolved independently. How tasks relate to comments differs between platforms:
- On Bitbucket Cloud, a task is attached to a comment. When writing a comment, select Create task to attach one or more tasks to it. You can also highlight text in an existing comment and select Create task to turn that text into a task.
- On Bitbucket Data Center, a comment itself can be a task. When writing a comment, select Is task to mark the whole comment as a task.
Resolving Comments
On Bitbucket Cloud, and on Bitbucket Data Center 8.9 or later, comment threads can be resolved and reopened individually. When replying to or creating a comment, select Resolve discussion (or Reopen discussion) to change the thread's status together with your comment.
On earlier Data Center versions, threads cannot be resolved directly — use tasks to track items that still need attention.
Comment Actions
- Reply — respond to an existing comment thread.
- Edit / Delete — modify or remove your own comments.
- React — add a reaction to a comment. Full emoji reactions are available on Bitbucket Data Center 7.7 or later; Bitbucket Cloud and earlier Data Center versions support likes only.
- Copy Link — copy the comment URL.
- Jump to Diff — navigate to the corresponding line in the diff viewer.
- Jump to Source — navigate to the corresponding line in the editor. Requires the repository to be associated with a local VCS root.
- Jump to Original Diff — navigate to the diff at the revision where the comment was originally made.
- Minimize — collapse the comment.