Skip to content

feat: supports time_zone and show,tql eval etc. #16

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 8 commits into from
May 29, 2025

Conversation

killme2008
Copy link
Contributor

@killme2008 killme2008 commented May 28, 2025

@killme2008 killme2008 marked this pull request as draft May 28, 2025 23:00
@killme2008 killme2008 marked this pull request as ready for review May 29, 2025 06:28
@killme2008 killme2008 requested review from sunng87, Copilot and evenyag May 29, 2025 06:28
Copy link
Contributor

@Copilot 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.

Pull Request Overview

This PR adds support for a new configuration option (time_zone) and extends SQL tool functionalities to include queries like SHOW DATABASES, TQL, DESC TABLE, and EXPLAIN.

  • Adds time_zone handling to configuration and server connections.
  • Introduces new tests for SHOW DATABASES queries and validates time_zone settings from different sources.
  • Updates the DatabaseServer's call_tool method to handle additional SQL commands and adjusts configuration parsing.

Reviewed Changes

Copilot reviewed 5 out of 5 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
tests/test_server.py Adds time_zone support and a new test for SHOW DATABASES queries.
tests/test_config.py Adds tests asserting time_zone values from defaults, env vars, and CLI args.
src/greptimedb_mcp_server/server.py Updates the server to include time_zone in connections and enhances query handling.
src/greptimedb_mcp_server/config.py Introduces the time_zone property and CLI argument.
conftest.py Adds mocked responses for SHOW DATABASES but contains a duplicate condition issue.

@killme2008 killme2008 requested a review from JetSquirrel May 29, 2025 06:53
@sunng87 sunng87 merged commit b9a028d into main May 29, 2025
1 check passed
@sunng87 sunng87 deleted the feature/support-timezone branch May 29, 2025 08:25
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