Skip to content

Fix chat template quit handling#1449

Open
pragnyanramtha wants to merge 1 commit into
simonw:mainfrom
pragnyanramtha:codex/chat-template-quit
Open

Fix chat template quit handling#1449
pragnyanramtha wants to merge 1 commit into
simonw:mainfrom
pragnyanramtha:codex/chat-template-quit

Conversation

@pragnyanramtha
Copy link
Copy Markdown

Summary

  • Check exit / quit chat commands before applying a prompt template
  • Prevent templates with a prompt: value from turning quit into a model prompt
  • Add a regression covering llm chat -t with a template prompt

Fixes #1336.

Validation

  • uv run pytest tests/test_chat_templates.py -q
  • uv run pytest tests/test_chat.py tests/test_chat_templates.py -q
  • uv run ruff check llm/cli.py tests/test_chat_templates.py
  • uv run black --check --target-version py313 llm/cli.py tests/test_chat_templates.py
  • git diff --check

@pragnyanramtha pragnyanramtha marked this pull request as ready for review May 17, 2026 04:16
Copilot AI review requested due to automatic review settings May 17, 2026 04:16
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

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

Copilot encountered an error and was unable to review this pull request. You can try again by re-requesting a review.

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.

chat with template is broken (wrong model, multiline doesn't work)

2 participants