You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
-1Lines changed: 0 additions & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -238,4 +238,3 @@ tag.
238
238
*[TensorFlow Data Validation PyPI](https://pypi.org/project/tensorflow-data-validation/)
239
239
*[TensorFlow Data Validation Paper](https://mlsys.org/Conferences/2019/doc/2019/167.pdf)
240
240
*[TensorFlow Data Validation Slides](https://conf.slac.stanford.edu/xldb2018/sites/xldb2018.conf.slac.stanford.edu/files/Tues_09.45_NeoklisPolyzotis_Data%20Analysis%20and%20Validation%20(1).pdf)
Copy file name to clipboardExpand all lines: pyproject.toml
+127Lines changed: 127 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -19,3 +19,130 @@ requires = [
19
19
# Required for using org_tensorflow bazel repository.
20
20
"numpy~=1.22.0",
21
21
]
22
+
23
+
[tool.ruff]
24
+
line-length = 88
25
+
26
+
[tool.ruff.lint]
27
+
select = [
28
+
# pycodestyle
29
+
"E",
30
+
"W",
31
+
# Pyflakes
32
+
"F",
33
+
# pyupgrade
34
+
"UP",
35
+
# flake8-bugbear
36
+
"B",
37
+
# flake8-simplify
38
+
"SIM",
39
+
# isort
40
+
"I",
41
+
# pep8 naming
42
+
"N",
43
+
# pydocstyle
44
+
"D",
45
+
# annotations
46
+
"ANN",
47
+
# debugger
48
+
"T10",
49
+
# flake8-pytest
50
+
"PT",
51
+
# flake8-return
52
+
"RET",
53
+
# flake8-unused-arguments
54
+
"ARG",
55
+
# flake8-fixme
56
+
"FIX",
57
+
# flake8-eradicate
58
+
"ERA",
59
+
# pandas-vet
60
+
"PD",
61
+
# numpy-specific rules
62
+
"NPY",
63
+
]
64
+
65
+
ignore = [
66
+
"D104", # Missing docstring in public package
67
+
"D100", # Missing docstring in public module
68
+
"D211", # No blank line before class
69
+
"PD901", # Avoid using 'df' for pandas dataframes. Perfectly fine in functions with limited scope
70
+
"ANN201", # Missing return type annotation for public function (makes no sense for NoneType return types...)
71
+
"ANN101", # Missing type annotation for `self`
72
+
"ANN204", # Missing return type annotation for special method
73
+
"ANN002", # Missing type annotation for `*args`
74
+
"ANN003", # Missing type annotation for `**kwargs`
75
+
"D105", # Missing docstring in magic method
76
+
"D203", # 1 blank line before after class docstring
77
+
"D204", # 1 blank line required after class docstring
78
+
"D413", # 1 blank line after parameters
79
+
"SIM108", # Simplify if/else to one line; not always clearer
80
+
"D206", # Docstrings should be indented with spaces; unnecessary when running ruff-format
81
+
"E501", # Line length too long; unnecessary when running ruff-format
82
+
"W191", # Indentation contains tabs; unnecessary when running ruff-format
83
+
84
+
# REMOVE AFTER FIXING
85
+
# ANN rules (flake8-annotations)
86
+
"ANN001", # Missing type annotation for function argument `args`
87
+
"ANN102", # Missing type annotation for `cls` in classmethod
88
+
"ANN202", # Missing Missing return type annotation for private function
89
+
"ANN205", # Missing return type annotation for staticmethod
90
+
"ANN206", # Missing return type annotation for classmethod
91
+
"ANN401", # Dynamically typed expressions (typing.Any) are disallowed in `domain`
92
+
# ARG rules (flake8-unused-arguments)
93
+
"ARG001", # Unused function argument
94
+
"ARG002", # Unused method argument
95
+
# B rules (flake8-bugbear)
96
+
"B005", # Using `.strip()` with multi-character strings is misleading
97
+
"B007", # Loop control variable not used within loop body
98
+
"B008", # Do not perform function call in argument defaults; instead, perform the call within the function, or read the default from a module-level singleton variable
99
+
"B904", # Within an `except` clause, raise exceptions with `raise ... from err` or `raise ... from None` to distinguish them from errors in exception handling
100
+
# D rules (pydocstyle)
101
+
"D101", # Missing docstring in public class
102
+
"D102", # Missing docstring in public method
103
+
"D103", # Missing docstring in public function
104
+
"D107", # Missing docstring in `__init__`,
105
+
"D401", # First line of docstring should be in imperative mood: "Loads the vocabulary from the specified path."
106
+
"D404", # First word of the docstring should not be "This"
107
+
"D417", # Missing argument descriptions in the docstring
108
+
# E rules (pycodestyle)
109
+
"E731", # Do not assign a `lambda` expression, use a `def`
110
+
"E741", # Ambiguous variable name
111
+
# ERA rules (flake8-eradicate)
112
+
"ERA001", # Found commented-out code
113
+
# F rules (Pyflakes)
114
+
"F821", # Undefined name
115
+
# FIX rules (flake8-fixme)
116
+
"FIX002", # Line contains TODO, consider resolving the issue
117
+
# N rules (pep8-naming)
118
+
"N802", # Function name should be lowercase,
119
+
# NPY rules (numpy-specific rules)
120
+
"NPY002", # Replace legacy
121
+
# PD rules (pandas-vet)
122
+
"PD002", # `inplace=True` should be avoided; it has inconsistent behavior
123
+
"PD003", # `.isna` is preferred to `.isnull`; functionality is equivalent
124
+
"PD011", # Use `.to_numpy()` instead of `.values`
125
+
"PD015", # Use `.merge` method instead of `pd.merge` function
126
+
# PT rules (flake8-pytest-style)
127
+
"PT009", # Use a regular `assert` instead of unittest-style `assertEqual`
128
+
"PT018", # Assertion should be broken down into multiple parts
129
+
"PT027", # Use `pytest.raises` instead of unittest-style `assertRaisesRegex`
130
+
# RET rules (flake8-return)
131
+
"RET504", # Unnecessary assignment to variable before `return` statement
132
+
"RET505", # Unnecessary `elif` after `return` statement
133
+
# SIM rules (flake8-simplify)
134
+
"SIM101", # Multiple `isinstance` calls for `maybe_collection`, merge into a single call
135
+
"SIM102", # Use a single `if` statement instead of nested `if` statements
136
+
"SIM103", # Return the condition directly
137
+
"SIM105", # Use `contextlib.suppress(...)` instead of `try`-`except`-`pass`
138
+
"SIM117", # Use a single `with` statement with multiple contexts instead of nested `with` statements
139
+
"SIM211", # Use `not ...` instead of `False if ... else True`
140
+
# UP rules (pyupgrade)
141
+
"UP008", # Use `super()` instead of `super(__class__, self)`
142
+
"UP028", # Replace `yield` over `for` loop with `yield from`
143
+
"UP031", # Use format specifiers instead of percent format
0 commit comments