🥅(summary) catch unexpected file-related exceptions when handling recording objects#944
🥅(summary) catch unexpected file-related exceptions when handling recording objects#944lebaudantoine merged 1 commit intomainfrom
Conversation
7857309 to
1156cb5
Compare
|
@coderabbitai full review |
✅ Actions performedFull review triggered. |
WalkthroughA new FileServiceException class was added to summary.core.file_service and _download_from_minio now catches MinioException and S3Error, re-raising them as FileServiceException. In summary.core.celery_worker, process_audio_transcribe_summarize_v2 wraps audio preparation and transcription calls in a try/except that catches FileServiceException, logs and returns early on error, and records transcription start/end times in metadata. An import for FileServiceException was added to the worker module. Estimated code review effort🎯 3 (Moderate) | ⏱️ ~20 minutes 🚥 Pre-merge checks | ✅ 3✅ Passed checks (3 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. 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.
Actionable comments posted: 1
🤖 Fix all issues with AI agents
In `@src/summary/summary/core/celery_worker.py`:
- Line 178: The logged full transcription (the logger.debug call that prints the
variable transcription) exposes potential PII; remove the direct transcription
output and replace it with a safe alternative such as logging only metadata
(e.g., transcription length, language, and a truncated/redacted snippet like
transcription[:100] + '...[REDACTED]') or a non-reversible hash/checksum of
transcription. Locate the logger.debug("Transcription: \n %s", transcription)
call in celery_worker.py and update it to log only redacted/derived info (or
remove the log entirely) while ensuring the variable name transcription is not
interpolated into logs.
✅ Actions performedFull review triggered. |
1156cb5 to
cfa1ffc
Compare
Previously, if a recording file was not found in the bucket, the code would crash. This adds proper error handling to avoid unhandled failures.
cfa1ffc to
2e6fc9d
Compare
|



Previously, if a recording file was not found in the bucket, the code would crash. This adds proper error handling to avoid unhandled failures.