Skip to content

[storage]: Unknown Error (Message too long) while uploading image on iOS #12973

Closed
@ahmadexe

Description

@ahmadexe

Is there an existing issue for this?

  • I have searched the existing issues.

Which plugins are affected?

Storage

Which platforms are affected?

iOS

Description

[storage]: Unknown Error (Message too long) while uploading image on iOS

Description

While uploading images to firebase storage from flutter ios project the images are sometimes uploaded to the storage however sometimes the images are not uploaded and we are stuck with a message that says; "Unhandled Exception: [firebase_storage/unknown] The operation couldn’t be completed. Message too long"

Flutter doctor Output

Screenshot 2024-06-18 at 4 21 21 PM

Flutter doctor -v output

Screenshot 2024-06-18 at 4 22 07 PM

Reproducing the issue

Unable to identify the exact steps to reproduce the issue,

final refRaw = FirebaseStorage.instance.ref();
final ref = refRaw.child(name);
final uploadTask = await ref.putFile(file); // Line that produces the error
final downloadUrl = await uploadTask.ref.getDownloadURL();
return downloadUrl;

Line no. 3 sometimes fail with the error code: [firebase_storage/unknown]
and error message: The operation couldn’t be completed. Message too long

Firebase Core version

2.15.0

Flutter Version

3.19.6

Relevant Log Output

[ERROR:flutter/runtime/dart_vm_initializer.cc(41)] Unhandled Exception: [firebase_storage/unknown] The operation couldn’t be completed. Message too long

Metadata

Metadata

Assignees

No one assigned

    Labels

    Needs AttentionThis issue needs maintainer attention.blocked: customer-responseWaiting for customer response, e.g. more information was requested.platform: iosIssues / PRs which are specifically for iOS.plugin: storageresolution: userThis was a user issue, e.g. invalid configuration or code.type: bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions