Update pr_agent/servers/github_action_runner.py

Co-authored-by: qodo-merge-for-open-source[bot] <189517486+qodo-merge-for-open-source[bot]@users.noreply.github.com>
This commit is contained in:
Tal
2025-06-17 08:34:07 +03:00
committed by GitHub
parent f39e0a13f4
commit d4e8f618ce

View File

@ -83,6 +83,7 @@ async def run_action():
get_logger().info(f"github action: failed to apply repo settings: {e}")
# Append the response language in the extra instructions
try:
response_language = get_settings().config.get('response_language', 'en-us')
if response_language.lower() != 'en-us':
get_logger().info(f'User has set the response language to: {response_language}')
@ -103,7 +104,8 @@ async def run_action():
if extra_instructions else lang_instruction_text
)
setting.extra_instructions = updated_instructions
except Exception as e:
get_logger().info(f"github action: failed to apply language-specific instructions: {e}")
# Handle pull request opened event
if GITHUB_EVENT_NAME == "pull_request" or GITHUB_EVENT_NAME == "pull_request_target":
action = event_payload.get("action")