You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[Bug]: Android: any file shared into T3 Code from another app is blocked with "Too much context" (same file via + works) #38607
I searched existing issues and did not find a duplicate.
I included enough detail to reproduce or investigate the problem.
Area
apps/mobile
Steps to reproduce
On Android, save any small file to the phone. A 238-byte .json file is enough.
Open the system Files app (Samsung My Files), long-press the file, tap Share, and choose T3 Code.
T3 Code opens a New thread draft with the file chip attached.
Type any text, for example test, and tap Send.
Expected behavior
The message sends with the shared file attached, the same as when the file is attached with the composer's + button.
Actual behavior
Send is blocked with the dialog "Too much context — This draft has too much context to send. Remove some context items and try again." (composerContextSendBlockReason in apps/mobile/src/lib/composerContext.ts, raised from NewTaskDraftScreen.tsx).
The file size makes no difference:
What was attached
How
Result
238-byte .json
Shared from My Files into T3 Code
Blocked: "Too much context"
86 KB .json
Shared from another app (ACTION_SEND_MULTIPLE, two files)
Blocked: "Too much context"
~1.1 MB .json
Shared from another app
Blocked: "Too much context"
The same 238-byte .json
Attached with the composer + button
Sends normally
So file attachments work, and the problem is specific to files that arrive through the Android share sheet (the incoming-share import path: incoming-share-model.ts → mergeComposerDraftContentState → restoreMissingComposerFileReferences → attachmentContextRecord).
The dialog's wording points at size, but the check can't be about size here. composerContextSendBlockReason shows that message whenever Schema.is(OrchestrationMessageContext) or the decode fails, and the only size cap is COMPOSER_CONTEXT_MAX_SERIALIZED_CHARS = 16_000_000. I ran the main contracts with effect@4.1.3 against the record I'd expect the share import to build:
Both the decode and Schema.is accept it, so the draft context the share import really produces must differ from this shape in some way I couldn't see from the source. It may be a stale or unreferenced record left in the persisted New thread draft, or a field the native share parser fills differently.
Two smaller suggestions:
The block message could say which record failed, or at least that it's invalid rather than too large. "Too much context" sent me chasing file size for a while.
A draft that's blocked this way gives no way to find or clear the hidden bad record.
Impact
Major degradation or frequent failure
Version or commit
Server v0.1.7 (Linux). Android app version not captured; the bug still happens as of 2026-11-18.
Environment
Android (Samsung, One UI), sharing from Samsung My Files and from a third-party app through the standard Android share sheet. Server on Fedora-based Linux.
Workaround
Save the file to the phone, then attach it from the composer with + instead of using Share.
Activity
vinicius741 commentedon Nov 18, 2026
Android app version: 2.3.0 (Settings › About). Server v0.1.7 on Linux.
feat(diagnostics): save a copy of the diagnostics logs to Downloads
juliusmarminge commentedon Nov 18, 2026
This is the same problem as #28535, so I'm closing it in favour of that one. If it is different, say how and it will be reopened.