Skip to content

Commit 10906ab

Browse files
natmokvalnoatamir
authored andcommitted
enable pylint: consider-using-sys-exit (pandas-dev#49480)
1 parent 59f58e4 commit 10906ab

File tree

2 files changed

+2
-3
lines changed

2 files changed

+2
-3
lines changed

pandas/tests/io/generate_legacy_storage_files.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -327,7 +327,7 @@ def write_legacy_file():
327327
sys.path.insert(0, ".")
328328

329329
if not 3 <= len(sys.argv) <= 4:
330-
exit(
330+
sys.exit(
331331
"Specify output directory and storage type: generate_legacy_"
332332
"storage_files.py <output_dir> <storage_type> "
333333
)
@@ -338,7 +338,7 @@ def write_legacy_file():
338338
if storage_type == "pickle":
339339
write_legacy_pickles(output_dir=output_dir)
340340
else:
341-
exit("storage_type must be one of {'pickle'}")
341+
sys.exit("storage_type must be one of {'pickle'}")
342342

343343

344344
if __name__ == "__main__":

pyproject.toml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -106,7 +106,6 @@ disable = [
106106
"comparison-with-itself",
107107
"consider-merging-isinstance",
108108
"consider-using-min-builtin",
109-
"consider-using-sys-exit",
110109
"consider-using-ternary",
111110
"consider-using-with",
112111
"cyclic-import",

0 commit comments

Comments
 (0)