Skip to content

[#26] Gemini structured output mimeType 값을 실제 API 요구사항에 맞춘다#27

Merged
opficdev merged 2 commits into
developfrom
fix/#26-gemini-mimeType
Jun 22, 2026
Merged

[#26] Gemini structured output mimeType 값을 실제 API 요구사항에 맞춘다#27
opficdev merged 2 commits into
developfrom
fix/#26-gemini-mimeType

Conversation

@opficdev

Copy link
Copy Markdown
Owner

🔗 연관된 이슈

🎯 의도

  • Gemini structured output 요청에서 실제 API가 요구하는 mimeType enum 값을 사용해 AI prediction 호출 실패를 해결하기 위한 수정

📝 작업 내용

📌 요약

  • Gemini request body의 mimeType 값을 APPLICATION_JSON으로 변경
  • Gemini request payload 테스트 기대값 수정
  • 중복된 Gemini client 성공 경로 테스트 제거

🔍 상세

  • src/ai/geminiPredictionClient.ts에서 generationConfig.responseFormat.text.mimeType 값을 "application/json"에서 "APPLICATION_JSON"으로 변경
  • tests/ai/geminiPredictionClient.test.ts에서 request payload 검증 값을 "APPLICATION_JSON"으로 변경
  • createDefaultAiPredictionClient 성공 경로와 중복되던 parses Gemini JSON text response 테스트 제거
  • 실제 Gemini error body에서 확인된 generation_config.response_format.text.mime_type invalid argument 원인 반영

📸 영상 / 이미지 (Optional)

@opficdev opficdev self-assigned this Jun 22, 2026
@opficdev opficdev force-pushed the fix/#26-gemini-mimeType branch from 1ffab7e to 5250b59 Compare June 22, 2026 15:21

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request updates the Gemini prediction client to use 'APPLICATION_JSON' instead of 'application/json' as the mimeType in the generation configuration, and updates the corresponding test assertions while removing the 'parses Gemini JSON text response' test. There are no review comments, and I have no additional feedback to provide.

Important

The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.

@opficdev opficdev merged commit ec4f35f into develop Jun 22, 2026
3 checks passed
@opficdev opficdev deleted the fix/#26-gemini-mimeType branch June 22, 2026 15:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Gemini structured output mimeType 값을 실제 API 요구사항에 맞춘다

1 participant