1313if sys .version_info < min_version :
1414 error = """
1515Beginning with Matplotlib 3.1, Python {0} or above is required.
16+ You are using Python {1}.
1617
1718This may be due to an out of date pip.
1819
1920Make sure you have pip >= 9.0.1.
20- """ .format ('.' .join (str (n ) for n in min_version )),
21+ """ .format ('.' .join (str (n ) for n in min_version ),
22+ '.' .join (str (n ) for n in sys .version_info [:3 ]))
2123 sys .exit (error )
2224
2325from pathlib import Path
@@ -112,8 +114,9 @@ def _download_jquery_to(dest):
112114 try :
113115 buff = download_or_cache (url , sha )
114116 except Exception :
115- raise IOError (f"Failed to download jquery-ui. Please download "
116- f"{ url } and extract it to { dest } ." )
117+ raise IOError (
118+ "Failed to download jquery-ui. Please download "
119+ "{url} and extract it to {dest}." .format (url = url , dest = dest ))
117120 with ZipFile (buff ) as zf :
118121 zf .extractall (dest )
119122
@@ -154,7 +157,7 @@ def run(self):
154157 # If the user just queries for information, don't bother figuring out which
155158 # packages to build or install.
156159 if not (any ('--' + opt in sys .argv
157- for opt in [ * Distribution .display_option_names , 'help' ])
160+ for opt in Distribution .display_option_names + [ 'help' ])
158161 or 'clean' in sys .argv ):
159162 # Go through all of the packages and figure out which ones we are
160163 # going to build/install.
@@ -169,10 +172,11 @@ def run(self):
169172 try :
170173 message = package .check ()
171174 except setupext .Skipped as e :
172- print_status (package .name , f "no [{ e } ]" )
175+ print_status (package .name , "no [{e}]" . format ( e = e ) )
173176 continue
174177 if message is not None :
175- print_status (package .name , f"yes [{ message } ]" )
178+ print_status (package .name ,
179+ "yes [{message}]" .format (message = message ))
176180 good_packages .append (package )
177181
178182 print_raw ()
0 commit comments