Bug Report: Failed dataset deletes still remove local rows and columns
维护者通常 1 天内回复
评估
调研方向
从 Traceloop SDK 中的 HTTPClient.delete、Row.delete 和 Column.delete 开始,将它们的失败检查与 Datasets.delete_by_slug 进行比较。重现模拟的 503 和 403 响应,然后更新这两项检查,使本地状态得以保留并引发错误。运行现有的 dataset 测试,并为删除 row 和 column 时的失败添加或更新有针对性的回归测试。
由索引模型根据 Issue 内容生成。
描述
Which component is this bug for?
Traceloop SDK
Description
column.delete() removes the column and its values from the local dataset even when the delete request fails. row.delete() also removes the row on failure. Neither call raises an exception.
Reproduction steps
traceloop-sdk 0.62.4, with a mocked 503 response:
from unittest.mock import patch
import requests
from traceloop.sdk.client.http import HTTPClient
from traceloop.sdk.datasets.dataset import Dataset
from traceloop.sdk.datasets.column import Column
from traceloop.sdk.datasets.row import Row
from traceloop.sdk.datasets.model import ColumnType
http = HTTPClient("https://example.invalid", "test", "repro")
dataset = Dataset(http)
dataset.slug = "evaluation"
row = Row(http, dataset, "row-1", {"question": "What is 2 + 2?"})
column = Column(http, dataset, "question", "Question", ColumnType.STRING)
dataset.rows = [row]
dataset.columns = [column]
response = requests.Response()
response.status_code = 503
response._content = b'{}'
with patch("requests.delete", return_value=response):
column.delete()
print(column.deleted, dataset.columns, row.values)
Expected behavior
Raise an error and leave the local rows, columns and values unchanged when the delete request fails.
Actual behavior
The HTTP error is logged, but column.delete() returns normally and prints:
True [] {}
The column is marked deleted and its values are gone. The same happens with a 403 response.
Python Version
3.12.14
Additional context
Also reproduced on main at 94d3f04. HTTPClient.delete returns False on failure, but Row.delete and Column.delete check for None. Datasets.delete_by_slug already checks the boolean result.
Have you spent some time to check if this bug has been raised before?
- I checked and didn't find similar issue
Are you willing to submit PR?
Yes. Can I send a PR for these two checks?
- 主要语言
- Python
- 星标
- 7.5k
- 派生
- 1.2k
- 平均合并
- 2 天 6 小时
- 30 天内合并 PR
- 2
环境准备
- 没有 Dockerfile 或 Docker Compose 文件
- 有 Pull Request 模板
- 阅读贡献指南
从这里开始
- 先读完整个 Issue,再读项目的贡献指南。
- 在 Issue 下留言说明你要接手 —— 这能避免两个人做同样的事。
- Fork 仓库,在一个分支上完成修改。
- 提交 Pull Request,并在描述里引用这个 Issue 编号。
traceloop/openllmetry 的其他 Issue
-
bug python
难度 2/5 1-3 小时 新手友好度 76/100
traceloop/openllmetry#4717 ·
维护者通常 1 天内回复
-
🐛 Bug Report: Incomplete cache token migration after #4243 breaks Bedrock and Groq instrumentation可能已有人在做 @Quantum-Enigma-dot 于 21 天前认领。 未关闭
难度 2/5 1-3 小时 新手友好度 76/100
traceloop/openllmetry#4665 · 1 条评论 ·
维护者通常 1 天内回复
-
🐛 Bug Report: OpenAI instrumentation drops gen_ai.usage.reasoning_tokens on streamed chat completions可能已有人在做 @jayfeng7 于 23 天前认领。 未关闭
难度 2/5 1-3 小时 新手友好度 82/100
traceloop/openllmetry#4660 · 1 条评论 ·
维护者通常 1 天内回复
-
🐛 Bug Report: LiteLLM instrumentation does not record seed, stop, frequency_penalty, presence_penalty可能已有人在做 @shantam77 于 38 天前认领。 未关闭
难度 2/5 1-3 小时 新手友好度 85/100
traceloop/openllmetry#4598 · 2 条评论 ·
维护者通常 1 天内回复
-
🐛 Bug Report: LiteLLM instrumentation never ends the span when a call is interrupted (KeyboardInterrupt, asyncio cancellation)可能已有人在做 @rupak-eng 于 39 天前认领。 未关闭
难度 2/5 1-3 小时 新手友好度 80/100
traceloop/openllmetry#4597 · 1 条评论 ·
维护者通常 1 天内回复
查看 traceloop/openllmetry 的全部 Issue
相似的 Issue
-
Internal Error未关闭bug
难度 2/5 1-3 小时 新手友好度 66/100
frappe/frappe_docker#2071 ·
维护者通常 1 天内回复
-
难度 2/5 1-3 小时 新手友好度 82/100
The-Pocket/PocketFlow#161 ·
-
comp/desktop P2 type/bug
难度 2/5 1-3 小时 新手友好度 78/100
NousResearch/hermes-agent#157702 ·
维护者通常 1 天内回复
-
scibench_physics / scibench_chemistry: a correct answer scores 0 when the unit has a power of ten可能已有人在做 @BahaaMattar 今天认领。 未关闭
难度 2/5 1-3 小时 新手友好度 84/100
EvolvingLMMs-Lab/lmms-eval#1699 ·
维护者通常 1 天内回复
-
project_inputs.html uses undefined file variable for dropdown IDs, lacks visual tag badges, and has empty delete labels可能已有人在做 @Rucha0901 今天认领。 未关闭
难度 2/5 1-3 小时 新手友好度 82/100
aboutcode-org/scancode.io#2354 ·
维护者通常 1 天内回复