Skip to content

Support reading SENTRY_TRACES_SAMPLE_RATE from environment #2035

@nbr

Description

@nbr

Describe the idea

Both the Python and JavaScript SDKs support setting $SENTRY_TRACES_SAMPLE_RATE in the environment, whereas the Ruby SDK does not (the currently supported environment variables seem to be listed here).

Why do you think it's beneficial to most of the users

Uniform configuration across SDKs would help make the developer experience more intuitive.

Possible implementation

Fall back to environment variable if traces_sample_rate not set in Sentry.init()

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels
    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