fix: Manual scanning
All checks were successful
Deploy to Staging / Build Images (pull_request) Successful in 35s
Deploy to Staging / Deploy to Staging (pull_request) Successful in 51s
Deploy to Staging / Verify Staging (pull_request) Successful in 8s
Deploy to Staging / Notify Staging Ready (pull_request) Successful in 7s
Deploy to Staging / Notify Staging Failure (pull_request) Has been skipped
All checks were successful
Deploy to Staging / Build Images (pull_request) Successful in 35s
Deploy to Staging / Deploy to Staging (pull_request) Successful in 51s
Deploy to Staging / Verify Staging (pull_request) Successful in 8s
Deploy to Staging / Notify Staging Ready (pull_request) Successful in 7s
Deploy to Staging / Notify Staging Failure (pull_request) Has been skipped
This commit is contained in:
@@ -359,8 +359,8 @@ async def process_manual_job(job_id: str) -> None:
|
||||
# Update status to processing
|
||||
await job_queue.update_manual_job_progress(job_id, 5, "Starting extraction")
|
||||
|
||||
# Get job data
|
||||
file_bytes = await job_queue.get_job_data(job_id)
|
||||
# Get job data (must use manual-specific key prefix)
|
||||
file_bytes = await job_queue.get_manual_job_data(job_id)
|
||||
if not file_bytes:
|
||||
await job_queue.fail_manual_job(job_id, "Job data not found")
|
||||
return
|
||||
|
||||
@@ -207,10 +207,15 @@ class JobQueue:
|
||||
|
||||
async def get_job_data(self, job_id: str) -> Optional[bytes]:
|
||||
"""Get the file data for a job."""
|
||||
r = await self.get_redis()
|
||||
data_key = f"{JOB_DATA_PREFIX}{job_id}"
|
||||
return await self._get_raw_data(f"{JOB_DATA_PREFIX}{job_id}")
|
||||
|
||||
# Get raw bytes (not decoded)
|
||||
async def get_manual_job_data(self, job_id: str) -> Optional[bytes]:
|
||||
"""Get the file data for a manual extraction job."""
|
||||
return await self._get_raw_data(f"{MANUAL_JOB_DATA_PREFIX}{job_id}")
|
||||
|
||||
async def _get_raw_data(self, data_key: str) -> Optional[bytes]:
|
||||
"""Get raw binary data from Redis."""
|
||||
# Need separate connection with decode_responses=False for binary data
|
||||
raw_redis = redis.Redis(
|
||||
host=settings.redis_host,
|
||||
port=settings.redis_port,
|
||||
|
||||
Reference in New Issue
Block a user