Gerrit - New feature launch - User Suggest Edit

200 views
Skip to first unread message

Milutin Kristofic

unread,
May 2, 2023, 8:06:39 PM5/2/23
to chromi...@chromium.org

Hi Gerrit users, 


We are excited to announce the rollout of the “User Suggest Edit “feature that will enable reviewers to directly suggest code edits in Gerrit. The proposed edits can be reviewed, accepted, or adapted by the change author. 

We hope this feature will speed up the code changes by allowing the author to accept suggested code changes without having to make local updates and reuploading a patchset


What: 

  1. Reviewers can now use the “Suggest Edit” button from within the comment dialog box to suggest a code block to replace the selected content in a file.

  2. Reviewers can preview the suggestion in full file diff

  3. The suggestion is part of comment and Reviewers send it to the author as other comments with the “Reply” 

  4. Author can view all the suggested edits in a file

  5. Author can apply suggestion as is, copy & paste the suggestion to adapt, or reject the suggestion

  6. Author can also preview the suggested edits in full file diff


When:

The features will finish rolling out this Friday (April 28th)


Why:

We want to provide a workflow for the reviewers and authors to suggest, review, and apply code blocks directly to increase the speed of the code changes. This will also help improve the effectiveness of the comments and enable knowledge sharing from senior SWEs. We aim to reduce the overall change review time by increased usage of suggested edits as compared to simple comments. 


Impact:

  1. A new “Suggest Edit” link for reviewers in the comments dialog

  2. A new “Show Edit” link for the reviewer to see the suggestion in full file diff view 

  3. A new “Show Edit” link for the authors to see the suggestion in full file diff view

  4. A new “Apply Edit” link for the author in the diff view (launched from preview edit) to apply the suggestion.




Exceptions:

  1. Suggested Edit feature is not available for commit messages

  2. Suggested Edits for a previous patchset can not be directly applied in the code on the current patchset to generate a new patchset by the author. Instead, the author will need to copy and paste the suggestion


Help:



Thanks,

- Milutin on behalf of the Gerrit Code Review team


Reply all
Reply to author
Forward
0 new messages