Files
c020627 1b7576d5d4 fix(linkai): cap the file download in the LinkAI sender
_download_file did a bare requests.get and wrote resp.content, so the
whole body was buffered before anything could object -- a socket
timeout alone never fires on a server that keeps trickling bytes, and
the vendor decides the size of the file it signs a link for.

Route it through common.media_download, the helper the LinkAI voice
download in voice/linkai already uses: the body is streamed, counted
chunk by chunk and cut off at the shared cap, and a refused download
leaves no partial file behind.
2026-10-24 16:15:06 +08:00
..