Skip to content

Commit bbebbd4

Browse files
committed
Merge pull request #2703 from androomerrill/plot_directive_sphinxext_fix
Updating regex used to split sphinx version string.
2 parents 93cce5e + b7812ee commit bbebbd4

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/matplotlib/sphinxext/plot_directive.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -147,7 +147,7 @@
147147
sphinx_version = sphinx.__version__.split(".")
148148
# The split is necessary for sphinx beta versions where the string is
149149
# '6b1'
150-
sphinx_version = tuple([int(re.split('[a-z]', x)[0])
150+
sphinx_version = tuple([int(re.split('[^0-9]', x)[0])
151151
for x in sphinx_version[:2]])
152152

153153
try:

0 commit comments

Comments
 (0)