warehouse
warehouse copied to clipboard
Only send "Trusted Publisher ... can be made more secure" emails once per publisher
Currently we send a notification email every time a Trusted Publisher is used within an environment for a publisher that is not constrained to an environment:
https://github.com/pypi/warehouse/blob/071ee72a906815df6be0a2076e1f792986701f7c/warehouse/oidc/views.py#L325-L342
This is somewhat spammy for users who choose not to do this intentionally, with no ability to disable the notifications.
We should only send this email once per publisher. This could be done by adding an additional column on the publisher that indicates whether a warning has been sent or not.
Hi @di, Taking up this issue