Skip to content

Commit 5f0fa10

Browse files
committed
Format with ruff
1 parent f4ad466 commit 5f0fa10

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

54 files changed

+74
-157
lines changed

conftest.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
# SPDX-FileCopyrightText: Blair Bonnett
22
# SPDX-License-Identifier: BSD-3-Clause
33

4+
45
def pytest_itemcollected(item):
56
"""Use the test docstring (if available) as the node ID.
67

data/share/matplotlib-pgfutils/examples/threecol/double.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,13 +3,11 @@
33

44
from pgfutils import save, setup_figure
55

6-
76
setup_figure(width=1, height=0.4, columns=2)
87

98
from matplotlib import pyplot as plt
109
import numpy as np
1110

12-
1311
t = np.linspace(0, 10, 400)
1412
s = 0.3 * t + 2.5 * np.cos(2 * np.pi * 0.85 * t) - 0.8
1513

data/share/matplotlib-pgfutils/examples/threecol/single.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,13 +3,11 @@
33

44
from pgfutils import save, setup_figure
55

6-
76
setup_figure(width=1, height=0.4, columns=1)
87

98
from matplotlib import pyplot as plt
109
import numpy as np
1110

12-
1311
t = np.linspace(0, 10, 200)
1412
s = 0.3 * t + 2.5 * np.cos(2 * np.pi * 0.85 * t) - 0.8
1513

data/share/matplotlib-pgfutils/examples/threecol/triple.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,13 +3,11 @@
33

44
from pgfutils import save, setup_figure
55

6-
76
setup_figure(width=1, height=0.4, columns=3)
87

98
from matplotlib import pyplot as plt
109
import numpy as np
1110

12-
1311
t = np.linspace(0, 10, 400)
1412
s = 0.3 * t + 2.5 * np.cos(2 * np.pi * 0.85 * t) - 0.8
1513

data/share/matplotlib-pgfutils/examples/twocol/double.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,13 +3,11 @@
33

44
from pgfutils import save, setup_figure
55

6-
76
setup_figure(width=1, height=0.4, columns=2)
87

98
from matplotlib import pyplot as plt
109
import numpy as np
1110

12-
1311
t = np.linspace(0, 10, 400)
1412
s = 0.3 * t + 2.5 * np.cos(2 * np.pi * 0.85 * t) - 0.8
1513

data/share/matplotlib-pgfutils/examples/twocol/single.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,13 +3,11 @@
33

44
from pgfutils import save, setup_figure
55

6-
76
setup_figure(width=1, height=0.4, columns=1)
87

98
from matplotlib import pyplot as plt
109
import numpy as np
1110

12-
1311
t = np.linspace(0, 10, 200)
1412
s = 0.3 * t + 2.5 * np.cos(2 * np.pi * 0.85 * t) - 0.8
1513

pyproject.toml

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,10 +64,14 @@ select = [
6464
"W", # pycodestyle warnings
6565
]
6666

67-
[tool.ruff.isort]
67+
[tool.ruff.lint.isort]
6868
combine-as-imports = true
6969
force-sort-within-sections = true
7070

71+
[tool.ruff.lint.per-file-ignores]
72+
"data/**.py" = ["E402"]
73+
"tests/**.py" = ["E402"]
74+
7175

7276
#
7377
# Testing

tests/sources/environment/check_set/basic.py

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,12 +3,10 @@
33

44
from pgfutils import save, setup_figure
55

6-
76
setup_figure()
87

98
import os
109

11-
1210
name1 = os.environ.get("name1", "not set")
1311
name2 = os.environ.get("name2", "not set")
1412

tests/sources/environment/check_set/override.py

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,17 +3,14 @@
33

44
import os
55

6-
76
os.environ["name1"] = "original value"
87

98
from pgfutils import save, setup_figure
109

11-
1210
setup_figure()
1311

1412
import os
1513

16-
1714
name1 = os.environ.get("name1", "not set")
1815
name2 = os.environ.get("name2", "not set")
1916

tests/sources/environment/invalid/basic.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,5 @@
33

44
from pgfutils import save, setup_figure
55

6-
76
setup_figure()
87
save()

0 commit comments

Comments
 (0)