Tagged articles
3 articles
Page 1 of 1
Code Mala Tang
Code Mala Tang
Oct 3, 2025 · Backend Development

Hidden Costs of Throwing Exceptions and the Result Pattern Solution

This article examines the hidden performance and maintenance drawbacks of using thrown exceptions for error handling in JavaScript/TypeScript, introduces the Result pattern as a type‑safe, predictable alternative, and demonstrates its implementation, testing, and appropriate use cases with practical code examples.

Error HandlingExceptionsTypeScript
0 likes · 12 min read
Hidden Costs of Throwing Exceptions and the Result Pattern Solution
Code Mala Tang
Code Mala Tang
Mar 27, 2025 · Fundamentals

Why Returning None Is Bad and Better Ways to Handle Missing Values in Python

Returning None for missing data can cause unexpected crashes, so this article explains why that approach is problematic and demonstrates safer alternatives in Python, such as using default values with dict.get, raising exceptions when appropriate, and employing result objects to clearly indicate success or failure.

Error HandlingNone handlingPython
0 likes · 3 min read
Why Returning None Is Bad and Better Ways to Handle Missing Values in Python
Top Architect
Top Architect
Jul 17, 2024 · Backend Development

Designing a Unified API Response Structure with Annotations and Interceptors in Spring Boot

This article explains how to design a unified API response format in Spring Boot, defining a JSON result structure with code, message, and data, organizing status codes, using @ResponseResult annotation, implementing interceptors and ResponseBodyAdvice to automatically wrap controller outputs, and offers optimization tips for clean backend development.

Response wrapperSpring Bootannotations
0 likes · 10 min read
Designing a Unified API Response Structure with Annotations and Interceptors in Spring Boot