Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat(pipeline) : Send RGPD notifications to mes-aides & mediation-numerique #276

Merged
merged 3 commits into from
Aug 21, 2024

Conversation

vperron
Copy link
Contributor

@vperron vperron commented Aug 19, 2024

Vérifié localement que les doublons de la médiation numérique avec Dora, quand l'adresse est la même, ne sont pas notifiés à nouveau (le système fonctionne comme prévu, quoi)

They will also be part of the notification campaign about displaying
their e-mail address in the API.
Make it dead simple for now.

- the notifications were not sent, even though the mailing list attached
  seemed OK in the interface
- we update the list in the same DAG as the notification dispatch
- we suppose that the list is not "properly updated" server-side at the
  time we send the notifications (race condition) so we introduce a
  fixed wait time for now.

We checked that re-triggering the notification alone (without the ML
sync) was indeed working, so chances are on our side. If the MLs are
dispatched next month properly, we could work on a mechanism that
actually checks the ML contents but... not sure we should bother.

BTW TimeDeltaSensor was interesting but unfortunately does not work
super well as the delta is computed from the start date of the DAG which
is "somewhere in 2023", so it does not wait at all in its current form
(without changing much of the DAG shape and initial params), so we took
a quick and simple (dirty ?) approach.
Copy link
Contributor

@vmttn vmttn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

j'ai l'impression qu'on aurait plus de faciliter à tester cette feature si on utilisait plpython pour modéliser les traitements. On pourrait imaginer des unit_test avec une dummy implementation de brevo et des tests d'intégration avec brevo purement en python (deja faisable en fait). Ou un faux environnement brevo pour tester (ce qui me semble moins évident à maintenir). En tout cas ça pourrait simplifier l'orchestration

@vperron
Copy link
Contributor Author

vperron commented Aug 21, 2024

J'ai tellement hâte de passer plein de trucs en plpython :)

@vperron vperron merged commit 59da20c into main Aug 21, 2024
8 of 9 checks passed
@vperron vperron deleted the vperron/more-brevo-contacts branch August 21, 2024 13:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants