Skip to content

feat: expose attachment types#1700

Open
jpnurmi wants to merge 6 commits intomasterfrom
jpnurmi/feat/attachment-type
Open

feat: expose attachment types#1700
jpnurmi wants to merge 6 commits intomasterfrom
jpnurmi/feat/attachment-type

Conversation

@jpnurmi
Copy link
Copy Markdown
Collaborator

@jpnurmi jpnurmi commented May 5, 2026

Allow downstream SDKs to attach files and bytes with standard Sentry attachment types, such as event.view_hierarchy or event.minidump.

This is more flexible than sentry_options_add_view_hierarchy() that a) requires a file on the disk, which must be frequently updated in case of view hierarchy, and b) pushes session management to the downstream SDKs, because they don't have access to the .run directory for multi-process support and automatic cleanup.

Expose attachment type setters together with well-known type constants
so downstream SDKs can mark attachments such as view hierarchy payloads
as "event.view_hierarchy".

Co-Authored-By: OpenAI Codex <noreply@openai.com>
@github-actions
Copy link
Copy Markdown

github-actions Bot commented May 5, 2026

Messages
📖 Do not forget to update Sentry-docs with your feature once the pull request gets approved.

Generated by 🚫 dangerJS against 2755f82

Copy link
Copy Markdown

@cursor cursor Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Fix All in Cursor

❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.

Reviewed by Cursor Bugbot for commit e4abe3d. Configure here.

Comment thread src/backends/native/sentry_crash_daemon.c Outdated
@limbonaut
Copy link
Copy Markdown
Collaborator

limbonaut commented May 5, 2026

Should we deprecate sentry_options_add_view_hierarchy? It'll be just a shortcut, not a very useful one.

@jpnurmi
Copy link
Copy Markdown
Collaborator Author

jpnurmi commented May 5, 2026

Should we deprecate sentry_options_add_view_hierarchy? It'll be just a shortcut, not a very useful one.

Hmm, yeah, we probably could. Besides sentry-native and its forks and vendored copies, I can only find public references in sentry-godot and sentry-docs.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants