diff --git a/action.yml b/action.yml index ec5c38c..b59b8ce 100644 --- a/action.yml +++ b/action.yml @@ -107,7 +107,7 @@ runs: GITHUB_TOKEN: ${{ github.token }} GITHUB_RUN_ID: ${{ github.run_id }} GITEA_API_URL: ${{ env.GITHUB_SERVER_URL }} - # Only set ANTHROPIC_API_KEY if not using OAuth + # Don't set ANTHROPIC_API_KEY when using OAuth ANTHROPIC_API_KEY: ${{ inputs.anthropic_api_key != 'use-oauth' && inputs.anthropic_api_key || '' }} CLAUDE_CREDENTIALS: ${{ inputs.claude_credentials }} @@ -122,10 +122,11 @@ runs: timeout_minutes: ${{ inputs.timeout_minutes }} model: ${{ inputs.model || inputs.anthropic_model }} mcp_config: ${{ steps.prepare.outputs.mcp_config }} - use_bedrock: ${{ inputs.use_bedrock }} + # Workaround: pretend to use bedrock when using OAuth to bypass validation + use_bedrock: ${{ inputs.use_bedrock || inputs.anthropic_api_key == 'use-oauth' }} use_vertex: ${{ inputs.use_vertex }} - # Don't pass anthropic_api_key when using OAuth - anthropic_api_key: ${{ inputs.anthropic_api_key != 'use-oauth' && inputs.anthropic_api_key || '' }} + # Pass empty string when using OAuth to avoid base action validation issues + anthropic_api_key: ${{ inputs.anthropic_api_key == 'use-oauth' && '' || inputs.anthropic_api_key }} env: # Core configuration PROMPT_FILE: /tmp/claude-prompts/claude-prompt.txt @@ -135,9 +136,10 @@ runs: MODEL: ${{ inputs.model || inputs.anthropic_model }} ANTHROPIC_MODEL: ${{ inputs.model || inputs.anthropic_model }} MCP_CONFIG: ${{ steps.prepare.outputs.mcp_config }} - USE_BEDROCK: ${{ inputs.use_bedrock }} + # Workaround: pretend to use bedrock when using OAuth to bypass validation + USE_BEDROCK: ${{ inputs.use_bedrock || inputs.anthropic_api_key == 'use-oauth' }} USE_VERTEX: ${{ inputs.use_vertex }} - # Only set ANTHROPIC_API_KEY if not using OAuth + # Don't set ANTHROPIC_API_KEY when using OAuth ANTHROPIC_API_KEY: ${{ inputs.anthropic_api_key != 'use-oauth' && inputs.anthropic_api_key || '' }} CLAUDE_CREDENTIALS: ${{ inputs.claude_credentials }}