Skip to content

Commit 4e8089d

Browse files
authored
More general solution
1 parent 237492a commit 4e8089d

1 file changed

Lines changed: 3 additions & 2 deletions

File tree

mprof

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -252,8 +252,9 @@ def add_brackets(xloc, yloc, xshift=0, color="r", label=None, options=None):
252252
"""
253253
try:
254254
import pylab as pl
255-
except ImportError:
256-
print("matplotlib is needed for plotting and tkinter for visualisation.")
255+
except ImportError as e:
256+
print("matplotlib is needed for plotting.")
257+
print(e)
257258
sys.exit(1)
258259
height_ratio = 20.
259260
vsize = (pl.ylim()[1] - pl.ylim()[0]) / height_ratio

0 commit comments

Comments
 (0)