Skip to main content
GitHub Flow
CHAPTER 05

Collaboration and Team Workflows

Updated: May 15, 2026
25 min read

# CHAPTER 5

Collaboration and Team Workflows

1. Introduction

You understand branches and Pull Requests, but software development is fundamentally a human endeavor. How do you know *who* should review your code? What happens when two developers disagree on an architectural decision? How do you request a specific team member's expertise? In this chapter, we will explore the human elements of the GitHub Flow. We will dive into the collaborative tools provided by GitHub—Reviewers, Assignees, and Discussions—and learn the etiquette required to operate smoothly within a fast-paced engineering team.

2. Learning Objectives

By the end of this chapter, you will be able to:
  • Differentiate between Assignees and Reviewers in a Pull Request.
  • Request reviews from specific team members.
  • Utilize inline code comments for constructive feedback.
  • Use the "Draft Pull Request" feature for early collaboration.
  • Understand the etiquette of asynchronous team communication.

3. Beginner Explanation

Imagine you are building a house with a construction crew.
  • The Worker (Assignee): The foreman points at you and says, "You are in charge of building the staircase." You are the *Assignee*. The task belongs to you.
  • The Inspector (Reviewer): You finish the staircase. You call the safety inspector to come look at it. The inspector is the *Reviewer*. They didn't build it, but they must approve it.
  • The Blueprint Table (Discussions): Before you even start building, you gather the crew around a table to look at the blueprints and argue about whether the stairs should be wood or metal. This is the *GitHub Discussions* area.

4. Assignees vs. Reviewers

When you create a Pull Request (or a GitHub Issue), you will see menus on the right-hand sidebar.
  • Assignees: This indicates *who is doing the work*. If you wrote the code in the PR, you assign yourself. This tells the team, "I am the one responsible for driving this PR to completion."
  • Reviewers: This indicates *who needs to check the work*. You select a senior developer or a peer. GitHub will send them a notification saying, "Your review has been requested."

5. Draft Pull Requests

Sometimes you want feedback on your code *before* you are actually finished. Maybe you are stuck on a complex algorithm and want a senior developer's advice. When creating a PR, click the dropdown arrow next to the green "Create pull request" button and select "Create draft pull request".
  • A Draft PR signals to the team: "This is a work in progress. Do not merge this yet!"
  • It allows teammates to look at your code and leave comments while you are still actively developing.
  • Once you are finished, you click "Ready for review" to turn it into a standard PR.

6. Mini Project: Simulate Collaborative Development

Let's simulate interacting with a reviewer's feedback.

Step-by-Step Walkthrough:

  1. 1. Imagine you have a PR open, and a reviewer leaves a comment on line 42: *"Please change this color from red to #FF0000 for consistency."*
  1. 2. Acknowledge: On GitHub, you reply to their comment: *"Good catch, fixing now."* (Communication is key).
  1. 3. Fix: Open your local terminal and editor. Change the color to #FF0000.
  1. 4. Update:
``bash git add . git commit -m "Update color code based on review" git push origin feature/my-branch `
  1. 5. Resolve: Go back to the PR on GitHub. The new commit automatically appears. You click the "Resolve Conversation" button on the reviewer's comment to hide it, signaling the fix is complete.

7. Team Communication Etiquette

  • Tagging: If you need a specific person's attention in a comment, use the @ symbol (e.g., @johndoe, can you verify this database query?). They will get a direct notification.
  • Context is King: When asking for a review, don't just assign someone and say nothing. Send them a message: *"Hey @sarah, I assigned you to PR #42 because you wrote the original authentication logic. Could you verify I didn't break the token validation?"*

8. Best Practices

  • Small, Fast Reviews: If you are requested to review a PR, do it within 24 hours. Code sitting in a PR rots quickly (it becomes outdated and gets merge conflicts). A healthy engineering team prioritizes reviewing other people's code over writing their own new code. Unblocking a teammate is the highest priority.

9. Common Mistakes

  • The "LGTM" Rubber Stamp: Reviewers often just quickly skim the code, type "LGTM" (Looks Good To Me), and approve it without actually testing it. This defeats the entire purpose of code review. As a reviewer, you are co-signing the code. If it breaks production, it is just as much your fault as the author's.

10. Exercises

  1. 1. What is the operational difference between making someone an "Assignee" versus a "Reviewer" on a Pull Request?
  1. 2. When and why would you use the "Draft Pull Request" feature instead of a standard Pull Request?

11. FAQs

Q: Can I require someone to approve my code before it can be merged? A: Yes! In GitHub Repository Settings, repository admins can set up "Branch Protection Rules." You can configure the
main` branch to strictly reject any merges unless at least one Reviewer has formally clicked the green "Approve" button.

12. Summary

In Chapter 5, we explored the interpersonal dynamics of GitHub Flow. We learned that writing code is only half the job; communicating intentions and requesting feedback is equally critical. We distinguished between Assignees (the owners) and Reviewers (the auditors), ensuring clear accountability. By utilizing Draft Pull Requests, we enabled early collaboration, preventing wasted effort on incorrect architectural paths. Finally, we established the asynchronous etiquette required to keep a team moving efficiently without creating communication bottlenecks.

13. Next Chapter Recommendation

We know how to collaborate on code that is already written. But how do we decide *what* code to write in the first place? Proceed to Chapter 6: GitHub Issues and Project Boards.

Finish this Chapter

Save your progress on your learning path and prepare for coding interview challenges.

Discussion

Join the discussion

Log in or create a free account to participate.

Sort: ·