SentryConfig#
- pydantic settings safir.sentry.SentryConfig#
Values from environment variables to configure Sentry.
Most Safir apps should define at least these paramters when initializing Sentry. These are taken from enviroment variables and not part of the main app config class because we want to initialize Sentry before the app configuration is initialized.
- Parameters:
_nested_model_default_partial_update (
bool
|None
, default:None
)_env_file (
Union
[Path
,str
,Sequence
[Union
[Path
,str
]],None
], default:PosixPath('.')
)_cli_parse_args (
bool
|list
[str
] |tuple
[str
,...
] |None
, default:None
)_cli_settings_source (
Optional
[CliSettingsSource
[Any
]], default:None
)_cli_shortcuts (
Mapping
[str
,str
|list
[str
]] |None
, default:None
)_secrets_dir (
Union
[Path
,str
,Sequence
[Union
[Path
,str
]],None
], default:None
)values (
Any
)
Show JSON schema
{ "title": "SentryConfig", "description": "Values from environment variables to configure Sentry.\n\nMost Safir apps should define at least these paramters when initializing\nSentry. These are taken from enviroment variables and not part of the main\napp config class because we want to initialize Sentry before the app\nconfiguration is initialized.", "type": "object", "properties": { "SENTRY_DSN": { "description": "DSN for sending events to Sentry", "title": "Sentry Dsn", "type": "string" }, "SENTRY_ENVIRONMENT": { "description": "Phalanx name of the Rubin Science Platform environment", "title": "Sentry Environment", "type": "string" }, "SENTRY_TRACES_SAMPLE_RATE": { "default": 0, "description": "Percentage of transactions to send to Sentry, expressed as a float between 0 and 1. 0 means send no traces, 1 means send every trace.", "maximum": 1, "minimum": 0, "title": "Sentry Traces Sample Rate", "type": "number" }, "SENTRY_RELEASE": { "description": "The version of this application that is deployed.", "title": "Sentry Release", "type": "string" } }, "additionalProperties": false, "required": [ "SENTRY_DSN", "SENTRY_ENVIRONMENT", "SENTRY_RELEASE" ] }