Skip to content
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

[mail] Fix UnsupportedDataTypeException #12568

Merged
merged 1 commit into from
Apr 25, 2022
Merged

Conversation

hmerk
Copy link
Contributor

@hmerk hmerk commented Apr 3, 2022

Originally by @J-N-K fixed in smarthomej/addons
smarthomej/addons#254

Reported on the forum.
https://community.openhab.org/t/mail-binding-errors-sending-mail-unsupporteddatatypeexception-text-plaijn-charset-utf-8/130365
The reason is that the standard implementation uses a context class loader to get the mime type handlers and tries to load the handlers from there. Under some circumstances this is the class loader of the activation bundle which does doesn't have the com.sun.mail packages available, leading to an javax.activation.UnsupportedDataTypeException: text/plain; charset=UTF-8 exception.

Fixes #11838

Signed-off-by: Hans-Jörg Merk [email protected]
Also Signed-off-by: Jan N. Klug [email protected]

@hmerk hmerk requested a review from a team as a code owner April 3, 2022 07:59
@hmerk hmerk requested a review from cweitkamp April 3, 2022 08:01
@hmerk
Copy link
Contributor Author

hmerk commented Apr 3, 2022

@cweitkamp As you already reviewed the original fix, I am requesting your review here as well.

@openhab-bot
Copy link
Collaborator

This pull request has been mentioned on openHAB Community. There might be relevant details there:

https://community.openhab.org/t/mail-binding-errors-sending-mail-unsupporteddatatypeexception-text-plaijn-charset-utf-8/130365/33

@hmerk hmerk added the bug An unexpected problem or unintended behavior of an add-on label Apr 3, 2022
@hmerk
Copy link
Contributor Author

hmerk commented Apr 24, 2022

@openhab/add-ons-maintainers Really no one willing to review to have this bug fixed ?

Copy link
Member

@wborn wborn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for fixing this bug @hmerk and @J-N-K!

@wborn wborn merged commit 270c917 into openhab:main Apr 25, 2022
@wborn wborn added this to the 3.3 milestone Apr 25, 2022
@hmerk
Copy link
Contributor Author

hmerk commented Apr 25, 2022

Thanks @wborn and @J-N-K !!!!!

@hmerk hmerk deleted the mail-binding-fix branch April 25, 2022 09:03
NickWaterton pushed a commit to NickWaterton/openhab-addons that referenced this pull request Apr 27, 2022
Also-by: Jan N. Klug <[email protected]>
Signed-off-by: Hans-Jörg Merk <[email protected]>
Signed-off-by: Nick Waterton <[email protected]>
andan67 pushed a commit to andan67/openhab-addons that referenced this pull request Nov 6, 2022
andrasU pushed a commit to andrasU/openhab-addons that referenced this pull request Nov 12, 2022
Also-by: Jan N. Klug <[email protected]>
Signed-off-by: Hans-Jörg Merk <[email protected]>
Signed-off-by: Andras Uhrin <[email protected]>
psmedley pushed a commit to psmedley/openhab-addons that referenced this pull request Feb 23, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug An unexpected problem or unintended behavior of an add-on
Projects
None yet
Development

Successfully merging this pull request may close these issues.

[Mail] sendMail and sendHtmlFail errors for UI rules
4 participants