[BUG] opensearch-sql CLI doesn't print a error return if http code is 500
@zhongnansu 已经在做这个了。
开始于 2021年11月30日。
评估
这个 Issue 还没有评估数据。
描述
Describe the bug
Some queries cause a error on server side and REST returns a message describing it followed by code 500. In this case CLI doesn't print the error.
opensearchsql> SELECT A, B FROM (SELECT `key` as A, DAYOFWEEK(date1) AS B from calcs) tmp WHERE tmp.B IN (1, 7);
KeyError('datarows')

In such cases I have to use CURL to see the message:
curl -XPOST http://localhost:9200/_plugins/_sql -H 'Content-Type: application/json' -d '{"query" : "SELECT A, B FROM (SELECT `key` as A, DAYOFWEEK(date1) AS B from calcs) tmp WHERE B IN (1, 7);"}'
{
"error": {
"reason": "There was internal problem at backend",
"details": "The following method is not supported in Schema: DAYOFWEEK",
"type": "UnsupportedOperationException"
},
"status": 500
}
The CLI interface is much more convenient for use rather than CURL, so it would be useful to keep using it to see the error message.
Additional context
Low priority
- 主要语言
- Python
- 星标
- 9
- 派生
- 24
- PR 合并指标
- 30 天内没有已合并 PR
环境准备
- 没有 Dockerfile 或 Docker Compose 文件
- 有 Pull Request 模板
- 阅读贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
opensearch-project/sql-cli 的其他 Issue
-
Mend: dependency security vulnerability
难度 2/5 1-3 小时 新手友好度 68/100
-
Mend: dependency security vulnerability
难度 2/5 1-3 小时 新手友好度 58/100
-
Mend: dependency security vulnerability
难度 2/5 1-3 小时 新手友好度 58/100
-
难度 5/5 一周以上 新手友好度 20/100
opensearch-project/sql-cli#59 · 1 条评论 · 1 个 reaction ·
-
Update version on PyPi可能重新可做 @zhongnansu 于 189 天前认领,目前没有进行中的 PR。 未关闭documentation enhancement
opensearch-project/sql-cli#45 · 3 条评论 · 已指派 1 人 ·
查看 opensearch-project/sql-cli 的全部 Issue
相似的 Issue
-
难度 1/5 1-3 小时 新手友好度 88/100
gradio-app/gradio#13964 ·
维护者通常 1 天内回复
-
难度 1/5 1 小时以内 新手友好度 93/100
BSData/horus-heresy-3rd-edition#3232 · 1 条评论 ·
维护者通常 1 天内回复
-
bug
难度 2/5 1-3 小时 新手友好度 78/100
jbacalso24/mimry#123 ·
维护者通常 1 天内回复
-
p:3-mid pydanty:bug pydanty:is-working
难度 2/5 1-3 小时 新手友好度 76/100
pydantic/pydantic-ai#10153 · 1 条评论 ·
维护者通常 1 天内回复
-
good first issue priority: medium size: S testing
难度 2/5 1-3 小时 新手友好度 85/100
cubrid-lab/cubrid-cookbook-python#316 ·
维护者通常 1 天内回复