-
-
Notifications
You must be signed in to change notification settings - Fork 252
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Return value of Ddeboer\\Imap\\Message\\AbstractPart::getDecodedContent() must be of the type string, boolean returned #284
Comments
It happens only on malformed base64 contents, isn't it? |
I have same issue. |
@Bambiq may you share the raw mail that triggered the error? |
Resend email to u or what? |
Of course take care to obfuscate sensitive datas. |
Please give me answer as soon as possible, thank u. |
@Bambiq Are you able to save the message in EML format? Binary data can't be used to test the issue, we need raw plain-text data as it is sent through the internet. |
Ok. i send u in a few hours. |
Hello! I get the same error message. Is there a solution to this yet? |
@daivantrinh The problem is still unknown, you can help us by providing the raw email that generated your error. To do so you can call the |
Here is the file from $message->getRawMessage() The mail is sent with Outlook 2016 and the receiver is office 365 basket. Regards. |
I'm sorry @daivantrinh may you also post the full error stack please? I need it to recreate the exact error in the test suite |
Hello @Slamdunk, how do I generate the full stack error? Sorry for my ignorance. |
Simply re-run your script or your application, and post the error message you see. |
I have made a quickfix to the problem by removing the expected return value in, Here is the error you asked for. |
Bug reproduced: present only in PHP 7.0 |
I updated to 1.4.1 and run the script again with php 7.0. PHP Fatal error: Uncaught Ddeboer\Imap\Exception\UnexpectedEncodingException: Cannot decode content Its the same mail that is generating this new error. |
@daivantrinh the bug resides in PHP 7.0 and cannot be fixed. What I've done in #324 is making this error manageable: now you can you a try/catch statement with a specific exception type catch on The issue is fixed in PHP 7.1, we can't do much more. Remember that on November 2018 this library will drop PHP < 7.1 support, so the sooner you update your PHP version the better. |
@Slamdunk, thanks for the quick reply and solution. I am looking to upgrading to PHP 7.1. Thanks again for the great repo, have a great day! |
Although this is now catchable I'm still having an issue as described above by daivantrinh where there is an "eml" attachment with attachments itself. When I output So when it attempts to decode the base64 encoded jpg it calls Should we re-open this issue or create a new one? Can someone contact me directly to collaborate on debugging this and finding a solution? Thanks. |
@billynoah sure: open a new issue with the error stack and email me the original raw email content, I'll dig into it and keep the sensitive data away from public |
thanks - my email is visible on my profile - can you email me directly so I have your address? also, can you explain what error stack means? It's the same error basically, the library wants to decode base64 but instead it's mixing up the mail parts so it tries to decode some quoted printable content as base64 and the result is false. I can email you an email that will allow you to reproduce the issue. hopefully that will suffice. in the meantime - I'll open a new issue. thanks |
No description provided.
The text was updated successfully, but these errors were encountered: