-
Notifications
You must be signed in to change notification settings - Fork 84
Remove auto-resubmit for privacy requests with expired identity data #7207
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
base: main
Are you sure you want to change the base?
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub. 2 Skipped Deployments
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Greptile Overview
Greptile Summary
This PR removes the auto-resubmit functionality for privacy requests with expired identity data. The changes are straightforward and safe:
Key Changes
- Removed 11 lines of code from
restart_privacy_request_from_failureendpoint that automatically resubmitted requests when identity cache was expired - Removed the
verify_cache_for_identity_data()method which was only used by the auto-resubmit logic
Context
The auto-resubmit logic was introduced after PR #6896 added fallback-to-database functionality. Since get_cached_identity_data() now automatically falls back to the database when cache expires, the auto-resubmit is no longer necessary. Privacy requests can proceed normally even with expired cache.
Review Notes
- No test coverage found for the removed auto-resubmit functionality
- The
resubmit_privacy_requestendpoint and service method remain available for manual resubmission if needed - The removal is clean with no dangling references
Confidence Score: 5/5
- This PR is safe to merge with no risk
- The changes are minimal, well-contained, and simply remove a now-unnecessary workaround. The fallback-to-database functionality (added in #6896) already handles expired cache gracefully, making the auto-resubmit logic redundant. No breaking changes or side effects identified.
- No files require special attention
Important Files Changed
File Analysis
| Filename | Score | Overview |
|---|---|---|
| src/fides/api/api/v1/endpoints/privacy_request_endpoints.py | 5/5 | Removed auto-resubmit logic for privacy requests with expired identity data. The removal is clean and doesn't affect any other functionality since the fallback to DB (added in #6896) already handles expired cache gracefully. |
| src/fides/api/models/privacy_request/privacy_request.py | 5/5 | Removed unused verify_cache_for_identity_data() method which was only used by the now-removed auto-resubmit logic. The method had no other references in the codebase. |
erosselli
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Actually -- we don;t store derived identities in the DB, so we'd need to check if the request has derived identities and re-submit then still :)
Ticket ENG-2324
Description Of Changes
When a privacy request is retried via the Admin UI, the retry endpoint previously checked if identity data was still in the Redis cache. If the cache had expired (which can happen for long-running or stuck requests), the endpoint would automatically trigger a full resubmit of the request instead of a retry.
This was a workaround because
verify_cache_for_identity_data()only checked the cache and didn't fall back to the database. Now thatverify_cache_for_identity_data()properly falls back to the persisted identity data in the database when the cache is empty (#6896), this auto-resubmit fallback is no longer necessary and can be removed.This simplifies the retry flow and ensures that clicking "Reprocess" in the Admin UI actually retries the request rather than unexpectedly resubmitting it.
Code Changes
restart_privacy_request_from_failureendpoint inprivacy_request_endpoints.pySteps to Confirm
Pre-Merge Checklist
CHANGELOG.mdupdatedmaindowngrade()migration is correct and works