Skip to content

Commit

Permalink
fix: pass label argument to plot through as string
Browse files Browse the repository at this point in the history
Prevents collection of columns if label argument happens to match a column name
  • Loading branch information
tomjholland committed Jan 2, 2025
1 parent 217598c commit c8fdcc5
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion pyprobe/plot.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,9 @@ def _retrieve_relevant_columns(
Returns:
A dataframe containing the relevant columns from the Result object.
"""
kwargs_values = [v for v in kwargs.values() if isinstance(v, str)]
kwargs_values = [
v for k, v in kwargs.items() if isinstance(v, str) and k != "label"
]
args_values = [v for v in args if isinstance(v, str)]
all_args = set(kwargs_values + args_values)
relevant_columns = []
Expand Down

0 comments on commit c8fdcc5

Please sign in to comment.