update main

This commit is contained in:
Hossein 2025-11-30 18:50:27 +03:30
parent 111aa883e4
commit 7cc20f555c

View File

@ -389,7 +389,7 @@ SECOND image = outfit_photo (outfit reference).
cand = response.candidates[0]
finish_reason = getattr(cand, "finish_reason", None)
print(f"[DEBUG] Finish reason: {finish_reason}")
print(f"[DEBUG] Safety ratings: {getattr(cand, "safety_ratings", None)}")
print(f"[DEBUG] Safety ratings: {getattr(cand, 'safety_ratings', None)}")
if hasattr(cand, "content") and getattr(cand.content, "parts", None):
print(f"[DEBUG] Parts in first candidate ({len(cand.content.parts)} total):")
@ -436,7 +436,7 @@ SECOND image = outfit_photo (outfit reference).
safety_ratings = cand.safety_ratings
if safety_ratings:
blocked = [
f"{getattr(r, "category", "unknown")}"
f"{getattr(r, 'category', 'unknown')}"
for r in safety_ratings
if hasattr(r, "blocked") and getattr(r, "blocked", False)
]