Address intake review follow-ups#346
Conversation
|
Warning Review limit reached
More reviews will be available in 44 minutes and 28 seconds. Learn how PR review limits work. Your organization has used up its prepaid credits, and credit purchases are no longer available. Enable the review add-on in the billing tab to keep reviews running — you're only billed for reviews past your plan's rate limits ($0.25/file). ⌛ How to resolve this issue?After more reviews become available, a review can be triggered using the To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based credits. 🚦 How do rate limits work?CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability. For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window. Please see our Fair Usage Limits Policy for further information. ℹ️ Review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (3)
📝 WalkthroughWalkthroughReplaces the Tally-specific raw payload sanitizer with a generic Intake Sanitization and Resume Sentinel
Estimated code review effort🎯 2 (Simple) | ⏱️ ~10 minutes Possibly related PRs
Poem
🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
✨ Finishing Touches🧪 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 |
There was a problem hiding this comment.
Pull request overview
This PR tightens intake processing across the API and worker to improve audit/debug traceability and avoid redundant resume preparation work, with regression tests to lock in behavior.
Changes:
- Preserve a sanitized
raw_payloadfor Google Forms intake jobs (and unify raw-payload sanitization for both Google Forms and Tally). - Ensure resume download/scan preparation is attempted at most once per create/update flow in the worker.
- Add unit coverage for raw payload preservation and the single-attempt resume preparation behavior.
Reviewed changes
Copilot reviewed 4 out of 4 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
apps/api/src/five08/backend/api.py |
Adds sanitized raw_payload for Google Forms jobs and unifies intake raw-payload sanitization. |
apps/worker/src/five08/worker/crm/intake_form_processor.py |
Introduces a sentinel to distinguish “not provided” vs explicit None, preventing resume prepare retries. |
tests/unit/test_backend_api.py |
Adds assertions for resume_url passthrough + sanitized raw_payload preservation. |
tests/unit/test_intake_form_processor.py |
Adds regression tests ensuring resume preparation isn’t retried in create/update flows. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| prepared_resume_file: IntakeResumeFile | None | ||
| if isinstance(resume_file, _ResumeFileNotProvided): | ||
| prepared_resume_file = self._prepare_resume_file(payload) | ||
| else: | ||
| prepared_resume_file = resume_file |
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 `@apps/api/src/five08/backend/api.py`:
- Around line 822-828: The shared sanitizer in _sanitize_intake_raw_payload
currently strips query strings but still preserves URL fragments, so sensitive
fragment data can be persisted in onboarding_intake_submissions.raw_payload.
Update the URL handling in this sanitizer to remove fragments as well as queries
before storage, and keep the change localized to the shared raw-payload path so
all callers benefit.
🪄 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: b16700bf-1138-499c-8774-dbd2fc37b70f
📒 Files selected for processing (4)
apps/api/src/five08/backend/api.pyapps/worker/src/five08/worker/crm/intake_form_processor.pytests/unit/test_backend_api.pytests/unit/test_intake_form_processor.py
Summary
Testing
Follow-up for review threads from #335:
Summary by CodeRabbit