Skip to content

File uploads fail on iOS/iPadOS 26.5.2 with Unexpected end of form #139

Description

@fabienhummel

Summary

File uploads fail consistently in DumbAssets on iOS 26.5.2 and iPadOS 26.5.2.

The asset data itself is saved successfully, but images, receipts, and other attached files are not uploaded.

The user interface displays the following error:

File upload failed
Error parsing response: The string did not match the expected pattern.

The DumbAssets container logs show that the multipart request reaches the application but ends unexpectedly:

API Request: POST /upload/image
Error: Unexpected end of form
    at Multipart._final (/app/node_modules/busboy/lib/types/multipart.js:588:17)
    at prefinish (node:internal/streams/writable:916:14)
    at finishMaybe (node:internal/streams/writable:930:5)
    at Writable.end (node:internal/streams/writable:845:5)
    at IncomingMessage.onend (node:internal/streams/readable:948:10)

The same error also occurs when uploading a receipt:

API Request: POST /upload/receipt
Error: Unexpected end of form
    at Multipart._final (/app/node_modules/busboy/lib/types/multipart.js:588:17)

Environment

  • DumbAssets Docker image: dumbwareio/dumbassets:latest
  • Docker host: Synology NAS
  • DumbAssets internal port: 3000
  • Reverse proxy: Traefik
  • Authentication middleware: TinyAuth
  • Security middleware: CrowdSec
  • Persistent volume mounted on /app/data
  • HTTPS is terminated before the request reaches DumbAssets

The request reaches the DumbAssets container correctly.

Traefik reports:

RequestMethod: POST
RequestPath: /api/upload/image
RouterName: dumbassets@docker
ServiceName: dumbassets@docker
OriginStatus: 500
DownstreamStatus: 500

The HTTP 500 response therefore originates from DumbAssets, not from Traefik, TinyAuth, CrowdSec, or the HTTPS reverse proxy.

Steps to reproduce

  1. Open DumbAssets on an iPhone or iPad running version 26.5.2.
  2. Create a new asset or edit an existing asset.
  3. Select an image or document.
  4. Save the asset.
  5. Try the same operation using the receipt field.

Actual result

The asset information is saved, but the attached file is not uploaded.

The browser displays:

File upload failed
Error parsing response: The string did not match the expected pattern.

The server returns HTTP 500 and Busboy reports:

Unexpected end of form

Expected result

The selected image, receipt, or document should be uploaded and attached to the asset.

Test matrix

Platform Browser Result
Android Chrome Works
macOS 26.5.2 Desktop browser Works
iPadOS 26.5 Safari Worked before updating the same iPad
iPadOS 26.5.2 Safari Fails
iOS 26.5.2 Safari Fails
iOS 26.5.2 Brave Fails
iOS 26.5.2 Chrome Fails
iOS 26.5.2 Firefox Fails

Files and sources tested

The problem is not limited to HEIC files or the Photos library.

The following cases were tested on iOS/iPadOS 26.5.2:

  • HEIC image selected from Photos: fails
  • JPEG image selected from Photos: fails
  • JPEG image selected from the Files app: fails
  • Receipt/document selected from the Files app: fails
  • Upload through the image field: fails
  • Upload through the receipt field: fails

Important regression test

The same iPad successfully uploaded files while running iPadOS 26.5.

Immediately after updating that same iPad to iPadOS 26.5.2, uploads started failing with the same Unexpected end of form error already observed on the iPhone.

No changes were made to:

  • DumbAssets
  • Docker
  • Traefik
  • TinyAuth
  • CrowdSec
  • Storage volumes
  • File permissions
  • Network configuration

The same DumbAssets instance still accepts uploads from Android and macOS 26.5.2.

Additional observations

All tested browsers on iOS fail in the same way, which suggests that the problem is related to the system web stack used by iOS/iPadOS rather than to a specific browser.

The multipart request appears to arrive truncated. Busboy does not receive the final multipart boundary and throws Unexpected end of form.

The frontend file-upload implementation using File, FormData, FileList, or DataTransfer may be worth investigating.

A possible workaround on the DumbAssets side could be to append the original selected File objects directly to FormData, without reconstructing the file input through DataTransfer.

Workaround

Uploads currently work from:

  • Android
  • macOS
  • Other desktop browsers

Uploads currently fail from:

  • iOS 26.5.2
  • iPadOS 26.5.2
Image

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions