Platforms: iOS and Android (native apps)
Version reproduced: 9.4.51.1
Problem
An image posted in a chat renders as broken immediately after sending, even though the upload to the server succeeds. Reopening/refreshing the chat renders it correctly, because the file is safely in S3 — the broken state is purely a local cache miss.
Root cause
After a successful upload, the app copies the just-uploaded file from its temp Receipts-Upload/ folder into the local attachment cache. The temp source file is cleaned up before the cache-copy step runs, so the copy fails and the image renders broken. This is a race condition between temp-file cleanup and the cache-copy step.
On iOS the failure surfaces as:
[AttachmentCache] Failed to cache attachment
error: code 'ENSCOCOAERRORDOMAIN4' (NSCocoaErrorDomain 4 = file not found)
copy .../Receipts-Upload/<uuid>.jpg → .../attachments/<id>.jpg
underlying: code 2 (ENOENT)
Expected
The image should render immediately after sending, without needing a chat refresh.
Actual
The image renders broken until the chat is reopened/refreshed.
Scope (production logs, 2026-08-12)
- 747 occurrences today across 404 unique users, steady throughout the day (no spike) — pre-existing, widespread iOS/Android issue, not a today-only regression.
- Example failures (iOS 9.4.51.1): request
a29c525a0c270999-SJC (03:16:30Z) and a29c53021d2a0999-SJC (03:16:57Z).
Related issues
Reported by @mallenexpensify via DM with MelvinBot.
Platforms: iOS and Android (native apps)
Version reproduced: 9.4.51.1
Problem
An image posted in a chat renders as broken immediately after sending, even though the upload to the server succeeds. Reopening/refreshing the chat renders it correctly, because the file is safely in S3 — the broken state is purely a local cache miss.
Root cause
After a successful upload, the app copies the just-uploaded file from its temp
Receipts-Upload/folder into the local attachment cache. The temp source file is cleaned up before the cache-copy step runs, so the copy fails and the image renders broken. This is a race condition between temp-file cleanup and the cache-copy step.On iOS the failure surfaces as:
Expected
The image should render immediately after sending, without needing a chat refresh.
Actual
The image renders broken until the chat is reopened/refreshed.
Scope (production logs, 2026-08-12)
a29c525a0c270999-SJC(03:16:30Z) anda29c53021d2a0999-SJC(03:16:57Z).Related issues
Reported by @mallenexpensify via DM with MelvinBot.