Back to all reviewers

Python syntax consistency

microsoft/playwright
Based on 2 comments
Markdown

Ensure Python code follows proper naming conventions and syntax rules. Use snake_case for variable and parameter names instead of camelCase, and use capitalized boolean literals (True/False) instead of lowercase variants from other languages.

Naming Conventions Markdown

Reviewer Prompt

Ensure Python code follows proper naming conventions and syntax rules. Use snake_case for variable and parameter names instead of camelCase, and use capitalized boolean literals (True/False) instead of lowercase variants from other languages.

This addresses common issues when adapting code examples from other languages or when developers switch between different programming contexts. Both naming and boolean literal consistency are essential for Python code correctness and readability.

Example:

# Incorrect
context = await browser.new_context(
  isMobile=false
)

# Correct  
context = await browser.new_context(
  is_mobile=False
)
2
Comments Analyzed
Markdown
Primary Language
Naming Conventions
Category

Source Discussions