Interview: implement deletion interview cpm#1747
Conversation
📝 WalkthroughWalkthroughThe interview service adds privacy deletion for interview assignments. Core privacy export and deletion preparation now resolve phase types from courses in which the student participates. ChangesPrivacy data handling
Estimated code review effort: 3 (Moderate) | ~20 minutes Sequence Diagram(s)sequenceDiagram
participant PrivacyDataDeletionHandler
participant Queries
participant interview_assignment
PrivacyDataDeletionHandler->>Queries: Delete assignments for subject.CourseParticipationIDs
Queries->>interview_assignment: Execute DELETE with UUID array
interview_assignment-->>Queries: Return execution error
Possibly related PRs
Suggested labels: Suggested reviewers: 🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✨ Finishing Touches📝 Generate docstrings
🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
5c95b99 to
1d1c073
Compare
|
rebase on main |
There was a problem hiding this comment.
Actionable comments posted: 1
🤖 Prompt for all review comments with AI agents
Verify each finding against current code. Fix only still-valid issues, skip the
rest with a brief reason, keep changes minimal, and validate.
Inline comments:
In `@servers/interview/privacy/main.go`:
- Line 14: Update InitPrivacyModule to register the privacy deletion endpoint on
the coursePhaseApi route group instead of the unscoped api group, ensuring
RegisterPrivacyDataDeletionEndpoint is mounted beneath
/api/course_phase/:coursePhaseID and uses the SDK-authenticated route context.
🪄 Autofix (Beta)
Fix all unresolved CodeRabbit comments on this PR:
- Push a commit to this branch (recommended)
- Create a new PR with the fixes
ℹ️ Review info
⚙️ Run configuration
Configuration used: defaults
Review profile: CHILL
Plan: Pro
Run ID: b65163eb-8d50-4352-b62e-b4e45707e269
📒 Files selected for processing (5)
servers/interview/db/query/privacy.sqlservers/interview/db/sqlc/privacy.sql.goservers/interview/main.goservers/interview/privacy/main.goservers/interview/privacy/service.go
mathildeshagl
left a comment
There was a problem hiding this comment.
Same as for Certificate phase: looks good, just I think it would make sense to add E2E tests here as you go already, so we do not have to add them in a follow-up later on. @JGStyle
✨ What is the change?
Delete all subject based records upon request inside the interview cpm. On the interview cpm, this is only interview_assignment until now. (More will come with
Interview: become unified and fully independent of core #1880)also fix a bug with the core deletion to make sure all course phases are reached (edge case where the course participation was not yet created, the core would not fan out to that service.)
📌 Reason for the change / Link to issue
as part of the bigger move to get gdpr deletion across prompt
https://github.com/orgs/prompt-edu/discussions/683
🧪 How to Test
As a user with data on the interview phase, request deletion
Approve the deletion as an admin from the privacy dashboard
Verify the users data has been deleted.
F.e. by looking at the removed interview slots, or by verifying the db records were deleted in the interview db
🖼️ Screenshots (if UI changes are included)
full deletion process in demo:
2026-07-14.at.21.07.56.mp4
✅ PR Checklist
Summary by CodeRabbit