Skip to content

Commit

Permalink
Update linting rules in ruff.toml
Browse files Browse the repository at this point in the history
Updated linting ignore list in ruff.toml for greater code compatibility. Added error codes W191, E111, E114, E117, D206, D300, Q000, Q001, Q002, Q003, COM819, ISC002, discarded error codes D203, D213. Removed format related configurations which including quote-style, indent-style, skip-magic-trailing-comma and line-ending as they didn't comply with ruff format. This ensures that our code consistency rules are up-to-date with the ruff format guidelines while reducing potential discrepancies between local and CI/CD linting outcomes.
  • Loading branch information
nakashima-hikaru committed Nov 26, 2023
1 parent 2768567 commit 1bf4ce7
Showing 1 changed file with 15 additions and 17 deletions.
32 changes: 15 additions & 17 deletions ruff.toml
Original file line number Diff line number Diff line change
Expand Up @@ -4,11 +4,22 @@ line-length = 120
[lint]
select = ["ALL"]
ignore = [
"D203",
"D213",
# to be compatible with ruff format
"E501",
"COM812", # to be compatible with ruff format
"ISC001", # to be compatible with ruff format
"W191",
"E111",
"E114",
"E117",
"D206",
"D300",
"Q000",
"Q001",
"Q002",
"Q003",
"COM812",
"COM819",
"ISC001",
"ISC002",
]

[lint.extend-per-file-ignores]
Expand Down Expand Up @@ -36,16 +47,3 @@ strict = true

[lint.pydocstyle]
convention = "google"

[format]
# Like Black, use double quotes for strings.
quote-style = "double"

# Like Black, indent with spaces, rather than tabs.
indent-style = "space"

# Like Black, respect magic trailing commas.
skip-magic-trailing-comma = false

# Like Black, automatically detect the appropriate line ending.
line-ending = "auto"

1 comment on commit 1bf4ce7

@github-actions
Copy link

Choose a reason for hiding this comment

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

Coverage

Coverage Report
FileStmtsMissCover
TOTAL9140100%

Tests Skipped Failures Errors Time
40 0 💤 0 ❌ 0 🔥 0.735s ⏱️

Please sign in to comment.