Conversation
PR SummaryIntroduces telemetry across forc CLI tools and updates tracing initialization.
Written by Cursor Bugbot for commit 9a50d32. This will update automatically on new commits. Configure here. |
| # - Create "forc-tracing-0.71.x" git tag. | ||
| version = "0.71.1" | ||
| # - Create "forc-tracing-0.72.x" git tag. | ||
| version = "0.72.0" |
There was a problem hiding this comment.
might as well update the changelog for forc-tracing at the same time
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
Bugbot Autofix is OFF. To automatically fix reported issues with Cloud Agents, enable Autofix in the Cursor dashboard.
| debug_telemetry, error_telemetry, info_telemetry, span_telemetry, trace_telemetry, | ||
| warn_telemetry, | ||
| }; | ||
| } |
There was a problem hiding this comment.
Telemetry stub macros are dead code due to conflicting cfg guards
Medium Severity
The telemetry module is declared with #[cfg(feature = "telemetry")] in lib.rs, meaning telemetry.rs is only loaded when telemetry is enabled. However, the stub macros inside telemetry.rs are gated with #[cfg(not(feature = "telemetry"))]. These conditions are mutually exclusive, so the disabled_telemetry module and its stub macros can never be compiled. When users disable telemetry and attempt to use these macros, they'll get a confusing "module not found" error instead of the intended clear error message about enabling the telemetry feature.
Re-enabling tracing, it was problematic in the past because of how we integrated this. Little bit more details:
The
WorkerGuardfrom fuel-telemetry was stored in a staticOnceLockinforc-tracing, preventing its Drop implementation from running. This caused, zombie processes remaining after CLI tool executionRefactored
init_tracing_subscriber()to return the WorkerGuard to the caller, enabling proper RAII cleanup when programs exit.