Simple-SMS-Messenger icon indicating copy to clipboard operation
Simple-SMS-Messenger copied to clipboard

[Unknown] Sending a < 1 MB PNG Results in Error Code 5

Open OdinVex opened this issue 3 years ago • 22 comments

I attempted to send a message of 255-characters with a PNG of 990.9 kB in size, it failed with 'error code 5'. My provider allows 8 MB attachments. Settings have set the 'resize' to unlimited and, even 2 MB, still fails. Is it because it is a PNG and not some crap-quality JPEG?

OdinVex avatar Jan 17 '23 21:01 OdinVex

what app and OS version are you using?

tibbi avatar Jan 17 '23 22:01 tibbi

what app and OS version are you using?

Simple SMS Messenger: 5.17.2 Android OS: 11, older phone.

OdinVex avatar Jan 17 '23 22:01 OdinVex

For the past couple weeks, I have been getting the same Error 5 message anytime I try to send a photo, no matter the size of the photo. Simple SMS Version 5.17.2 Android 12

Muuhdist avatar Jan 25 '23 22:01 Muuhdist

Same here, it fails a lot for image captured from my phone. But screenshots with small sizes are sent fine.

Atreyagaurav avatar Feb 03 '23 03:02 Atreyagaurav

Hey, y'all.

The error is related to the max MMS limit and images captured by phones nowadays are often large. Here is a test APK with improved image compression: https://github.com/Naveen3Singh/Simple-SMS-Messenger/releases/download/compression_test/sms-messenger-core-debug.apk

Let me know if this works for any of you, thanks!

naveensingh avatar Feb 16 '23 14:02 naveensingh

Hey, y'all.

The error is related to the max MMS limit and images captured by phones nowadays are often large. Here is a test APK with improved image compression: https://github.com/Naveen3Singh/Simple-SMS-Messenger/releases/download/compression_test/sms-messenger-core-debug.apk

Let me know if this works for any of you, thanks!

I can't even send a 1K favicon png.

Edit: 113 bytes, 16x16. I can send 8 MB PNGs with stock Messages and the file checksum matches the original file, so it's SMS Messenger that isn't working correctly. I'd debug it myself, but I despise Android development.

OdinVex avatar Feb 16 '23 19:02 OdinVex

Are you able to send any other media like audio or document?

naveensingh avatar Feb 16 '23 19:02 naveensingh

Are you able to send any other media like audio or document?

4.8 MB Video: No Error 5


250 KB SVG: No "Unknown Error" (This is an XML file containing instructions to draw an image, it isn't binary, it's Text.) 500 KB JPEG: Yes


15 KB Text File: Yes 1 MB Text File: No

Conclusion: Compression is not the answer, something else is wrong.

Messages sends them all, checksums match, too. Even an 8 MB test binary file (dd if=/dev/random of=./Test.txt bs=1M count=8) is sent via Messages.

OdinVex avatar Feb 16 '23 19:02 OdinVex

This new apk works better for me.  Thank you!Sent from my Verizon, Samsung Galaxy smartphone -------- Original message --------From: Naveen Singh @.> Date: 2/16/23 9:25 AM (GMT-05:00) To: SimpleMobileTools/Simple-SMS-Messenger @.> Cc: JB @.>, Comment @.> Subject: Re: [SimpleMobileTools/Simple-SMS-Messenger] [Unknown] Sending a < 1 MB PNG Results in Error Code 5 (Issue #571) Hey, y'all. The error is related to the max MMS limit and images captured by phones nowadays are often large. Here is a test APK with improved image compression: https://github.com/Naveen3Singh/Simple-SMS-Messenger/releases/download/compression_test/sms-messenger-core-debug.apk Let me know if this works for any of you, thanks!

—Reply to this email directly, view it on GitHub, or unsubscribe.You are receiving this because you commented.Message ID: @.***>

Muuhdist avatar Feb 16 '23 19:02 Muuhdist

@OdinVex

250 KB SVG: No "Unknown Error" (This is an XML file containing instructions to draw an image, it isn't binary, it's Text.)

the logic requires attachment previews to load properly else they are discarded. Support for loading SVGs is not yet added (probably an oversight) hence the failure. Thanks for bringing it into the spotlight.

500 KB JPEG: Yes

but large JPEGs (>1MB) fail?

Messages sends them all

It could be the RCS feature (unlikely because you, as a power user, would have noticed). It's more likely that the code that generates MMS Pdu is old and needs to be improved/updated.

Do older versions work for you? (they shouldn't because the error 5 you see still happened but wasn't visible to users before)

Edit: Error 5 is an IO error.

naveensingh avatar Feb 16 '23 20:02 naveensingh

the logic requires attachment previews to load properly else they are discarded. Support for loading SVGs is not yet added (probably an oversight) hence the failure. Thanks for bringing it into the spotlight.

It should be assumed to treat all files as binary unless otherwise selectively modified.

but large JPEGs (>1MB) fail?

Untested, I just know my service provider has confirmed 8 MB sizes as perfectly fine.

It could be the RCS feature (unlikely because you, as a power user, would have noticed). It's more likely that the code that generates MMS Pdu is old and needs to be improved/updated.

My provider doesn't support RCS (Mint Mobile, a VMNO operating on T-Mobile backend).

Do older versions work for you? (they shouldn't because the error 5 you see still happened but wasn't visible to users before)

Edit: Error 5 is an IO error.

I don't have any old APKs to test with, at the moment. What version first had it? If you happen to know, I'll try a version before it.

OdinVex avatar Feb 16 '23 20:02 OdinVex

What version first had it?

The changes were introduced in 5.17.2

You can try 5.17.1 or 5.17.0, thanks

naveensingh avatar Feb 16 '23 20:02 naveensingh

What version first had it?

The changes were introduced in 5.17.2

You can try 5.17.1 or 5.17.0, thanks

Initial tests to myself on 5.17.0 has 8 MB zip files working fine. Rebooting again to test other extensions, will follow up. Can't test with another person until maybe 5 hours from now.

Edit: The 4.8 MB video file appears to be sending fine, no error (yet). Edit: The video sent fine.

Edit: The SVG reports "An unknown error occurred". The 1 MB Text file (random binary generated) works fine. Again, this is all 5.17.0. Seems to work a bit better for more stuff, no Error 5 anywhere.

OdinVex avatar Feb 16 '23 21:02 OdinVex

Many thanks but IIRC that was the issue. The MMS messages appeared as sent but were never actually sent because of the error (that was passed silently)

Do lmk how the test with another person goes (at your leisure)

naveensingh avatar Feb 16 '23 21:02 naveensingh

Many thanks but IIRC that was the issue. The MMS messages appeared as sent but were never actually sent because of the error (that was passed silently)

Do lmk how the test with another person goes (at your leisure)

Will do. I do think the 1 MB and 8 MB files were sent rather quickly, though the 4.8 MB file sent slowly enough to think a transfer really happened.

OdinVex avatar Feb 16 '23 21:02 OdinVex

can someone test sending 2 casual images like 10mb? It behaves like it was sent for me, even have the 2 ticks as delivered, but the receiver doesnt receive anything. The current Google play version at least shows an error 5 in that case.

tibbi avatar Feb 17 '23 11:02 tibbi

can someone test sending 2 casual images like 10mb? It behaves like it was sent for me, even have the 2 ticks as delivered, but the receiver doesnt receive anything. The current Google play version at least shows an error 5 in that case.

Edit: Scratch everything I put up before, the app is definitely broken, I had been testing by sending to myself, sometimes the app works with that, sometimes not, no longer assuming a logic issue on that. 5.17.0 and 5.17.4 tested, both fail to actually send to an actual contact (aside a tiny JPG). I couldn't even send a 1 MB random bin text file (my end thought was sent, 2 checkmarks). 10 MB JPG failed. A small 50 KB JPG worked fine. I'm going to need to switch to a third party app for a while, may not be available for testing.

OdinVex avatar Feb 18 '23 04:02 OdinVex

so for me i had to restart my phone and send the image again and it worked. not sure what caused the error code 5 repeatedly. phone pixel 6a. sms messenger up to date as of 9/15/23, provider mint mobile

jessewriter avatar Sep 15 '23 19:09 jessewriter

Same workaround. Same problem with qksms

bodtx avatar Sep 15 '23 20:09 bodtx

The reset workaround didn't work for me. Neither did setting the Resize sent MMS images options to No limit or 100KB, sending a 1.5MB screenshot of the failed messages, or sending a 918.5KB half resolution version of the 7.7MB photo. What did work was setting the default messenger to my phone's original one (Messaging) and sending it from there. 🤷🏿‍♂️

v5.19.3 Pixel 6a GrapheneOS Android v14

QuestioningEspecialy avatar Feb 10 '24 20:02 QuestioningEspecialy

@QuestioningEspecialy SMT apps were sold to ad company. https://github.com/SimpleMobileTools/General-Discussion/issues/241 Fork is here https://github.com/FossifyOrg

inson1 avatar Feb 10 '24 20:02 inson1

I wasn't aware of these apps being abandoned or forked, but for others reading along, here's the issue matching this one in the other repo: https://github.com/FossifyOrg/Messages/issues/45

Soundtoxin avatar Feb 10 '24 21:02 Soundtoxin