Skip to content

consoleLoggingIntegration should be opt-in per logs spec v2.0.0 #5985

@antonis

Description

@antonis

Summary

The logs spec v2.0.0 introduces a requirement that auto-emitting log integrations MUST be opt-in:

Integrations that auto-emit logs MUST be opt-in. The integration MUST NOT emit any logs unless the user explicitly enables it.

Currently, consoleLoggingIntegration is automatically added to default integrations when enableLogs is truthy (packages/core/src/js/integrations/default.ts). Once the spec change to default enableLogs to true lands upstream, this would silently start capturing all console.* calls as Sentry logs for every user — causing unexpected volume and cost.

Required Changes

  • Remove consoleLoggingIntegration from default integrations — users should explicitly add it
  • Align enableLogs default with spec v2.0.0 (true) once @sentry/core updates

logEnricherIntegration can stay as a default since it only enriches existing logs, not auto-emit new ones.

References

Metadata

Metadata

Assignees

No one assigned
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions