Skip to content

Conversation

cadedaniel
Copy link
Collaborator

There are many lint failures which makes new ones easy to miss. This PR makes the linter by default only check changed files using the same logic as used for yapf.

Testing

$ ./format.sh --files vllm/block.py
vLLM yapf: Done
vLLM Pylint:

------------------------------------
Your code has been rated at 10.00/10
$ echo '# long line------------------------------------------------------------------------' >> vllm/block.py
$ ./format.sh
vLLM yapf: Done
vLLM Pylint:
************* Module vllm.block
vllm/block.py:71:0: C0301: Line too long (83/80) (line-too-long)

-----------------------------------
Your code has been rated at 9.70/10
$ ./format.sh --all
vLLM yapf: Done
vLLM Pylint:
************* Module vllm.model_executor.models.internlm
vllm/model_executor/models/internlm.py:265:24: E1136: Value 'state_dict' is unsubscriptable (unsubscriptable-object)
vllm/model_executor/models/internlm.py:275:24: E1136: Value 'state_dict' is unsubscriptable (unsubscriptable-object)
vllm/model_executor/models/internlm.py:293:24: E1136: Value 'state_dict' is unsubscriptable (unsubscriptable-object)
vllm/model_executor/models/internlm.py:307:20: E1136: Value 'state_dict' is unsubscriptable (unsubscriptable-object)
************* Module vllm.model_executor.models.qwen
vllm/model_executor/models/qwen.py:296:24: E1136: Value 'state_dict' is unsubscriptable (unsubscriptable-object)
vllm/model_executor/models/qwen.py:309:20: E1136: Value 'state_dict' is unsubscriptable (unsubscriptable-object)
[rest omitted]

Copy link
Collaborator

@Yard1 Yard1 left a comment

Choose a reason for hiding this comment

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

LGTM!

Copy link
Member

@zhuohan123 zhuohan123 left a comment

Choose a reason for hiding this comment

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

LGTM! Thanks for your contribution!

@zhuohan123 zhuohan123 merged commit e575df3 into vllm-project:main Oct 31, 2023
hongxiayang pushed a commit to hongxiayang/vllm that referenced this pull request Feb 13, 2024
inkcherry pushed a commit to inkcherry/vllm that referenced this pull request Aug 11, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants