CS002warningFree tier
csharp-debug-log-in-production
Debug.Log / Console.WriteLine calls left in production code
Applies to: C#
Why this matters
Debug log statements in production code clutter player logs, leak information, and in Unity they cause per-frame string allocations that stress the GC and cause frame hitches. They're fine while debugging but should be removed, wrapped in #if UNITY_EDITOR, or replaced with a structured logger before shipping.
Catch it before it ships
pip install stablestack # or: npx stablestackstablestack # scans your project, CS002 includedstablestack explain CS002False positive in your codebase? Suppress a single line with # noqa: CS002