Skip to content

Commit cc45d29

Browse files
authored
fix: temp mpl deprec (#443)
1 parent 1fcd5d9 commit cc45d29

File tree

5 files changed

+6
-6
lines changed

5 files changed

+6
-6
lines changed

Diff for: src/mplhep/alice.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
import inspect
44

5-
from matplotlib import docstring
5+
from matplotlib import _docstring as docstring
66

77
import mplhep
88

Diff for: src/mplhep/atlas.py

+2-2
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515
__all__ = ("style", "lumitext")
1616

1717

18-
@mpl.docstring.copy(label_base.exp_text)
18+
@mpl._docstring.copy(label_base.exp_text)
1919
def text(text="", **kwargs):
2020
for key, value in dict(mplhep.rcParams.text._get_kwargs()).items():
2121
if (
@@ -29,7 +29,7 @@ def text(text="", **kwargs):
2929
return label_base.exp_text("ATLAS", text=text, **kwargs)
3030

3131

32-
@mpl.docstring.copy(label_base.exp_label)
32+
@mpl._docstring.copy(label_base.exp_label)
3333
def label(label=None, **kwargs):
3434
for key, value in dict(mplhep.rcParams.label._get_kwargs()).items():
3535
if (

Diff for: src/mplhep/cms.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
import inspect
44

5-
from matplotlib import docstring
5+
from matplotlib import _docstring as docstring
66

77
import mplhep
88

Diff for: src/mplhep/lhcb.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@
2020

2121
import inspect
2222

23-
from matplotlib import docstring
23+
from matplotlib import _docstring as docstring
2424

2525
import mplhep
2626
from mplhep import label as label_base

Diff for: tests/test_inputs.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -101,7 +101,7 @@ def test_inputs_bh_cat():
101101
bh.axis.IntCategory(range(10)), bh.axis.StrCategory("", growth=True)
102102
)
103103

104-
x = np.round(np.random.normal(5, 3, 1000))
104+
x = np.round(np.random.normal(5, 3, 1000)).astype(int)
105105
A, Z = np.array(["A", "Z"]).view("int32")
106106
y = list(
107107
np.random.randint(low=A, high=Z, size=1000, dtype="int32").view(f"U{1000}")[0]

0 commit comments

Comments
 (0)