Repository navigation
docs(app-session): a thread send may carry files where the host advertises threadFiles - #61
Merged
Merged
Conversation
…tises threadFiles
Collaborator
Author
|
The |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Docs and one test vector only; no protocol version change. Goes with mousse-agent/mousse#2505, which lets a paired device send documents with a thread message.
What changed
spec/app-session.md, Admissions and attachments: a host that takes files on a thread send advertisesthreadFilesinnet.info({v:1,maxFiles,maxBytes,extensions}) androuted["orchestrator.send"]11 or later (queue.enqueue4). The send carriesfiles:[{name,data}](base64), inline or staged as a third staged keyfiles. The host checks each file's extension and first bytes and refuses the whole message withfile_unsupportedorfile_too_large. WithoutthreadFiles, a caller sends images only; an older host refusesfileswithbad_request.routed.thread.attachedFilereads such a file back in 40 KiB pages, shaped likebots.chat.file.spec/vectors/app-session/session.json: new casethread send carries files. The existing case that refusesattachmentsstill holds.Compatibility
Older phones never send
files, so nothing changes for them. A phone that checksthreadFilesbefore sending files never sends them to an older desktop.Checks
tests/netEngine/appSessionVectors.test.tsin mousse-agent/mousse, with this file vendored) passes all cases, the new one included.