@@ -345,7 +345,7 @@ def impl(args, regex, min_ver=None, ignore_exit_code=False):
345345 if min_ver is not None and version < min_ver :
346346 raise ExecutableNotFoundError (
347347 f"You have { args [0 ]} version { version } but the minimum "
348- f"version supported by Matplotlib is { min_ver } . " )
348+ f"version supported by Matplotlib is { min_ver } " )
349349 return _ExecInfo (args [0 ], version )
350350 else :
351351 raise ExecutableNotFoundError (
@@ -366,7 +366,12 @@ def impl(args, regex, min_ver=None, ignore_exit_code=False):
366366 message = "Failed to find a Ghostscript installation"
367367 raise ExecutableNotFoundError (message )
368368 elif name == "inkscape" :
369- return impl (["inkscape" , "-V" ], "^Inkscape ([^ ]*)" )
369+ info = impl (["inkscape" , "-V" ], "^Inkscape ([^ ]*)" )
370+ if info and info .version >= "1.0" :
371+ raise ExecutableNotFoundError (
372+ f"You have Inkscape version { info .version } but Matplotlib "
373+ f"only supports Inkscape<1.0" )
374+ return info
370375 elif name == "magick" :
371376 path = None
372377 if sys .platform == "win32" :
@@ -403,7 +408,7 @@ def impl(args, regex, min_ver=None, ignore_exit_code=False):
403408 or "0.9" <= info .version <= "1.0" ):
404409 raise ExecutableNotFoundError (
405410 f"You have pdftops version { info .version } but the minimum "
406- f"version supported by Matplotlib is 3.0. " )
411+ f"version supported by Matplotlib is 3.0" )
407412 return info
408413 else :
409414 raise ValueError ("Unknown executable: {!r}" .format (name ))
0 commit comments