Editing Matrix image captions breaks when bridging #55

Open
opened 2025-03-06 00:13:23 +00:00 by cadence · 0 comments
Owner

image

This probably happens because the URL is not preserved correctly.

Either we need to assume images themselves can NOT be edited, and not pass the attachments array to Discord at all. Or, we need to assume images themselves CAN be edited, and make a proper attachments array to pass to Discord, instead of the current broken state where seemingly we are passing attachments without pendingFiles.

Probably need to check this one in the debugger and see which code paths it's taking to generate attachments and pendingFiles.

Use gomuks web to reproduce.

DiscordAPIError: {"message": "Invalid Form Body", "code": 50035, "errors": {"attachments": {"0": {"_errors": [{"code": "ATTACHMENT_NOT_FOUND", "message": "Attachment data not found"}]}}}}
    at fn (/home/rocky/out-of-your-element/node_modules/snowtransfer/src/RequestHandler.ts:445:13)
    at process.processTicksAndRejections (node:internal/process/task_queues:105:5)
    at async wrapped (/home/rocky/out-of-your-element/node_modules/snowtransfer/src/RequestHandler.ts:115:14)
    at async exports.AsyncSequentialQueue._next (/home/rocky/out-of-your-element/node_modules/snowtransfer/src/RequestHandler.ts:145:3)
![image](/attachments/fcbbe323-af85-4b84-98f2-5bb684be5b42) This probably happens because the URL is not preserved correctly. Either we need to assume images themselves can NOT be edited, and not pass the attachments array to Discord at _all._ Or, we need to assume images themselves CAN be edited, and make a proper attachments array to pass to Discord, instead of the current broken state where seemingly we are passing attachments without pendingFiles. Probably need to check this one in the debugger and see which code paths it's taking to generate attachments and pendingFiles. Use gomuks web to reproduce. ``` DiscordAPIError: {"message": "Invalid Form Body", "code": 50035, "errors": {"attachments": {"0": {"_errors": [{"code": "ATTACHMENT_NOT_FOUND", "message": "Attachment data not found"}]}}}} at fn (/home/rocky/out-of-your-element/node_modules/snowtransfer/src/RequestHandler.ts:445:13) at process.processTicksAndRejections (node:internal/process/task_queues:105:5) at async wrapped (/home/rocky/out-of-your-element/node_modules/snowtransfer/src/RequestHandler.ts:115:14) at async exports.AsyncSequentialQueue._next (/home/rocky/out-of-your-element/node_modules/snowtransfer/src/RequestHandler.ts:145:3)
106 KiB
Sign in to join this conversation.
No labels
blocking
web
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: cadence/out-of-your-element#55
No description provided.