Skip to content

Commit 6727dd1

Browse files
committed
pyupgrade
1 parent 5cd3242 commit 6727dd1

File tree

3 files changed

+4
-4
lines changed

3 files changed

+4
-4
lines changed

src/tikzplotlib/_axes.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -80,12 +80,12 @@ def __init__(self, data, obj): # noqa: C901
8080
if obj.get_xscale() == "log":
8181
self.axis_options.append("xmode=log")
8282
self.axis_options.append(
83-
"log basis x={{{}}}".format(_try_f2i(obj.xaxis._scale.base))
83+
f"log basis x={{{_try_f2i(obj.xaxis._scale.base)}}}"
8484
)
8585
if obj.get_yscale() == "log":
8686
self.axis_options.append("ymode=log")
8787
self.axis_options.append(
88-
"log basis y={{{}}}".format(_try_f2i(obj.yaxis._scale.base))
88+
f"log basis y={{{_try_f2i(obj.yaxis._scale.base)}}}"
8989
)
9090

9191
# Possible values for get_axisbelow():

src/tikzplotlib/_cleanfigure.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -584,7 +584,7 @@ def _get_collection_data(collection):
584584
if is3D:
585585
# https://stackoverflow.com/questions/51716696/extracting-data-from-a-3d-scatter-plot-in-matplotlib
586586
offsets = collection._offsets3d
587-
xData, yData, zData = [o.data for o in offsets]
587+
xData, yData, zData = (o.data for o in offsets)
588588
data = _stack_data_3D(xData, yData, zData)
589589
else:
590590
offsets = collection.get_offsets()

src/tikzplotlib/_save.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -384,7 +384,7 @@ def _recurse(data, obj):
384384
pass
385385
else:
386386
warnings.warn(
387-
"tikzplotlib: Don't know how to handle object {}.".format(type(child))
387+
f"tikzplotlib: Don't know how to handle object {type(child)}."
388388
)
389389
return data, content.flatten()
390390

0 commit comments

Comments
 (0)