8000 FIX: pathlib in nbagg · matplotlib/matplotlib@14eadeb · GitHub
[go: up one dir, main page]

Skip to content

Commit 14eadeb

Browse files
committed
FIX: pathlib in nbagg
1 parent ed0a579 commit 14eadeb

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

lib/matplotlib/backends/backend_nbagg.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@
77
import io
88
import json
99
import os
10+
import pathlib
1011
import uuid
1112

1213
from IPython.display import display, Javascript, HTML
@@ -111,7 +112,8 @@ def get_javascript(cls, stream=None):
111112
else:
112113
output = stream
113114
super().get_javascript(stream=output)
114-
output.write((Path(__file__).parent / "web_backend/js/nbagg_mpl.js")
115+
output.write((pathlib.Path(__file__).parent
116+
/ "web_backend/js/nbagg_mpl.js")
115117
.read_text(encoding="utf-8"))
116118
if stream is None:
117119
return output.getvalue()

0 commit comments

Comments
 (0)
0