get_event_attachment inlines files up to 30 MiB, which can drop the transport
Les mainteneurs répondent en général sous 1 jour
Personne n'a encore pris cette issue.
Évaluation
- Difficulté
- 4/5
- Temps estimé
- 3-5 jours
- Accessibilité débutants
- 48/100
- Type d'issue
- Bug
- Clarté
- Plutôt claire
- Activité
- Active
- Stack technique
- typescript
- Domaine
- backend-api-design
Piste de recherche
Start with packages/mcp-core/src/api-client/client.ts around the inline attachment size cap and download handling, then read tools/catalog/get-event-attachment.ts for the tool schema and response. Check how the tool can return a link without buffering a large file and how its tests cover inline and oversized attachments. Done means callers can get a usable result for large attachments without the transport closing; the reported client limit and memory impact are still unverified.
Rédigé par le modèle d'indexation à partir du texte de l'issue.
Description
Pattern: get_event_attachment returns any attachment up to 30 MiB inline as a base64 blob in one JSON-RPC result, and a caller has no way to ask for a link instead. For a ~22 MiB file the client's transport closed before it got a usable result.
Reports: 1 (MCP user feedback MCP-SERVER-GW8, get_event_attachment, server 0.42.0, Codex over HTTP, kind=broken, impact=blocked). Customer identifiers are left out on purpose; the internal feedback log has them.
What happened: listing an event's attachments worked. Downloading a 23,439,996-byte .tar.gz closed the transport before the client got either the embedded resource or a download link. Sampled server spans for those calls are all ok: the attachment list GET and the ?download=1 GET returned 200 and the tools/call span finished in ~1.2 s, so the handler completed and the failure came after the result left it.
Cause (code verified, transport side inferred):
- The inline cap is
DEFAULT_MAX_INLINE_ATTACHMENT_BYTES = 30 * 1024 * 1024, sized for the Worker's 128 MB isolate, not for what MCP clients accept (packages/mcp-core/src/api-client/client.ts:372-378@0c6b028). - Only attachments over that cap skip the download and return a presigned link (
client.ts:4160-4171,tools/catalog/get-event-attachment.ts:124-134). A 22.4 MiB file falls under it, so the bytes are buffered (client.ts:4192) and returned as a ~31 MB base64EmbeddedResource(get-event-attachment.ts:147-166). - The input schema has only
attachmentIdto pick a file; nothing requests metadata or a link only (get-event-attachment.ts:91-101). - Sentry already answers
?download=1for objectstore attachments with a redirect to a presigned URL (getsentry/sentrysrc/sentry/api/endpoints/event_attachment_details.py:124@0d74e59b939), which the oversized path uses viaresolveDirectDownloadUrl.
Not checked: the client-side error and the client's maximum message size, so it's inferred, not confirmed, that the result size closed the transport. I also didn't check whether the Worker came close to its memory limit while serializing the result. Related but different: the "hosted MCP connection dropped mid-call" reports were transient and worked on retry; this one is size-dependent.
via automation evt_905b9c478746fd9deeb853f85ad7441b · Run ID dispatch_18245721458ab109a53742963df57e13.
--
- Langage dominant
- TypeScript
- Étoiles
- 975
- Forks
- 189
- Merge moyen
- 19 h 57 min
- PR mergées (30 j)
- 542
Préparer son environnement
Ce projet ne fournit ni conteneur de développement, ni Dockerfile, ni guide de contribution : l'installation est à votre charge. Commencez par son README, et consultez notre guide de la première contribution pour les étapes générales.
Par où commencer
- Lisez l'issue en entier, puis le guide de contribution du projet.
- Signalez en commentaire que vous la prenez — cela évite que deux personnes fassent le même travail.
- Forkez le dépôt et travaillez sur une branche.
- Ouvrez une pull request qui référence le numéro de l'issue.
Autres issues de getsentry/toolkit
-
Difficulté 2/5 1-3 heures Accessibilité débutants 72/100
getsentry/toolkit#2583 · 1 commentaire ·
Les mainteneurs répondent en général sous 1 jour
-
Difficulté 2/5 1-3 heures Accessibilité débutants 77/100
getsentry/toolkit#2531 · 1 commentaire ·
Les mainteneurs répondent en général sous 1 jour
-
mcp-feedback-pattern
Difficulté 2/5 1-3 heures Accessibilité débutants 74/100
getsentry/toolkit#2458 · 2 commentaires ·
Les mainteneurs répondent en général sous 1 jour
-
Difficulté 2/5 1-3 heures Accessibilité débutants 75/100
getsentry/toolkit#2444 · 1 commentaire ·
Les mainteneurs répondent en général sous 1 jour
-
mcp-feedback-pattern
Difficulté 2/5 1-3 heures Accessibilité débutants 67/100
getsentry/toolkit#2362 · 1 commentaire ·
Les mainteneurs répondent en général sous 1 jour
Toutes les issues de getsentry/toolkit
Issues similaires
-
sumHorizontal, maxHorizontal, minHorizontal, allHorizontal, anyHorizontal, struct and argSortBy treat strings as literals instead of column namesPeut-être pris @tomaionescu l’a pris aujourd’hui. Ouverte
Difficulté 2/5 1-3 heures Accessibilité débutants 78/100
pola-rs/nodejs-polars#486 ·
Les mainteneurs répondent en général sous 1 jour
-
Difficulté 2/5 1-3 heures Accessibilité débutants 62/100
jaegertracing/jaeger-ui#4853 ·
Les mainteneurs répondent en général sous 1 jour
-
area/plugins platform/linux reproduced type/bug version/v2
Difficulté 2/5 1-3 heures Accessibilité débutants 72/100
anomalyco/opencode#66970 · 3 commentaires ·
Les mainteneurs répondent en général sous 1 jour
-
area:tui enhancement platform:macos
Difficulté 2/5 1-3 heures Accessibilité débutants 68/100
anthropics/claude-code#112838 ·
-
Add: Sports First TV (US)Ouverteapproved check:passed streams:add
Difficulté 2/5 1-3 heures Accessibilité débutants 66/100
Les mainteneurs répondent en général sous 1 jour