DjangoAdminHackers / django-linkcheck

An app that will analyze and report on links in any model that you register with it. Links can be bare (urls or image and file fields) or embedded in HTML (linkcheck handles the parsing). It's fairly easy to override methods of the Linkcheck object should you need to do anything more complicated (like generate URLs from slug fields etc).
BSD 3-Clause "New" or "Revised" License
75 stars 26 forks source link

Send email report with broken links #64

Closed Debakel closed 7 years ago

andybak commented 8 years ago

Let me see if I understand this correctly:

  1. You can (optionally) add a alert_mail_field property to linklists.py
  2. If you do this email address is stored in each Link instance
  3. A separate management command can be used to email a report to each person

Assumptions:

  1. If you don't run the management command then everything works the same as without this feature
  2. If you don't add the alert_mail_field property then everything works the same as without this feature.

Even though I don't have a use for it I guess I can see how it could be useful.

I do wonder if we really need a new database field. Each Link instance knows it's model class and from that it should be possible to match that up with the linklist and thus the email address.

andybak commented 7 years ago

@Debakel did you see my comments here: https://github.com/DjangoAdminHackers/django-linkcheck/pull/64#issuecomment-260914733 - I was hoping for a discussion!