Skip to content

Commit 6ae49cc

Browse files
Copilotborchero
andauthored
docs: Clarify FailureInfo write methods include rule columns (#219)
Co-authored-by: copilot-swe-agent[bot] <198982749+Copilot@users.noreply.github.com> Co-authored-by: borchero <22455425+borchero@users.noreply.github.com>
1 parent 3a6a94b commit 6ae49cc

File tree

1 file changed

+14
-2
lines changed

1 file changed

+14
-2
lines changed

dataframely/filter_result.py

Lines changed: 14 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -143,7 +143,11 @@ def __len__(self) -> int:
143143
# ---------------------------------- PERSISTENCE --------------------------------- #
144144

145145
def write_parquet(self, file: str | Path | IO[bytes], **kwargs: Any) -> None:
146-
"""Write the failure info to a parquet file.
146+
"""Write the failure info to a single parquet file.
147+
148+
Writes the invalid rows along with additional boolean rule columns indicating
149+
which validation rules failed. Unlike :meth:`invalid`, this includes columns
150+
for each rule, where ``False`` indicates the rule failed for that row.
147151
148152
Args:
149153
file: The file path or writable file-like object to which to write the
@@ -162,7 +166,11 @@ def write_parquet(self, file: str | Path | IO[bytes], **kwargs: Any) -> None:
162166
def sink_parquet(
163167
self, file: str | Path | IO[bytes] | PartitioningScheme, **kwargs: Any
164168
) -> None:
165-
"""Stream the failure info to a parquet file.
169+
"""Stream the failure info to a single parquet file.
170+
171+
Writes the invalid rows along with additional boolean rule columns indicating
172+
which validation rules failed. Unlike :meth:`invalid`, this includes columns
173+
for each rule, where ``False`` indicates the rule failed for that row.
166174
167175
Args:
168176
file: The file path or writable file-like object to which to write the
@@ -234,6 +242,10 @@ def write_delta(
234242
) -> None:
235243
"""Write the failure info to a delta lake table.
236244
245+
Writes the invalid rows along with additional boolean rule columns indicating
246+
which validation rules failed. Unlike :meth:`invalid`, this includes columns
247+
for each rule, where ``False`` indicates the rule failed for that row.
248+
237249
Args:
238250
target: The file path or DeltaTable to which to write the delta lake data.
239251
kwargs: Additional keyword arguments passed directly to

0 commit comments

Comments
 (0)