Skip to content

Commit 4e73e5f

Browse files
committed
enable RUF and UP
1 parent 3f6d88a commit 4e73e5f

File tree

2 files changed

+6
-2
lines changed

2 files changed

+6
-2
lines changed

chispa/__init__.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,9 @@
1717
sys.path.append(os.path.join(spark_home, "python"))
1818
py4j_src_zip = glob(os.path.join(spark_home, "python", "lib", "py4j-*-src.zip"))
1919
if len(py4j_src_zip) == 0:
20-
raise ValueError("py4j source archive not found in %s" % os.path.join(spark_home, "python", "lib"))
20+
raise ValueError(
21+
"py4j source archive not found in {}".format(os.path.join(spark_home, "python", "lib"))
22+
)
2123
else:
2224
py4j_src_zip = sorted(py4j_src_zip)[::-1]
2325
sys.path.append(py4j_src_zip[0])

pyproject.toml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -68,10 +68,12 @@ fix = true
6868
preview = true
6969

7070
[tool.ruff.lint]
71-
select = ["E", "F", "I"]
71+
select = ["E", "F", "I", "RUF", "UP"]
7272
ignore = [
7373
# Line too long
7474
"E501",
75+
# Mutable class attributes
76+
"RUF012"
7577
]
7678

7779
[tool.ruff.lint.flake8-type-checking]

0 commit comments

Comments
 (0)