Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
require prometheus client libs in mail_fetcher
This is job is currently erroring in all environments, albeit after it's already done all the important work. {"@timestamp":"2024-09-16T13:05:05.605Z","message":"Finished running MailFetcher in production mode - 2024-09-16 13:05:05 UTC","level":"INFO","tags":["rails"]} script/mail_fetcher:58:in `<main>': uninitialized constant Prometheus::Client::Push (NameError) Prometheus::Client::Push.new( Note the "Finished running MailFetcher in production mode" log before the error - the script has still done everything it needs to, it just hasn't sent the metrics, which fortunately is on the very last line of the script. This looks like the same mistake I made when doing metrics for publishing-api: alphagov/publishing-api@3037457 We need to explicitly require the push library to use it. I'm not 100% sure if we really need the other two imports (client and registry), but publishing-api has them, so we may as well be consistent. Can't hurt, surely.
- Loading branch information