Skip to content

Program 02 · Module 05 of 9

Module 05: Implementing Changes in an Existing Codebase

Add a feature or fix to a system with conventions you did not choose. You plan a small change, follow existing patterns, keep the diff reviewable and use an assistant under supervision.

Suggested study time
6–7 hours
Prerequisites
Modules 1 to 4.; A change request or issue to work on.

Sign in to track your progress. Every lesson stays free to read without an account.

Learning outcomes

By the end of this module you will be able to:

  • Plan a change as the smallest set of edits that satisfies its acceptance criteria.
  • Follow existing conventions and note where you deliberately depart.
  • Direct an assistant with a bounded task and review its diff line by line.
  • Prepare a pull request that a reviewer can assess quickly.

Lessons

  1. 5.1

    Planning a Small Change

    Turn a request into acceptance criteria and the smallest set of edits that meets them.

    40 min
  2. 5.2

    Following Existing Conventions

    Recognise a codebase's patterns and extend them rather than introducing new ones.

    35 min
  3. 5.3

    Directing an Assistant on a Bounded Task

    Give an assistant a narrow task and constraints, and review what it returns.

    45 min
  4. 5.4

    Feature Flags and Staged Rollout

    Ship behind a switch so that a change can be enabled gradually and withdrawn quickly.

    40 min
  5. 5.5

    Writing a Reviewable Pull Request

    Describe a change so that a reviewer can assess its risk quickly.

    35 min

About 3 h 15 min of lessons in total.

Practical assignment

Implement a minimum order value rule

Implement a real or invented change request in your repository, such as a validation rule. Keep the diff small, test it, and write the pull request description.

Deliverables

  • Acceptance criteria written before coding.
  • The change, with tests for each criterion.
  • A pull request description with scope, risk, test evidence and rollback.
  • A note on which assistant output you changed or rejected and why.

Validation checklist

Use this to check your assignment before you move on.

Knowledge check

  1. 1.While making a change you notice messy code nearby. What is the best course?
    Show the answer and explanation

    Answer: B. Unrelated edits enlarge the diff and mask the risk of the real change. Cleaning up in the same commit is a common habit but makes review harder.

  2. 2.Why review an assistant's diff line by line?
    Show the answer and explanation

    Answer: B. The risk is unrequested or incomplete changes, not constant error. A reviewer's rule is a reason to comply, not the reason it matters.

PromptFable is independent and is not affiliated with, endorsed by or sponsored by Anthropic, Google, OpenAI or any other vendor. Claude, Gemini, Google AI Studio and other product names are trademarks of their respective owners.