Skip to content

Commit e2e727c

Browse files
dtsongclaude
andcommitted
fix: specify exception type and condition in comment
resolve_names() raises KeyError (not a generic error) and only validates when schema is present. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
1 parent 9507ea7 commit e2e727c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

data_diff/queries/ast_classes.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -515,7 +515,7 @@ def select(self, *exprs, **named_exprs) -> Self | ITable:
515515
named_exprs = _drop_skips_dict(named_exprs)
516516
exprs += _named_exprs_as_aliases(named_exprs)
517517
resolve_names(self.source_table, exprs)
518-
# No explicit subset check needed; resolve_names() will raise if any column name is invalid
518+
# No explicit subset check needed; resolve_names() raises KeyError for invalid column names (when schema is present)
519519
return attrs.evolve(self, columns=exprs)
520520

521521

0 commit comments

Comments
 (0)