Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit ad5ffed

Browse filesBrowse files
committed
MAINT: use more descriptive argument name.
The optional argument "ignore_error" is changed to "ignore_exit_code" based on the suggestion of @timhoffm.
1 parent 36339eb commit ad5ffed
Copy full SHA for ad5ffed

File tree

Expand file treeCollapse file tree

1 file changed

+3
-3
lines changed
Filter options
Expand file treeCollapse file tree

1 file changed

+3
-3
lines changed

‎lib/matplotlib/__init__.py

Copy file name to clipboardExpand all lines: lib/matplotlib/__init__.py
+3-3Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -314,7 +314,7 @@ def _get_executable_info(name):
314314
If the executable is not one that we know how to query.
315315
"""
316316

317-
def impl(args, regex, min_ver=None, ignore_error=False):
317+
def impl(args, regex, min_ver=None, ignore_exit_code=False):
318318
# Execute the subprocess specified by args; capture stdout and stderr.
319319
# Search for a regex match in the output; if the match succeeds, the
320320
# first group of the match is the version.
@@ -324,7 +324,7 @@ def impl(args, regex, min_ver=None, ignore_error=False):
324324
output = subprocess.check_output(
325325
args, stderr=subprocess.STDOUT, universal_newlines=True)
326326
except subprocess.CalledProcessError as _cpe:
327-
if ignore_error:
327+
if ignore_exit_code:
328328
output = _cpe.output
329329
else:
330330
raise _cpe
@@ -385,7 +385,7 @@ def impl(args, regex, min_ver=None, ignore_error=False):
385385
return impl([path, "--version"], r"^Version: ImageMagick (\S*)")
386386
elif name == "pdftops":
387387
info = impl(["pdftops", "-v"], "^pdftops version (.*)",
388-
ignore_error=True)
388+
ignore_exit_code=True)
389389
if info and not ("3.0" <= info.version
390390
# poppler version numbers.
391391
or "0.9" <= info.version <= "1.0"):

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.