mirror of
https://github.com/python/cpython.git
synced 2025-11-03 03:22:27 +00:00
reverted distutils its 3.1 state. All new work is now happening in disutils2, and distutils is now feature-frozen.
This commit is contained in:
parent
5db0c94072
commit
3679727939
64 changed files with 1626 additions and 1678 deletions
|
|
@ -3,19 +3,11 @@ import os
|
|||
import shutil
|
||||
import tempfile
|
||||
from copy import deepcopy
|
||||
import warnings
|
||||
|
||||
from distutils import log
|
||||
from distutils.log import DEBUG, INFO, WARN, ERROR, FATAL
|
||||
from distutils.core import Distribution
|
||||
|
||||
def capture_warnings(func):
|
||||
def _capture_warnings(*args, **kw):
|
||||
with warnings.catch_warnings():
|
||||
warnings.simplefilter("ignore")
|
||||
return func(*args, **kw)
|
||||
return _capture_warnings
|
||||
|
||||
class LoggingSilencer(object):
|
||||
|
||||
def setUp(self):
|
||||
|
|
@ -63,8 +55,6 @@ class TempdirManager(object):
|
|||
super().tearDown()
|
||||
while self.tempdirs:
|
||||
d = self.tempdirs.pop()
|
||||
if not os.path.exists(d):
|
||||
continue
|
||||
shutil.rmtree(d, os.name in ('nt', 'cygwin'))
|
||||
|
||||
def mkdtemp(self):
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue