Interview conceptSoftware Engineering Fundamentals

Local Project Feature Implementation

Asked of: Software Engineer

Last updated

What's being tested

Local feature implementation tests whether you can turn an ambiguous requirement into a safe, maintainable change inside an unfamiliar codebase. The interviewer is probing repository navigation, API and data-flow reasoning, incremental implementation, testing discipline, and your ability to preserve existing behavior. Upstart cares because production engineers routinely modify systems they did not originally design, where correctness includes compatibility, observability, and rollback safety—not merely making one happy-path test pass.

Core knowledge

  • Repository reconnaissance means locating the application entry point, dependency manifest, configuration, routing, persistence, and test commands before editing. Read README, inspect recent history with git log, and trace one existing feature end to end.

  • Establish a contract before coding: inputs, outputs, validation rules, error semantics, authorization expectations, side effects, and compatibility requirements. If requirements are ambiguous, state an assumption and implement the narrowest behavior consistent with existing conventions.

  • Follow the project’s architecture boundaries. Keep HTTP parsing in handlers, business rules in services, persistence in repositories or models, and serialization at the edge; avoid placing database calls, validation, and policy logic in one controller.

  • Prefer small, reversible changes: add one vertical slice, run focused tests, inspect the diff, then expand. Avoid unrelated refactors because they enlarge review surface and make regressions harder to localize.

  • Use existing abstractions and conventions before introducing new ones. Match established naming, dependency injection, error types, logging fields, transaction boundaries, and response formats unless the feature clearly requires a deliberate deviation.

  • Design input validation at trust boundaries. Distinguish malformed input (400), unauthenticated access (401), unauthorized access (403), missing resources (404), conflicts (409), and unexpected failures (500) according to the project’s conventions.

  • Preserve invariants explicitly: uniqueness, referential integrity, state-transition legality, and idempotency. For a retried write, an idempotency key or unique constraint may prevent duplicate effects; application checks alone are vulnerable to races.

  • Treat concurrency as part of correctness. A read-modify-write sequence can lose updates; use an atomic database update, optimistic version check, or transaction with an appropriate isolation level rather than relying on timing.

  • Build tests at multiple levels: unit tests for deterministic business rules, integration tests for database or framework wiring, and endpoint tests for the externally visible contract. Cover success, invalid input, missing data, authorization, duplicate requests, and dependency failure.

  • Use observability to make behavior diagnosable: structured logs with request or entity identifiers, useful error context without sensitive data, and metrics such as request count, error rate, and latency. Never log secrets, credentials, or unnecessary personal information.

  • Verify changes with a feedback loop: formatter, linter, type checker, focused tests, full suite, and a manual smoke test where appropriate. Investigate failures rather than weakening assertions or deleting tests that expose a real contract violation.

  • Think about backward compatibility for schemas and APIs. Additive changes are generally safer than renaming or deleting fields; if a migration is needed, consider expand-and-contract deployment so old and new application versions can coexist.

Worked example

Because no titled interview prompt was supplied, use the representative exercise “Add a feature to an existing local project” as the practice frame. In the first 30 seconds, a strong candidate would ask where the feature is exposed, what the exact input/output contract is, whether existing clients must remain compatible, and which persistence or authorization rules apply. They would declare assumptions such as preserving current response conventions, rejecting invalid input at the boundary, and making repeated requests safe where the operation has side effects. The answer would be organized around repository reconnaissance, contract and validation, business-layer implementation, persistence/concurrency behavior, and tests plus verification. They would trace a similar existing feature first instead of inventing a new architecture. One explicit tradeoff would be whether to add a new service abstraction or reuse an existing one: reuse is faster and more consistent, while a new boundary may be justified if the business rule is independently complex or likely to evolve. They would call out transaction scope and duplicate-request behavior rather than treating the happy path as sufficient. They would close by saying, “If I had more time, I’d add failure-path integration tests, inspect logs and latency locally, and review migration and rollback behavior.”

A second angle

A different representative variation is “Modify an existing feature without breaking current callers.” The framing shifts from building a vertical slice to preserving an established contract while introducing compatibility behavior. The candidate should inspect call sites and tests, prefer additive fields or endpoints, and identify whether old and new versions can run simultaneously during deployment. A useful explicit decision is whether to branch behavior by API version or use a backward-compatible default; the choice depends on client control and the permanence of the contract. The same implementation discipline applies, but regression detection and rollout safety become the dominant concerns.

Common pitfalls

Pitfall: Treating “the test passes” as proof of correctness. A candidate may implement only the visible happy path while ignoring malformed input, duplicate requests, authorization, persistence failure, or concurrent updates; enumerate those cases and test the externally observable contract.

Pitfall: Coding immediately without learning the repository. Introducing a new pattern, response shape, or dependency before inspecting neighboring code signals poor integration judgment; first identify the project’s established route, service, model, and test conventions.

Pitfall: Discussing architecture at a vague level without tracing control flow. Saying “I would add an API and database table” is weaker than naming the files or layers touched, transaction boundary, error mapping, test seams, and commands used to validate the change.

Connections

An interviewer may pivot to API design, database transactions, dependency injection, test doubles, observability, or backward-compatible migrations. Be prepared to explain how the feature behaves under retries, partial failure, concurrent requests, and incremental deployment.

Further reading

  • Working Effectively with Legacy Code — Michael Feathers’ practical techniques for safely changing unfamiliar codebases.

  • Release It! — production failure modes, stability patterns, and operational thinking for feature changes.

  • Refactoring — Martin Fowler’s catalog of behavior-preserving code improvements.

Related concepts