deno
04af43db - fix(ext/console): make timer and counter state per-instance to fix OTEL console wrapping

Commit
40 days ago
fix(ext/console): make timer and counter state per-instance to fix OTEL console wrapping When OTEL is enabled, `wrapConsole` calls both the OTEL Console and the original Console methods sequentially. Since `timerMap` and `countMap` were module-level singletons shared across all Console instances, the OTEL Console would modify timer/counter state before the original Console ran, causing spurious "Timer already exists" and "Timer does not exist" warnings. Move `timerMap` and `countMap` to private instance fields so each Console instance maintains independent state. Fixes #28818 Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Author
Parents
Loading