I''m trying to set up a means to automatically send an email from certain parts of troubled code, that is, very often, code that might appear in the Rescue predicate of a begin.....rescue, so as to track down issues remotely. Surely there must be a gem for such? If not, how might one construct something like this in code? TIA, RVic -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To unsubscribe from this group and stop receiving emails from it, send an email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To view this discussion on the web visit https://groups.google.com/d/msgid/rubyonrails-talk/42fc38f4-e8f0-43ad-8cd4-47ae607cd056%40googlegroups.com. For more options, visit https://groups.google.com/groups/opt_out.
On Tue, Dec 10, 2013 at 7:32 AM, RVic <rvince99-PkbjNfxxIARBDgjK7y7TUQ@public.gmane.org> wrote:> I''m trying to set up a means to automatically send an email from certain > parts of troubled code, that is, very often, code that might appear in the > Rescue predicate of a begin.....rescue, so as to track down issues remotely. > > Surely there must be a gem for such? If not, how might one construct > something like this in code? TIA, RVicE-Mail poses a security risk and information leak issue, perhaps try using a service that offers SSL and make sure to strip information as it goes into it. There is HoneyBadger (I don''t remember them offering a free service) and Airbrake (they do offer a limited free account.) There is also bugsnag but I haven''t really played with them even though for some reason they keep emailing me. -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To unsubscribe from this group and stop receiving emails from it, send an email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To view this discussion on the web visit https://groups.google.com/d/msgid/rubyonrails-talk/CAM5XQnyARqXDxsr%3DVA6OYW%3DJtffASDyzjMuTXWsMLMMdjjJaaA%40mail.gmail.com. For more options, visit https://groups.google.com/groups/opt_out.
I have a file on Github which sends an email on rescuing an error: https://github.com/VirtuosoJoel/Toolkit/blob/master/AutoReport.rb The method I used to send an email is the "mail" gem, and its usage is demonstrated around line 556 in this file: https://github.com/VirtuosoJoel/Toolkit/blob/master/MechReporter.rb -- Posted via http://www.ruby-forum.com/. -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To unsubscribe from this group and stop receiving emails from it, send an email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To view this discussion on the web visit https://groups.google.com/d/msgid/rubyonrails-talk/cb7c8df7644e7c65fd308b24c3cad138%40ruby-forum.com. For more options, visit https://groups.google.com/groups/opt_out.
http://smartinez87.github.io/exception_notification/ should do what you want -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To unsubscribe from this group and stop receiving emails from it, send an email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To view this discussion on the web visit https://groups.google.com/d/msgid/rubyonrails-talk/389b00ed-046a-4c0e-a996-a1b88cfd63da%40googlegroups.com. For more options, visit https://groups.google.com/groups/opt_out.
On Tue, Dec 10, 2013 at 7:37 AM, Jordon Bedwell <envygeeks-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org> wrote:> On Tue, Dec 10, 2013 at 7:32 AM, RVic <rvince99-PkbjNfxxIARBDgjK7y7TUQ@public.gmane.org> wrote: > > I''m trying to set up a means to automatically send an email from certain > > parts of troubled code, that is, very often, code that might appear in > the > > Rescue predicate of a begin.....rescue, so as to track down issues > remotely. > > > > Surely there must be a gem for such? If not, how might one construct > > something like this in code? TIA, RVic > > E-Mail poses a security risk and information leak issue, perhaps try > using a service that offers SSL and make sure to strip information as > it goes into it. There is HoneyBadger (I don''t remember them offering > a free service) and Airbrake (they do offer a limited free account.) > There is also bugsnag but I haven''t really played with them even > though for some reason they keep emailing me. > > >Datadog is another option, they have a free limited level: 5 hosts, 1 day retention. -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To unsubscribe from this group and stop receiving emails from it, send an email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To view this discussion on the web visit https://groups.google.com/d/msgid/rubyonrails-talk/CAHUC_t-zL8rDTWuoYDSqsNMEyB1%2BTNU1%2B2SJXU0YLQDb4-AKbw%40mail.gmail.com. For more options, visit https://groups.google.com/groups/opt_out.
Thank you all for your replies! This is very helpful. RVic -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To unsubscribe from this group and stop receiving emails from it, send an email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To view this discussion on the web visit https://groups.google.com/d/msgid/rubyonrails-talk/9c9515f2-5cae-4ed6-b6fa-8b9a5934f79e%40googlegroups.com. For more options, visit https://groups.google.com/groups/opt_out.
On Tuesday, 10 December 2013 08:32:33 UTC-5, RVic wrote:> > I''m trying to set up a means to automatically send an email from certain > parts of troubled code, that is, very often, code that might appear in the > Rescue predicate of a begin.....rescue, so as to track down issues remotely. > > Surely there must be a gem for such? If not, how might one construct > something like this in code? TIA, RVic >The hosted services are a good first pick - if you need something like them but can''t (for security or political reasons) use a third-party service, I''d recommend trying out Errbit: https://github.com/errbit/errbit Direct-to-email stuff (like the old exception_notification plugin) is usually sub-optimal: you''ll wind up getting a lot of repeated emails if your site sees reasonable traffic, making it hard to pick out *unique* errors. The services / tools above all can send emails, but they default to only notifying you about "new" errors. --Matt Jones -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To unsubscribe from this group and stop receiving emails from it, send an email to rubyonrails-talk+unsubscribe-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To view this discussion on the web visit https://groups.google.com/d/msgid/rubyonrails-talk/d67750e6-2a4b-4593-a1c1-5d0e310cae5c%40googlegroups.com. For more options, visit https://groups.google.com/groups/opt_out.