Skip to content

Commit 00a6f11

Browse files
Run ruff format
1 parent 2415c9b commit 00a6f11

File tree

2 files changed

+7
-3
lines changed

2 files changed

+7
-3
lines changed

plotly/matplotlylib/mpltools.py

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -495,7 +495,7 @@ def prep_ticks(ax, index, ax_type, props):
495495
else:
496496
axis_dict = dict(range=None, type="linear")
497497
warnings.warn(
498-
"Converted non-base10 {0}-axis log scale to 'linear'" "".format(ax_type)
498+
"Converted non-base10 {0}-axis log scale to 'linear'".format(ax_type)
499499
)
500500
else:
501501
return dict()
@@ -514,8 +514,10 @@ def prep_ticks(ax, index, ax_type, props):
514514

515515
if formatter == "LogFormatterMathtext":
516516
axis_dict["exponentformat"] = "e"
517-
elif formatter == "FuncFormatter" and props["axes"][index]["tickformat"] is not None:
518-
to_remove = ["dtick" "tickmode"]
517+
elif (
518+
formatter == "FuncFormatter" and props["axes"][index]["tickformat"] is not None
519+
):
520+
to_remove = ["dticktickmode"]
519521
for key in to_remove:
520522
if key in axis_dict:
521523
axis_dict.pop(key)

plotly/matplotlylib/tests/test_renderer.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22

33
from . import plt
44

5+
56
def test_non_arithmetic_progression_xtickvals():
67
xticks = [0.01, 0.53, 0.75]
78
plt.figure()
@@ -12,6 +13,7 @@ def test_non_arithmetic_progression_xtickvals():
1213

1314
assert plotly_fig.layout.xaxis.tickvals == tuple(xticks)
1415

16+
1517
def test_non_arithmetic_progression_xticktext():
1618
xtickvals = [0.01, 0.53, 0.75]
1719
xticktext = ["Baseline", "param = 1", "param = 2"]

0 commit comments

Comments
 (0)