ThreeSixtyGiving / grantnav

This is a web based search tool for data in the 360 giving data format.
http://grantnav.threesixtygiving.org/
Other
9 stars 5 forks source link

Set up alerts when GrantNav run is complete #1090

Open mariongalley opened 2 months ago

mariongalley commented 2 months ago

Is your feature request related to a problem? Please describe. We don't know when a GrantNav run is complete after a takedown

Describe the solution you'd like Email 360Giving when a GrantNav run is complete (if it has been triggered manually)

Describe alternatives you've considered Check GrantNav manually after ~ 4h

Additional context Add any other context or screenshots about the feature request here.

michaelwood commented 2 months ago

The only tricky bit here is working out if a pipeline run is manual or not, we could guess it based on the time of day, but there is always the possibility that someone might do a manual run in the night that overlaps with the regular loading window of time.

If this is quite urgent we could do a simple v0 which alerts every time GrantNav has finished loading without us needing to modify any code.

A v1 which alerts only on manual needs to have access to some new data from the datastore, as we currently don't store whether it was a manual run or scheduled. This could be a new status and added to the updates API that already exists (https://github.com/ThreeSixtyGiving/datastore/blob/live/datastore/api/grantnav/api.py#L17).

mariongalley commented 2 months ago

@michaelwood It makes sense to alert based on time of day - we wouldn't manually re-run the pipeline if it was close to the time of the nightly run I don't think