Skip to content

Conversation

@petetan
Copy link
Contributor

@petetan petetan commented Aug 13, 2025

This PR fixes multiple issues that were causing the AI Release Tool to fail or report misleading success messages:

Issues Fixed

1. OpenAI API Error (400): Invalid response_format

  • Problem: gpt-4o-mini model doesn't support response_format: 'json_object'
  • Solution: Only use response_format for full GPT-4 models that support it
  • Impact: AI analysis will now work with gpt-4o-mini and other compatible models

2. Git Commit Message Escaping

  • Problem: Multi-line commit messages with quotes break shell commands
  • Solution: Properly escape quotes and newlines in commit messages
  • Impact: Release branch creation will succeed with complex commit messages

3. Misleading Success Reports

  • Problem: Tool reports "✅ AI Release Tool completed successfully" even when errors occur
  • Solution: ReleaseWorkflow now properly rethrows errors instead of returning default values
  • Impact: Proper error reporting and failure detection

Testing

  • All existing tests pass
  • Build successful
  • Addresses the specific error seen in GitHub Actions

- Fix OpenAI API error: only use response_format for models that support it (not gpt-4o-mini)
- Fix commit message escaping to handle newlines and quotes in git commands
- Fix error handling in ReleaseWorkflow to properly rethrow errors instead of returning default values
- Ensures proper failure reporting when errors occur
@petetan petetan merged commit d6be578 into main Aug 13, 2025
1 check passed
@petetan petetan deleted the feature/fix-ai-and-error-handling branch August 13, 2025 17:53
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.

2 participants