Handle lf email per provider (read only) - prod#4961
Conversation
Signed-off-by: Lukasz Gryglicki <lgryglicki@cncf.io> Assisted by [OpenAI](https://platform.openai.com/) Assisted by [GitHub Copilot](https://github.com/features/copilot)
|
Important Review skippedAuto reviews are disabled on base/target branches other than the default branch. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
✨ Finishing Touches🧪 Generate unit tests (beta)
Comment |
There was a problem hiding this comment.
Pull request overview
Updates DocuSign signature email resolution to avoid using stale lf_email for GitHub/GitLab sign flows, aligning behavior with issue #4939 (GitHub/GitLab should rely on provider-derived user_emails; Gerrit can use LFID email).
Changes:
- Add provider-aware email resolution for ICLA DocuSign defaults in the Python backend and extend unit tests to validate GitHub vs Gerrit behavior.
- Update the Go v2 signing service email selection to conditionally allow
LfEmail(intended for Gerrit) and avoid it for GitHub/GitLab. - Stabilize functional Cypress tests by adding a pre-test “fixture repair” step and explicitly adding
dotenvto the functional test devDependencies/locks.
Reviewed changes
Copilot reviewed 5 out of 7 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
cla-backend/cla/models/docusign_models.py |
Provider-aware email resolution for individual signatures and DocuSign URL population. |
cla-backend/cla/tests/unit/test_docusign_models.py |
Unit tests ensuring GitHub ignores lf_email while Gerrit can use it. |
cla-backend-go/v2/sign/service.go |
Update Go signing service email selection to gate LfEmail usage by provider type. |
tests/functional/cypress/e2e/v4/github-repositories.cy.ts |
Add pre-test repo re-enable step to reduce E2E flakiness. |
tests/functional/package.json |
Add dotenv devDependency for Cypress config usage. |
tests/functional/yarn.lock |
Lockfile update for dotenv version resolution. |
tests/functional/package-lock.json |
Lockfile update for dotenv version resolution. |
Files not reviewed (1)
- tests/functional/package-lock.json: Language not supported
Work on this slack request.
Issue: #4939
This is the prod version of #4944.
Signed-off-by: Lukasz Gryglicki lgryglicki@cncf.io
Assisted by OpenAI
Assisted by GitHub Copilot