File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -156,6 +156,7 @@ for REGION in "${REGIONS[@]}"; do
156156 continue
157157 fi
158158
159+ IMAGE_MODEL_AVAILABLE=false
159160 AT_LEAST_ONE_MODEL_AVAILABLE=false
160161 TEMP_TABLE_ROWS=()
161162
@@ -199,6 +200,9 @@ for REGION in "${REGIONS[@]}"; do
199200
200201 if [ " $AVAILABLE " -ge " $REQUIRED_CAPACITY " ]; then
201202 FOUND=true
203+ if [ " $MODEL_NAME " = " gpt-image-1" ]; then
204+ IMAGE_MODEL_AVAILABLE=true
205+ fi
202206 AT_LEAST_ONE_MODEL_AVAILABLE=true
203207 TEMP_TABLE_ROWS+=(" $( printf " | %-4s | %-20s | %-43s | %-10s | %-10s | %-10s |" " $INDEX " " $REGION " " $MODEL_TYPE " " $LIMIT " " $CURRENT_VALUE " " $AVAILABLE " ) " )
204208 else
@@ -215,8 +219,7 @@ for REGION in "${REGIONS[@]}"; do
215219 done
216220 done
217221
218- # For content-gen, we only need GPT-5.1, so check if at least one model is available
219- if [ " $AT_LEAST_ONE_MODEL_AVAILABLE " = true ] && [ " $INSUFFICIENT_QUOTA " = false ] && [ " $FOUND " = true ]; then
222+ if { [ " $IS_USER_PROVIDED_PAIRS " = true ] && [ " $INSUFFICIENT_QUOTA " = false ] && [ " $FOUND " = true ]; } || { [ " $IMAGE_MODEL_AVAILABLE " = true ] && { [ " $APPLY_OR_CONDITION " != true ] || [ " $AT_LEAST_ONE_MODEL_AVAILABLE " = true ]; }; }; then
220223 VALID_REGIONS+=(" $REGION " )
221224 TABLE_ROWS+=(" ${TEMP_TABLE_ROWS[@]} " )
222225 INDEX=$(( INDEX + 1 ))
Original file line number Diff line number Diff line change @@ -1580,7 +1580,8 @@ async def generate_content(
15801580 for v in results ["violations" ]
15811581 )
15821582 except (json .JSONDecodeError , KeyError ):
1583- pass
1583+ # Failed to parse compliance response JSON; violations will remain empty
1584+ logger .debug ("Could not parse compliance violations from response" , exc_info = True )
15841585
15851586 except Exception as e :
15861587 logger .exception (f"Error generating content: { e } " )
You can’t perform that action at this time.
0 commit comments