Skip to content

Commit 63895f5

Browse files
authored
Merge pull request #5772 from David-Wu1119/unformatted-error-placeholders
Fix unformatted placeholders in secondary_y and output_type error messages
2 parents fa12456 + dd7cdd4 commit 63895f5

2 files changed

Lines changed: 3 additions & 3 deletions

File tree

‎plotly/_subplots.py‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1421,8 +1421,8 @@ def _set_trace_grid_reference(trace, layout, grid_ref, row, col, secondary_y=Fal
14211421
if secondary_y:
14221422
if len(subplot_refs) < 2:
14231423
raise ValueError(
1424-
"""
1425-
Subplot with type '{subplot_type}' at grid position ({row}, {col}) was not
1424+
f"""
1425+
Subplot with type '{subplot_refs[0].subplot_type}' at grid position ({row}, {col}) was not
14261426
created with the secondary_y spec property set to True. See the docstring
14271427
for the specs argument to plotly.subplots.make_subplots for more information.
14281428
"""

‎plotly/io/_utils.py‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ def validate_coerce_output_type(output_type):
3636
cls = go.FigureWidget
3737
else:
3838
raise ValueError(
39-
"""
39+
f"""
4040
Invalid output type: {output_type}
4141
Must be one of: 'Figure', 'FigureWidget'"""
4242
)

0 commit comments

Comments
 (0)