hhyo / hhyo/Archery

SQL查询--点击查询,3秒后就会弹框,终止,但是默认值应该是60秒

Open
#2,986 2 comments 0 reactions 0 assignees View on GitHub
Dominant language
Python
Stars
7k
Forks
1.9k
Avg merge
2d 11h
Merged PRs (30d)
6

Description

### 重现步骤

![Image](https://github.com/user-attachments/assets/bff04a11-8245-471f-a142-1c2f357bf39a)

### 预期外的结果

docker logs archery -f --tail=10 查看日志不及时
2025-06-10 11:21:17,378 - default - WARNING - MySQL语句执行报错,语句:select *
from tb_mall_order_universal_report
where coupon_id="202505200007300266560WY6N1FD"
limit 1;,错误信息Traceback (most recent call last):
File "/opt/archery/sql/engines/mysql.py", line 468, in query
effect_row = cursor.execute(sql, parameters)
File "/opt/venv4archery/lib/python3.9/site-packages/MySQLdb/cursors.py", line 179, in execute
res = self._query(mogrified_query)
File "/opt/venv4archery/lib/python3.9/site-packages/MySQLdb/cursors.py", line 331, in _query
self._do_get_result(db)
File "/opt/venv4archery/lib/python3.9/site-packages/MySQLdb/cursors.py", line 136, in _do_get_result
self._result = result = self._get_result()
File "/opt/venv4archery/lib/python3.9/site-packages/MySQLdb/cursors.py", line 363, in _get_result
return self._get_db().store_result()
MySQLdb.OperationalError: (3024, 'Query execution was interrupted, maximum statement execution time exceeded')
但是我检查配置都发现默认值是60秒,并且数据库确实只执行了60秒,问chatgpt发现应该是 前端 Ajax 请求超时导致弹框失败

### 日志文本

```shell

```

### 版本

1.10.0

### 部署方式

Docker

### 是否还有其他可以辅助定位问题的信息?比如数据库版本等

_No response_

Contributor guide

Open the contributing guide

Research direction

Start with the reported execution path in /opt/archery/sql/engines/mysql.py at line 468, then trace the frontend Ajax request that displays the timeout dialog. Compare the request timeout with the reported 60-second database setting and reproduce the query in Docker. Done means the dialog no longer appears after about 3 seconds while the configured 60-second limit remains effective.

Written by the indexing model from the issue text.

Assessment

Tech stack
mysql, python
Domain
databases, frontend
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.