When Context Betrays You: Deriving Contexts for Optional Operations in Go

In Go, context.Context is the standard mechanism for propagating cancellation, deadlines , and values across Goroutines and function calls. The general rule is simple: always pass the context forward. But this rule has a subtle trap that can cause bugs that are hard to reproduce, especially when you have optional operations with fallback.