Commits

Anonymous committed e32afa6

Remove 2.3 compatibility requirement.

Comments (0)

Files changed (3)

 -----------
 (codename not selected, to be released in 2009)
 
+- Dropped Python 2.3 compatibility.
+
 - Lexers added:
 
   * Go

tests/test_html_formatter.py

         tfile.close()
         catname = os.path.join(TESTDIR, 'dtds', 'HTML4.soc')
         try:
-            try:
-                import subprocess
-                ret = subprocess.Popen(['nsgmls', '-s', '-c', catname, pathname],
-                                       stdout=subprocess.PIPE).wait()
-            except ImportError:
-                # Python 2.3 - no subprocess module
-                ret = os.popen('nsgmls -s -c "%s" "%s"' % (catname, pathname)).close()
-                if ret == 32512: raise OSError  # not found
+            import subprocess
+            ret = subprocess.Popen(['nsgmls', '-s', '-c', catname, pathname],
+                                   stdout=subprocess.PIPE).wait()
         except OSError:
             # nsgmls not available
             pass

tests/test_latex_formatter.py

         fmt.format(tokensource, tfile)
         tfile.close()
         try:
-            try:
-                import subprocess
-                ret = subprocess.Popen(['latex', '-interaction=nonstopmode',
-                                        pathname],
-                                       stdout=subprocess.PIPE).wait()
-            except ImportError:
-                # Python 2.3 - no subprocess module
-                ret = os.popen('latex -interaction=nonstopmode "%s"'
-                               % pathname).close()
-                if ret == 32512: raise OSError  # not found
+            import subprocess
+            ret = subprocess.Popen(['latex', '-interaction=nonstopmode',
+                                    pathname],
+                                   stdout=subprocess.PIPE).wait()
         except OSError:
             # latex not available
             pass