Code Review and Working with Existing Codebases Questions

Reviewing others' code and navigating unfamiliar systems: giving and receiving actionable review feedback, spotting correctness and design issues, and reading and understanding large or legacy codebases before changing them. Covers collaborative coding norms, incremental change in shared repositories, and verifying changes against existing behavior. The team-facing side of day-to-day engineering.

EasyTechnical
61 practiced

As a systems engineer reviewing infrastructure code (Terraform, Ansible, Bash, Python), create a practical code-review checklist you would apply to pull requests. The checklist should cover correctness, clarity, maintainability, performance, security, testability, operational readiness (observability, rollback), documentation, and dependency/secret handling. For each checklist item include a 1-2 sentence rationale and a concrete example of what to look for in PR diffs or code.

HardTechnical
119 practiced

You are reviewing automation code that performs TLS certificate rotation for internal services. Identify failure modes, security checks, and test cases you would require. Propose a robust design for rotation that avoids downtime, supports emergency rollback, and ensures private key secrecy during rotation.

MediumTechnical
66 practiced

You are reviewing a large refactor that touches core library internals. Outline a plan to split the change into incremental PRs that are safe to merge independently. Include a proposed sequence, how to keep the system working at each step, feature flagging, test strategies, and rollback points.

EasyBehavioral
73 practiced

Behavioral: Tell me about a time when you found a critical bug or security issue in infrastructure code during a code review. Use the STAR format: describe the Situation, the Task you had, the Actions you took as reviewer and with the team, and the Results (including any follow-up changes to process or automation).

MediumTechnical
88 practiced

You are reviewing an Ansible playbook intended to be idempotent. Identify problems in this snippet and propose changes to make it idempotent and testable.

yaml
- hosts: web
  tasks:
    - name: install nginx
      command: apt-get install -y nginx
    - name: create conf
      copy:
        content: "server { listen 80; }"
        dest: /etc/nginx/sites-enabled/default
    - name: restart nginx
      service:
        name: nginx
        state: restarted

What would you change and why? How would you test the playbook in CI?

Unlock Full Question Bank

Get access to all 32 Code Review and Working with Existing Codebases interview questions and detailed answers.

Sign in to Continue

Join thousands of developers preparing for their dream job.