Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[CodeStyle][ruff] add new rule T100 #60243

Merged
merged 2 commits into from
Dec 22, 2023
Merged

Conversation

gouzil
Copy link
Member

@gouzil gouzil commented Dec 21, 2023

PR types

Others

PR changes

Others

Description

检查pdb,breakpoint()等 Debugger 相关函数和 api

Copy link

paddle-bot bot commented Dec 21, 2023

你的PR提交成功,感谢你对开源项目的贡献!
请关注后续CI自动化测试结果,详情请参考Paddle-CI手册
Your PR has been submitted. Thanks for your contribution!
Please wait for the result of CI firstly. See Paddle CI Manual for details.

@paddle-bot paddle-bot bot added the contributor External developers label Dec 21, 2023
@gouzil gouzil requested a review from SigureMo December 21, 2023 15:46
@@ -556,7 +556,7 @@ def step(self, instr: Instruction):
):
BreakpointManager().locate(self)
print(log_message)
breakpoint() # breakpoint for debug
breakpoint() # noqa: T100 # breakpoint for debug
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

注释直接删掉就好

@@ -18,7 +18,7 @@
import inspect
import logging
import os
import pdb
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

import 都扫出来了?这检查是不是过于严格了,我感觉只有 FunctionCall 才应该被检测出来吧……

Copy link
Member

@SigureMo SigureMo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTMeow

@SigureMo SigureMo changed the title [CodeStyle][ruff] add select T100 [CodeStyle][ruff] add new rule T100 Dec 21, 2023
@luotao1 luotao1 added the HappyOpenSource 快乐开源活动issue与PR label Dec 22, 2023
@luotao1 luotao1 merged commit 5dc39b4 into PaddlePaddle:develop Dec 22, 2023
29 checks passed
@gouzil gouzil deleted the ruff_add_T100 branch December 27, 2023 02:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
contributor External developers HappyOpenSource 快乐开源活动issue与PR
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants