nels-o / toaster

A wee Win8 console notifications app. Post toast notifications from the console, making it easy to integrate into existing batch scripts etc.
111 stars 17 forks source link

Unhandled Exception: SQL error or missing database #8

Open sirlancelot opened 7 years ago

sirlancelot commented 7 years ago

A colleague of mine was having this issue on Windows 10 when running this through gulp-notify. The following error is shown when trying to notify.

Unhandled Exception: System.Exception: SQL error or missing database (Exception from HRESULT: 0x87AF0001)
   at Windows.UI.Notifications.ToastNotifier.Show(ToastNotification notification)
   at toast.Program.ShowToast(String title, String message, String imageURI, Boolean sound)
   at toast.Program.Main(String[] args)

We traced the issue down to a corrupted Windows 10 notification database. Go to ~\AppData\Local\Microsoft\Windows\Notifications and delete the three *.db* files. You may need to close & restart Explorer.

Perhaps an enhancement which can be made to this app would be to catch this exception and output something a little more helpful.

nels-o commented 7 years ago

Oh, interesting. I'll think a bit about how toaster should handle that sort of exception.

sirlancelot commented 7 years ago

Thanks @nels-o! My team has found this app quite useful. Thanks for making it!