Skip to content

Commit 4ebcc97

Browse files
committed
Fix mandelbrot example.
(Apparently the version parsing can sometimes fail on Travis.)
1 parent 68786e6 commit 4ebcc97

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

examples/showcase/mandelbrot.py

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -67,10 +67,9 @@ def mandelbrot_set(xmin, xmax, ymin, ymax, xn, yn, maxiter, horizon=2.0):
6767

6868
# Some advertisement for matplotlib
6969
year = time.strftime("%Y")
70-
major, minor, micro = matplotlib.__version__.split('.', 2)
7170
text = ("The Mandelbrot fractal set\n"
72-
"Rendered with matplotlib %s.%s, %s - http://matplotlib.org"
73-
% (major, minor, year))
71+
"Rendered with matplotlib %s, %s - http://matplotlib.org"
72+
% (matplotlib.__version__, year))
7473
ax.text(xmin+.025, ymin+.025, text, color="white", fontsize=12, alpha=0.5)
7574

7675
plt.show()

0 commit comments

Comments
 (0)