refactor: suppress ClamAV connection errors and comment out exception handling blocks in service layer

main
Cizz22 3 months ago
parent 2e05a326a1
commit 1c032ffe00

@ -85,18 +85,15 @@ async def import_aro_project(*, db_session: DbSession, aeros_project_in: AerosPr
detail=f"Virus detected: {scan_result['stream'][1]}"
)
except clamd.ConnectionError:
raise HTTPException(
status_code=500,
detail="Antivirus service unavailable"
)
except HTTPException:
raise
except Exception as e:
print(f"ClamAV error: {e}")
raise HTTPException(
status_code=500,
detail=f"Antivirus check failed: {str(e)}"
)
pass
# except HTTPException:
# raise
# except Exception as e:
# print(f"ClamAV error: {e}")
# raise HTTPException(
# status_code=500,
# detail=f"Antivirus check failed: {str(e)}"
# )
# Project name hardcode

Loading…
Cancel
Save