box / box/box-python-sdk

Log failed Preflight check at INFO level

未关闭
#527 1 条评论 0 个 reaction 已指派 0 人 在 GitHub 查看
enhancement
主要语言
Python
星标
459
派生
223
平均合并
8 小时 57 分钟
30 天内合并 PR
13

描述

### Is your feature request related to a problem? Please describe.
I don't think the preflight check, which throws a 409 when a file exists, should be logging a WARNING in the logs.

### Describe the solution you'd like
I think Preflight in particular should log with INFO level. Although I can understand the decision for Preflight to throw a 409, in this case I am calling it specifically to ask "can I overwrite this file?" So the response, whatever it is, shouldn't be a WARNING for my application.

Put another way: If the Preflight just throws a 409 and logs a warning, I don't see how that is different to simply calling folder.upload() and letting it throw the exception. Aren't I just wasting an API call?

### Describe alternatives you've considered
I really don't want to set the SDK log level to ERROR and above, but that is the only option I think?

贡献指南

打开贡献指南

调研方向

首先定位 Python SDK 中的 Preflight 实现和警告日志。检查针对失败 Preflight 检查的现有测试,然后验证仍会返回 409 响应,同时相应的日志条目使用 INFO 而不是 WARNING。

由索引模型根据 Issue 内容生成。

评估

技术栈
python
领域
api
Issue 类型
功能
难度
3/5
预计耗时
1-2 天
活跃度
停滞
描述清晰度
基本清楚
新手友好度
42/100

把新 issue 发到你的邮箱

精选适合新手参与的 GitHub issue 摘要。