Skip to content

Commit cb14b71

Browse files
jaguarliujaguarliu
authored andcommitted
release: 0.3.1 support sql server
1 parent 3001461 commit cb14b71

File tree

8 files changed

+7
-16
lines changed

8 files changed

+7
-16
lines changed

.ide/Dockerfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@ FROM python:3.13.0
33
# RUN apt-get update && apt-get install -y git
44

55
# 下载插件并设置权限,重命名后复制到系统路径
6-
RUN wget https://github.com/langgenius/dify-plugin-daemon/releases/download/0.0.6/dify-plugin-linux-amd64 -O /tmp/dify-plugin-linux-amd64 && \
6+
RUN wget https://github.com/langgenius/dify-plugin-daemon/releases/download/0.0.7/dify-plugin-linux-amd64 -O /tmp/dify-plugin-linux-amd64 && \
77
chmod +x /tmp/dify-plugin-linux-amd64 && \
88
mv /tmp/dify-plugin-linux-amd64 /usr/local/bin/dify
99

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
## rookie_text2data
22

33
**Author:** jaguarliuu
4-
**Version:** 0.3.0
4+
**Version:** 0.3.1
55
**Type:** tool
66

77
### Description

README_ZH.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
## rookie_text2data
22

33
**Author:** jaguarliuu
4-
**Version:** 0.3.0
4+
**Version:** 0.3.1
55
**Type:** tool
66

77
### Description

manifest.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
version: 0.3.0
1+
version: 0.3.1
22
type: plugin
33
author: jaguarliuu
44
name: rookie_text2data

requirements.txt

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
11
# 核心依赖
2-
dify_plugin~=0.0.1b67
2+
dify_plugin~=0.0.1b72
33
sqlalchemy>=2.0.0
44

55
# 数据库驱动
6-
# pyodbc>=4.0.39 # SQL Server新驱动
6+
pyodbc>=4.0.39 # SQL Server新驱动
77
pymysql>=1.1.1 # MySQL驱动
88
psycopg2-binary>=2.9.10 # PostgreSQL驱动
99

tools/rookie_text2data.py

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,8 @@
44
from dify_plugin import Tool
55
from dify_plugin.entities.tool import ToolInvokeMessage
66
from dify_plugin.entities.model.llm import LLMModelConfig
7-
from dify_plugin.entities.tool import ToolInvokeMessage
87
from dify_plugin.entities.model.message import SystemPromptMessage, UserPromptMessage
98
from utils.prompt_loader import PromptLoader
10-
# from utils.alchemy_db_client import format_schema_dsl
11-
# from utils.alchemy_db_client import get_db_schema
129
from database_schema.connector import get_db_schema
1310
from database_schema.formatter import format_schema_dsl
1411

utils/alchemy_db_client.py

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -219,16 +219,10 @@ def _build_connection_uri(
219219
database: str,
220220
) -> str:
221221
"""构建数据库连接字符串"""
222-
<<<<<<< HEAD
223-
separator = ':' if db_type != 'sqlserver' else ','
224-
db_type = db_type if db_type != 'sqlserver' else 'mssql'
225-
extra_info = '' if driver_info == None else f'?driver={driver_info}'
226222

227-
return f"{db_type}+{driver}://{username}:{password}@{host}{separator}{port}/{database}{extra_info}"
228-
=======
229223
db_type = db_type if db_type != 'sqlserver' else 'mssql'
230224
return f"{db_type}+{driver}://{username}:{password}@{host}:{port}/{database}"
231-
>>>>>>> debug
225+
232226

233227
def _process_result(result_proxy) -> Union[list[dict], dict, None]:
234228
"""处理执行结果"""

0 commit comments

Comments
 (0)