-
-
Notifications
You must be signed in to change notification settings - Fork 372
Closed
Description
Note
The pull request "fix: Multiple attachments support for feedback" was created by @tustanivsky but did not reference an issue. Therefore this issue was created for better visibility in external tools like Linear.
📜 Description
Updated SentryFeedback to accept [Attachment] objects instead of raw [Data] arrays, enabling proper support for
multiple attachments with full metadata (filename, content type, etc.).
This also introduces some breaking changes to public API:
initmethod signaturedataDictionary()method now returns attachments as[[String: Any]]with metadata instead of[Data]affecting consumers of theonSubmitSuccesscallback
This issue originally came up in Unreal SDK while adding attachment support for user feedback:
💡 Motivation and Context
The previous implementation had several limitations:
- Hardcoded metadata:
attachmentsForEnvelope()assumed all attachments were screenshots and hardcoded filename: "screenshot.png" and contentType: "application/png" - Single attachment limitation: Only the first attachment was processed despite accepting an array
- Lost metadata: Converting Attachment → Data → Attachment discarded important information like custom filenames and content types
- Backend supports multiple: The Sentry backend can successfully process and display multiple feedback attachments, but the SDK wasn't taking advantage of this
💚 How did you test it?
- Added/updated tests
- Manually using Unreal SDK sample project.
📝 Checklist
You have to check all boxes before merging:
- I added tests to verify the changes.
- No new PII added or SDK only sends newly added PII if
sendDefaultPIIis enabled. - I updated the docs if needed.
- I updated the wizard if needed.
- Review from the native team if needed.
- No breaking change or entry added to the changelog.
- No breaking change for hybrid SDKs or communicated to hybrid SDKs.
Metadata
Metadata
Assignees
Labels
No labels