imbajin commented on code in PR #313:
URL:
https://github.com/apache/incubator-hugegraph-ai/pull/313#discussion_r2566999378
##########
pyproject.toml:
##########
@@ -43,6 +43,9 @@ dev = [
"pytest~=8.0.0",
"pytest-cov~=5.0.0",
"pylint~=3.0.0",
+ "ruff>=0.5.0",
+ "mypy>=1.16.1",
Review Comment:
⚠️ **mypy 配置缺失**
添加了 mypy 依赖但未看到 `[tool.mypy]` 配置。建议添加基础配置:
```toml
[tool.mypy]
python_version = "3.10"
warn_return_any = true
warn_unused_configs = true
ignore_missing_imports = true # 对于部分缺少 stubs 的依赖
```
或者如果 mypy 暂不启用,可以在 README 或 PR 描述中说明这是为后续准备的。
##########
vermeer-python-client/src/pyvermeer/demo/task_demo.py:
##########
@@ -27,27 +27,23 @@ def main():
token="",
log_level="DEBUG",
)
- task = client.tasks.get_tasks()
+ client.tasks.get_tasks()
Review Comment:
🧹 **代码变更:移除未使用的变量**
这里将 `task = ...` 改为直接调用 `client.tasks.get_tasks()`,移除了未使用的变量。这是 ruff 的 F841
规则检测出来的,修复正确。
不过作为示例代码,原本的写法可能是为了展示如何使用返回值。如果这是 demo 文件,建议保留变量并使用它(或者添加注释说明)。
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]