Jump to content

Email Notifications


Recommended Posts

Posted

It wasn't working for me, I uninstalled the plugin, restarted the server, re-installed the plugin - and it worked!

Posted

This plugin hasn't been working for me since the last update.  The uninstall/reinstall worked for me as well.  It even saved the settings I had and the test notification works for the first time too.  Using gmail as smtp server.

  • 1 year later...
Posted

FYI for gmail you might need to enable an option in your Gmail account because i'm not sure if the .NET smtp api's supports default minimum security standards.

 

See here, scroll down about halfway through:

 

http://stackoverflow.com/questions/32260/sending-email-in-net-through-gmail

 

This is just for your own info if you want to use gmail. Maybe the .NET SmtpClient does support what it needs, i"m just not sure.

Posted

Actually I've pushed an update to the plugin to replace the email sending with an alternative open source implementation. It should support more types of email servers now. If anyone is running the beta server and can try it out that would be helpful, thanks.

Posted

Tried on latest dev and beta but still get an error when sending a test notification:

 

"There was an error sending the test email. Please check your email settings and try again."

 

It was doing the same on the previous version, but I still received normal notifications, so will see if I get any.

 

From the server log:

 

2016-11-19 11:30:44.1935 Info Notifier: Emailing EMAIL@ADDRESS with subject Emby: Emby: Test Notification
2016-11-19 11:30:44.2415 Error HttpServer: Error processing request
	*** Error Report ***
	Version: 3.1.6166.23097
	Command line: C:\Users\Media\AppData\Roaming\MediaBrowser-Server\System\MediaBrowser.ServerApplication.exe
	Operating system: Microsoft Windows NT 6.1.7601 Service Pack 1
	64-Bit OS: True
	64-Bit Process: True
	Processor count: 4
	Program data path: C:\Users\Media\AppData\Roaming\MediaBrowser-Server
	Application directory: C:\Users\Media\AppData\Roaming\MediaBrowser-Server\System
	System.NullReferenceException: Object reference not set to an instance of an object.
	   at MediaBrowser.Plugins.SmtpNotifications.Notifier.<>c__DisplayClass8_0.<GetOptions>b__0(SMTPOptions i)
	   at System.Linq.Enumerable.FirstOrDefault[TSource](IEnumerable`1 source, Func`2 predicate)
	   at MediaBrowser.Plugins.SmtpNotifications.Notifier.SendNotificationInternal(UserNotification request, CancellationToken cancellationToken)
	   at MediaBrowser.Plugins.SmtpNotifications.Api.ServerApiEndpoints.Post(TestNotification request)
	   at ServiceStack.Host.ServiceExecGeneral.<>c__DisplayClass4_0.<CreateExecFn>b__0(Object service, Object request)
	   at ServiceStack.Host.ServiceExecGeneral.<Execute>d__2.MoveNext()
	--- End of stack trace from previous location where exception was thrown ---
	   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
	   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
	   at ServiceStack.Host.ServiceController.<Execute>d__15.MoveNext()
	--- End of stack trace from previous location where exception was thrown ---
	   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
	   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
	   at ServiceStack.Host.RestHandler.<ProcessRequestAsync>d__19.MoveNext()
	--- End of stack trace from previous location where exception was thrown ---
	   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
	   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
	   at Emby.Server.Implementations.HttpServer.HttpListenerHost.<RequestHandler>d__59.MoveNext()
	System.NullReferenceException
	   at MediaBrowser.Plugins.SmtpNotifications.Notifier.<>c__DisplayClass8_0.<GetOptions>b__0(SMTPOptions i)
	   at System.Linq.Enumerable.FirstOrDefault[TSource](IEnumerable`1 source, Func`2 predicate)
	   at MediaBrowser.Plugins.SmtpNotifications.Notifier.SendNotificationInternal(UserNotification request, CancellationToken cancellationToken)
	   at MediaBrowser.Plugins.SmtpNotifications.Api.ServerApiEndpoints.Post(TestNotification request)
	   at ServiceStack.Host.ServiceExecGeneral.<>c__DisplayClass4_0.<CreateExecFn>b__0(Object service, Object request)
	   at ServiceStack.Host.ServiceExecGeneral.<Execute>d__2.MoveNext()
	--- End of stack trace from previous location where exception was thrown ---
	   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
	   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
	   at ServiceStack.Host.ServiceController.<Execute>d__15.MoveNext()
	--- End of stack trace from previous location where exception was thrown ---
	   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
	   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
	   at ServiceStack.Host.RestHandler.<ProcessRequestAsync>d__19.MoveNext()
	--- End of stack trace from previous location where exception was thrown ---
	   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
	   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
	   at Emby.Server.Implementations.HttpServer.HttpListenerHost.<RequestHandler>d__59.MoveNext()
	
2016-11-19 11:30:44.2415 Error HttpServer: Error processing request
	*** Error Report ***
	Version: 3.1.6166.23097
	Command line: C:\Users\Media\AppData\Roaming\MediaBrowser-Server\System\MediaBrowser.ServerApplication.exe
	Operating system: Microsoft Windows NT 6.1.7601 Service Pack 1
	64-Bit OS: True
	64-Bit Process: True
	Processor count: 4
	Program data path: C:\Users\Media\AppData\Roaming\MediaBrowser-Server
	Application directory: C:\Users\Media\AppData\Roaming\MediaBrowser-Server\System
	System.NullReferenceException: Object reference not set to an instance of an object.
	   at MediaBrowser.Plugins.SmtpNotifications.Notifier.<>c__DisplayClass8_0.<GetOptions>b__0(SMTPOptions i)
	   at System.Linq.Enumerable.FirstOrDefault[TSource](IEnumerable`1 source, Func`2 predicate)
	   at MediaBrowser.Plugins.SmtpNotifications.Notifier.SendNotificationInternal(UserNotification request, CancellationToken cancellationToken)
	   at MediaBrowser.Plugins.SmtpNotifications.Api.ServerApiEndpoints.Post(TestNotification request)
	   at ServiceStack.Host.ServiceExecGeneral.<>c__DisplayClass4_0.<CreateExecFn>b__0(Object service, Object request)
	   at ServiceStack.Host.ServiceExecGeneral.<Execute>d__2.MoveNext()
	--- End of stack trace from previous location where exception was thrown ---
	   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
	   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
	   at ServiceStack.Host.ServiceController.<Execute>d__15.MoveNext()
	--- End of stack trace from previous location where exception was thrown ---
	   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
	   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
	   at ServiceStack.Host.RestHandler.<ProcessRequestAsync>d__19.MoveNext()
	--- End of stack trace from previous location where exception was thrown ---
	   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
	   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
	   at Emby.Server.Implementations.HttpServer.HttpListenerHost.<RequestHandler>d__59.MoveNext()
	System.NullReferenceException
	   at MediaBrowser.Plugins.SmtpNotifications.Notifier.<>c__DisplayClass8_0.<GetOptions>b__0(SMTPOptions i)
	   at System.Linq.Enumerable.FirstOrDefault[TSource](IEnumerable`1 source, Func`2 predicate)
	   at MediaBrowser.Plugins.SmtpNotifications.Notifier.SendNotificationInternal(UserNotification request, CancellationToken cancellationToken)
	   at MediaBrowser.Plugins.SmtpNotifications.Api.ServerApiEndpoints.Post(TestNotification request)
	   at ServiceStack.Host.ServiceExecGeneral.<>c__DisplayClass4_0.<CreateExecFn>b__0(Object service, Object request)
	   at ServiceStack.Host.ServiceExecGeneral.<Execute>d__2.MoveNext()
	--- End of stack trace from previous location where exception was thrown ---
	   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
	   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
	   at ServiceStack.Host.ServiceController.<Execute>d__15.MoveNext()
	--- End of stack trace from previous location where exception was thrown ---
	   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
	   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
	   at ServiceStack.Host.RestHandler.<ProcessRequestAsync>d__19.MoveNext()
	--- End of stack trace from previous location where exception was thrown ---
	   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
	   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
	   at Emby.Server.Implementations.HttpServer.HttpListenerHost.<RequestHandler>d__59.MoveNext()
	
2016-11-19 11:30:44.2415 Info HttpServer: HTTP Response 500 to 192.168.1.22. Time: 71ms. http://192.168.1.140:8096/emby/Notification/SMTP/Test/3558d83febb02707497c92721b7a69c3
2016-11-19 11:30:44.2415 Info HttpServer: HTTP Response 500 to 192.168.1.22. Time: 72ms. http://192.168.1.140:8096/emby/Notification/SMTP/Test/fe8e98c1df54d9b502474bab46ee8982
 
Posted

To test the new release, I installed a new plugin but I didn't get a notification that I had installed it.

 

I went back to the previous version of the plugin and I get notifications, but the plugin is then automatically updated to the latest version.

 

So on the previous version I get notifications, but the latest I don't.

 

I've tested this on both dev and beta servers.

Posted

Ok I pushed another update, thanks.

Posted

Luke - not sure if this is related, but I have a notification in the Dashboard that won't mark as being "read".

 

I'm seeing this in the latest DEV and BETA releases you've just pushed.

 

There aren't any errors in either server logs.

 

I've tried marking it as read via the Emby Companion extension in the Chrome browser, but it won't change.

 

Just thought I'd mention it.

FrostByte
Posted

Luke - not sure if this is related, but I have a notification in the Dashboard that won't mark as being "read".

 

I'm seeing this in the latest DEV and BETA releases you've just pushed.

 

There aren't any errors in either server logs.

 

I've tried marking it as read via the Emby Companion extension in the Chrome browser, but it won't change.

 

Just thought I'd mention it.

 

I'm seeing one message also that won't go away.  I'm still on .226 though (will update to 227 after movie is over).  I'm not using the email notification though

 

5830e4834160e_unread.jpg

  • Like 1
Posted

Are emails sending now with the previously mentioned changes?

Posted

I am not getting emails when using gmail

Posted

Please provide a server log, thanks. Also if you were using a different email provider besides Gmail with the previous version of the plugin, a comparison of before and after would be helpful. Thanks.

Posted

Are emails sending now with the previously mentioned changes?

 

No, I'm still not receiving any emails.

 

I send through my own domain to my GMAIL account as I always have done.

 

Before the plugin was released the other day, I was receiving emails.

 

there is nothing in the server log other than:

 

2016-11-21 07:38:42.9318 Debug NotificationManager: Sending notification via Email Notifications to user Master
2016-11-21 07:38:43.2348 Info App: Emailing EMAIL_ADDRESS with subject Emby: A new version of Emby Server 3.1.6168.41403 has been installed (MediaServer-3).
2016-11-21 07:38:44.1109 Debug NotificationManager: Sending notification via Email Notifications to user Master
2016-11-21 07:38:44.1109 Info App: Emailing EMAIL_ADDRESS with subject Emby: Please restart Emby Server to finish updating (MediaServer-3).

Still no emails received though.

 

Posted

Using the "Test Notification" option, I get the following error(s) in the server log:

 

2016-11-21 10:30:54.8758 Info AuthenticationRepository: Opening connection
2016-11-21 10:30:54.8758 Info App: Emailing EMAIL_ADDRESS with subject Emby: Emby: Test Notification
2016-11-21 10:30:54.8758 Error HttpServer: Error processing request
*** Error Report ***
Version: 3.1.6168.41403
Command line: C:\Users\Media\AppData\Roaming\MediaBrowser-Server\System\MediaBrowser.ServerApplication.exe
Operating system: Microsoft Windows NT 6.1.7601 Service Pack 1
64-Bit OS: True
64-Bit Process: True
Processor count: 4
Program data path: C:\Users\Media\AppData\Roaming\MediaBrowser-Server
Application directory: C:\Users\Media\AppData\Roaming\MediaBrowser-Server\System
System.NullReferenceException: Object reference not set to an instance of an object.
  at MediaBrowser.Plugins.SmtpNotifications.Notifier.<>c__DisplayClass4_0.<GetOptions>b__0(SMTPOptions i)
  at System.Linq.Enumerable.FirstOrDefault[TSource](IEnumerable`1 source, Func`2 predicate)
  at MediaBrowser.Plugins.SmtpNotifications.Notifier.SendNotificationInternal(UserNotification request, CancellationToken cancellationToken)
  at MediaBrowser.Plugins.SmtpNotifications.Api.ServerApiEndpoints.Post(TestNotification request)
  at ServiceStack.Host.ServiceExecGeneral.<>c__DisplayClass4_0.<CreateExecFn>b__0(Object service, Object request)
  at ServiceStack.Host.ServiceExecGeneral.<Execute>d__2.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
  at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
  at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
  at ServiceStack.Host.ServiceController.<Execute>d__15.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
  at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
  at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
  at ServiceStack.Host.RestHandler.<ProcessRequestAsync>d__19.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
  at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
  at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
  at Emby.Server.Implementations.HttpServer.HttpListenerHost.<RequestHandler>d__60.MoveNext()
System.NullReferenceException
  at MediaBrowser.Plugins.SmtpNotifications.Notifier.<>c__DisplayClass4_0.<GetOptions>b__0(SMTPOptions i)
  at System.Linq.Enumerable.FirstOrDefault[TSource](IEnumerable`1 source, Func`2 predicate)
  at MediaBrowser.Plugins.SmtpNotifications.Notifier.SendNotificationInternal(UserNotification request, CancellationToken cancellationToken)
  at MediaBrowser.Plugins.SmtpNotifications.Api.ServerApiEndpoints.Post(TestNotification request)
  at ServiceStack.Host.ServiceExecGeneral.<>c__DisplayClass4_0.<CreateExecFn>b__0(Object service, Object request)
  at ServiceStack.Host.ServiceExecGeneral.<Execute>d__2.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
  at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
  at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
  at ServiceStack.Host.ServiceController.<Execute>d__15.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
  at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
  at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
  at ServiceStack.Host.RestHandler.<ProcessRequestAsync>d__19.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
  at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
  at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
  at Emby.Server.Implementations.HttpServer.HttpListenerHost.<RequestHandler>d__60.MoveNext()

2016-11-21 10:30:54.8758 Info HttpServer: HTTP Response 500 to 81.140.218.9. Time: 34ms. http://192.168.1.140:8096/emby/Notification/SMTP/Test/fe8e98c1df54d9b502474bab46ee8982
2016-11-21 10:30:54.8758 Error HttpServer: Error processing request
*** Error Report ***
Version: 3.1.6168.41403
Command line: C:\Users\Media\AppData\Roaming\MediaBrowser-Server\System\MediaBrowser.ServerApplication.exe
Operating system: Microsoft Windows NT 6.1.7601 Service Pack 1
64-Bit OS: True
64-Bit Process: True
Processor count: 4
Program data path: C:\Users\Media\AppData\Roaming\MediaBrowser-Server
Application directory: C:\Users\Media\AppData\Roaming\MediaBrowser-Server\System
System.NullReferenceException: Object reference not set to an instance of an object.
  at MediaBrowser.Plugins.SmtpNotifications.Notifier.<>c__DisplayClass4_0.<GetOptions>b__0(SMTPOptions i)
  at System.Linq.Enumerable.FirstOrDefault[TSource](IEnumerable`1 source, Func`2 predicate)
  at MediaBrowser.Plugins.SmtpNotifications.Notifier.SendNotificationInternal(UserNotification request, CancellationToken cancellationToken)
  at MediaBrowser.Plugins.SmtpNotifications.Api.ServerApiEndpoints.Post(TestNotification request)
  at ServiceStack.Host.ServiceExecGeneral.<>c__DisplayClass4_0.<CreateExecFn>b__0(Object service, Object request)
  at ServiceStack.Host.ServiceExecGeneral.<Execute>d__2.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
  at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
  at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
  at ServiceStack.Host.ServiceController.<Execute>d__15.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
  at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
  at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
  at ServiceStack.Host.RestHandler.<ProcessRequestAsync>d__19.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
  at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
  at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
  at Emby.Server.Implementations.HttpServer.HttpListenerHost.<RequestHandler>d__60.MoveNext()
System.NullReferenceException
  at MediaBrowser.Plugins.SmtpNotifications.Notifier.<>c__DisplayClass4_0.<GetOptions>b__0(SMTPOptions i)
  at System.Linq.Enumerable.FirstOrDefault[TSource](IEnumerable`1 source, Func`2 predicate)
  at MediaBrowser.Plugins.SmtpNotifications.Notifier.SendNotificationInternal(UserNotification request, CancellationToken cancellationToken)
  at MediaBrowser.Plugins.SmtpNotifications.Api.ServerApiEndpoints.Post(TestNotification request)
  at ServiceStack.Host.ServiceExecGeneral.<>c__DisplayClass4_0.<CreateExecFn>b__0(Object service, Object request)
  at ServiceStack.Host.ServiceExecGeneral.<Execute>d__2.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
  at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
  at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
  at ServiceStack.Host.ServiceController.<Execute>d__15.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
  at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
  at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
  at ServiceStack.Host.RestHandler.<ProcessRequestAsync>d__19.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
  at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
  at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
  at Emby.Server.Implementations.HttpServer.HttpListenerHost.<RequestHandler>d__60.MoveNext()
Hope that helps.
Posted

What are the contents of the complete log? thanks.

Posted

What are the contents of the complete log? thanks.

 

Full log here - it's 19Mb in size.

Posted

Here's an email. Did this go through?

2016-11-21 19:14:01.8110 Info App: Emailing EMAIL_ADDRESS with subject Emby: A new version of Emby Server 3.1.6169.25342 has been installed (MediaServer-3).

Posted

No emails received.

Posted

Ok, I'm at the point of pulling this plugin from the catalog unless someone else would like to take it over. We are simply passing the criteria to external API's to send the email. It's just getting to be too much for me to have to troubleshoot why emails are not being sent.

Posted

I'd rather you put it back as it was before you updated it and remove the TEST option.

 

Unless you can post the DLL that was working and then pull it.

 

I look after 5 different Emby server setups for friends and family and having the notifications is really useful.

 

It saves me having to connect every day to check to check all is OK.

 

I use the same email and domain as NzbGet uses for its email notifications and they are always delivered.

Posted

For what it's worth, sending through Gmail on the latest plugin is working fine for me.

Posted

That's interesting, thanks for the input.

Happy2Play
Posted

Stable server 3.0.8500 and v3.0.6119.41073 sent test email fine with Hotmail.  Will test beta and updated plugin tomorrow.

Posted

The issue remains though with the old version of the plugin, the email sending api that it's using does not seem to work with all email domains, therefore we can't really have it in the catalog because it just leads to people thinking "emby doesn't work". the new approach has some potential if we can get that to work consistently.

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...