Powered by penguin. Your IP: 54.80.115.140 | Toc:- prep
Executing(%prep): /bin/sh -e /tmp/B.HVALGw/BUILD/tmp/rpm-tmp.47033
- build
Executing(%build): /bin/sh -e /tmp/B.HVALGw/BUILD/tmp/rpm-tmp.47033
- error 1
E OSError: [Errno 2] No such file or directory
- error 2
E OSError: [Errno 2] No such file or directory
- error 3
E OSError: [Errno 2] No such file or directory
- error 4
E OSError: [Errno 2] No such file or directory
- error 5
E OSError: [Errno 2] No such file or directory
- error 6
E OSError: [Errno 2] No such file or directory
- error 7
E OSError: [Errno 2] No such file or directory
- error 8
E OSError: [Errno 2] No such file or directory
- error 9
E OSError: [Errno 2] No such file or directory
- error 10
E OSError: [Errno 2] No such file or directory
- error 11
E OSError: [Errno 2] No such file or directory
- error 12
E OSError: [Errno 2] No such file or directory
- error 13
E OSError: [Errno 2] No such file or directory
- error 14
err 'Traceback (most recent call last):\n File "setup.py", line 1, in <module>\n from setuptools import setup;setup(use_scm_version={"root": ".."})\n File "/usr/lib64/python2.7/distutils/core.py", line 111, in setup\n _setup_distribution = dist = klass(attrs)\n File "/usr/share/python2.7/site-packages/setuptools/dist.py", line 272, in __init__\n File "/usr/lib64/python2.7/distutils/dist.py", line 287, in __init__\n self.finalize_options()\n File "/usr/share/python2.7/site-packages/setuptools/dist.py", line 327, in finalize_options\n File "/usr/share/python2.7/site-packages/setuptools_scm/integration.py", line 19, in version_keyword\n File "/usr/share/python2.7/site-packages/setuptools_scm/__init__.py", line 104, in get_version\n File "/usr/share/python2.7/site-packages/setuptools_scm/__init__.py", line 82, in _do_parse\nLookupError: setuptools-scm was unable to detect version for \'/tmp/B.HVALGw/BUILD/tmp/pytest-of-builder/pytest-0/test_pkginfo_noscmroot0/sub\'.\n\nMake sure you\'re either building from a fully intact git repository or PyPI tarballs. Most other sources (such as GitHub\'s tarballs, a git checkout without the .git folder) don\'t contain the necessary metadata and will not work.\n\nFor example, if you\'re using pip, instead of https://github.com/user/proj/archive/master.zip use git+https://github.com/user/proj.git#egg=proj\n'
- error 15
error: Bad exit status from /tmp/B.HVALGw/BUILD/tmp/rpm-tmp.47033 (%build)
- error 16
RPM build errors:
- error 17
error: No files produced.
Content:request from: qboosh
checking if we should skip the build
started at: Sat Mar 11 19:50:21 2017
fetching https://srcbuilder.pld-linux.org/th//srpms/67a4abea-475d-48f8-a8cb-4cbc181bd89e/python-setuptools_scm-1.15.0-1.src.rpm
fetched 35675 bytes, 101.9 K/s
installing srpm: python-setuptools_scm-1.15.0-1.src.rpm
mesg: ttyname failed: Inappropriate ioctl for device
+ install -d /tmp/B.HVALGw/BUILD /tmp/B.HVALGw/RPMS
+ LC_ALL=en_US.UTF-8
+ rpm -qp --changelog python-setuptools_scm-1.15.0-1.src.rpm
* Sat Mar 11 2017 PLD Linux Team <feedback@pld-linux.org>
- For complete changelog see: http://git.pld-linux.org/?p=packages/python-setuptools_scm.git;a=log;h=master
* Sat Mar 11 2017 Jakub Bogusz <qboosh@pld-linux.org> 20ee71f - updated to 1.15.0
- actually run tests
* Wed Dec 28 2016 Arkadiusz MiĆkiewicz <arekm@maven.pl> 3bd0d5d - python3.6
- release 2 (by relup.sh)
* Fri May 13 2016 Jakub Bogusz <qboosh@pld-linux.org> cdd8c19 - updated to 1.11.0
+ rpm -Uhv --nodeps --define '_topdir /tmp/B.HVALGw' --define '_specdir %{_topdir}' --define '_sourcedir %{_specdir}' --define '_rpmdir %{_topdir}/RPMS' --define '_builddir %{_topdir}/BUILD' python-setuptools_scm-1.15.0-1.src.rpm
Preparing... ##################################################
python-setuptools_scm ##################################################
+ rm -f python-setuptools_scm-1.15.0-1.src.rpm
mesg: ttyname failed: Inappropriate ioctl for device
+ install -m 700 -d /tmp/B.HVALGw/BUILD/tmp
mesg: ttyname failed: Inappropriate ioctl for device
+ TMPDIR=/tmp/B.HVALGw/BUILD/tmp
+ exec nice -n 0 rpmbuild -bp --short-circuit --nodeps --define '_topdir /tmp/B.HVALGw' --define '_specdir %{_topdir}' --define '_sourcedir %{_specdir}' --define '_rpmdir %{_topdir}/RPMS' --define '_builddir %{_topdir}/BUILD' --target x86_64-pld-linux --define 'prep exit 0' /tmp/B.HVALGw/python-setuptools_scm.spec
Building target platforms: x86_64-pld-linux
checking BuildConflict-ing packages
no BuildConflicts found
checking BR
rpm: Building target platforms: x86_64-pld-linux
no BR needed
building RPM using: set -ex; : build-id: 67a4abea-475d-48f8-a8cb-4cbc181bd89e; TMPDIR=/tmp/B.HVALGw/BUILD/tmp exec nice -n 0 rpmbuild -bb --define '_smp_mflags -j5' --define '_make_opts -Otarget' --define '_pld_builder 1' --define '_topdir /tmp/B.HVALGw' --define '_specdir %{_topdir}' --define '_sourcedir %{_specdir}' --define '_rpmdir %{_topdir}/RPMS' --define '_builddir %{_topdir}/BUILD' --target x86_64-pld-linux /tmp/B.HVALGw/python-setuptools_scm.spec
mesg: ttyname failed: Inappropriate ioctl for device
+ : build-id: 67a4abea-475d-48f8-a8cb-4cbc181bd89e
+ TMPDIR=/tmp/B.HVALGw/BUILD/tmp
+ exec nice -n 0 rpmbuild -bb --define '_smp_mflags -j5' --define '_make_opts -Otarget' --define '_pld_builder 1' --define '_topdir /tmp/B.HVALGw' --define '_specdir %{_topdir}' --define '_sourcedir %{_specdir}' --define '_rpmdir %{_topdir}/RPMS' --define '_builddir %{_topdir}/BUILD' --target x86_64-pld-linux /tmp/B.HVALGw/python-setuptools_scm.spec
Building target platforms: x86_64-pld-linux
Executing(%prep): /bin/sh -e /tmp/B.HVALGw/BUILD/tmp/rpm-tmp.47033
+ umask 022
+ cd /tmp/B.HVALGw/BUILD
+ cd /tmp/B.HVALGw/BUILD
+ rm -rf setuptools_scm-1.15.0
+ /usr/bin/gzip -dc /tmp/B.HVALGw/setuptools_scm-1.15.0.tar.gz
+ /bin/tar -xf -
+ STATUS=0
+ '[' 0 -ne 0 ']'
+ cd setuptools_scm-1.15.0
+ /bin/id -u
+ '[' 1000 '=' 0 ']'
+ /bin/id -u
+ '[' 1000 '=' 0 ']'
+ /bin/chmod -Rf a+rX,u+w,g-w,o-w .
+ exit 0
Executing(%build): /bin/sh -e /tmp/B.HVALGw/BUILD/tmp/rpm-tmp.47033
TMP=/home/users/builder/tmp
HOME=/home/users/builder
PATH=/home/users/builder/GNUstep/Tools:/usr/local/bin:/usr/bin:/bin:/home/users/builder/bin
TMPDIR=/tmp/B.HVALGw/BUILD/tmp
+ umask 022
+ cd /tmp/B.HVALGw/BUILD
+ cd setuptools_scm-1.15.0
+ LDFLAGS='-Wl,--as-needed -Wl,--no-copy-dt-needed-entries -Wl,-z,relro -Wl,-z,combreloc '
+ export LDFLAGS
+ CFLAGS=' -O2 -fwrapv -pipe -Wformat -Werror=format-security -gdwarf-4 -fno-debug-types-section -fvar-tracking-assignments -g2 -Wp,-D_FORTIFY_SOURCE=2 -fstack-protector-strong --param=ssp-buffer-size=4 -fPIC -march=x86-64 -gdwarf-4 -fno-debug-types-section -fvar-tracking-assignments -g2 '
+ export CFLAGS
+ CXXFLAGS=' -O2 -fwrapv -pipe -Wformat -Werror=format-security -gdwarf-4 -fno-debug-types-section -fvar-tracking-assignments -g2 -Wp,-D_FORTIFY_SOURCE=2 -fstack-protector-strong --param=ssp-buffer-size=4 -fPIC -march=x86-64 -gdwarf-4 -fno-debug-types-section -fvar-tracking-assignments -g2 '
+ export CXXFLAGS
+ CC=x86_64-pld-linux-gcc
+ export CC
+ CXX=x86_64-pld-linux-g++
+ export CXX
+ /usr/bin/python2 setup.py build '--build-base=build-2'
running build
running build_py
creating build-2
creating build-2/lib
creating build-2/lib/setuptools_scm
copying setuptools_scm/__init__.py -> build-2/lib/setuptools_scm
copying setuptools_scm/__main__.py -> build-2/lib/setuptools_scm
copying setuptools_scm/discover.py -> build-2/lib/setuptools_scm
copying setuptools_scm/git.py -> build-2/lib/setuptools_scm
copying setuptools_scm/hacks.py -> build-2/lib/setuptools_scm
copying setuptools_scm/hg.py -> build-2/lib/setuptools_scm
copying setuptools_scm/integration.py -> build-2/lib/setuptools_scm
copying setuptools_scm/utils.py -> build-2/lib/setuptools_scm
copying setuptools_scm/version.py -> build-2/lib/setuptools_scm
+ /usr/bin/python2 -mpytest
============================= test session starts ==============================
platform linux2 -- Python 2.7.13, pytest-2.9.2, py-1.4.32, pluggy-0.3.1
setuptools version 21.0.0
setuptools_scm version 1.15.0
rootdir: /tmp/B.HVALGw/BUILD/setuptools_scm-1.15.0, inifile:
plugins: timeout-1.0.0, hypothesis-3.1.0
collected 47 items
testing/test_basic_api.py ..........
testing/test_functions.py ................
testing/test_git.py EEEEEEEE
testing/test_main.py .
testing/test_mercurial.py .....EEEE
testing/test_regressions.py F.s
==================================== ERRORS ====================================
___________________ ERROR at setup of test_version_from_git ____________________
wd = <conftest.Wd object at 0x7fb5e1f98dd0>
@pytest.fixture
def wd(wd):
> wd('git init')
testing/test_git.py:10:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
testing/conftest.py:30: in __call__
return do(cmd, self.cwd)
setuptools_scm/utils.py:79: in do
out, err, ret = do_ex(cmd, cwd)
setuptools_scm/utils.py:67: in do_ex
p = _popen_pipes(cmd, cwd)
setuptools_scm/utils.py:57: in _popen_pipes
HGPLAIN='1',
/usr/lib64/python2.7/subprocess.py:390: in __init__
errread, errwrite)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
self = <subprocess.Popen object at 0x7fb5e1f98a50>, args = ['git', 'init']
executable = 'git', preexec_fn = None, close_fds = False
cwd = '/tmp/B.HVALGw/BUILD/tmp/pytest-of-builder/pytest-0/test_version_from_git0/wd'
env = {'CC': 'x86_64-pld-linux-gcc', 'CFLAGS': ' -O2 -fwrapv -pipe -Wformat -Werror=format-security -gdwarf-4 -fno-debug-typ...es/Java:/usr/local/lib64/GNUstep/Libraries/Java:/usr/lib64/GNUstep/Libraries/Java', 'CXX': 'x86_64-pld-linux-g++', ...}
universal_newlines = False, startupinfo = None, creationflags = 0, shell = False
to_close = set([9, 12]), p2cread = None, p2cwrite = None, c2pread = 9
c2pwrite = 11, errread = 12, errwrite = 13
def _execute_child(self, args, executable, preexec_fn, close_fds,
cwd, env, universal_newlines,
startupinfo, creationflags, shell, to_close,
p2cread, p2cwrite,
c2pread, c2pwrite,
errread, errwrite):
"""Execute program (POSIX version)"""
if isinstance(args, types.StringTypes):
args = [args]
else:
args = list(args)
if shell:
args = ["/bin/sh", "-c"] + args
if executable:
args[0] = executable
if executable is None:
executable = args[0]
def _close_in_parent(fd):
os.close(fd)
to_close.remove(fd)
# For transferring possible exec failure from child to parent
# The first char specifies the exception type: 0 means
# OSError, 1 means some other error.
errpipe_read, errpipe_write = self.pipe_cloexec()
try:
try:
gc_was_enabled = gc.isenabled()
# Disable gc to avoid bug where gc -> file_dealloc ->
# write to stderr -> hang. http://bugs.python.org/issue1336
gc.disable()
try:
self.pid = os.fork()
except:
if gc_was_enabled:
gc.enable()
raise
self._child_created = True
if self.pid == 0:
# Child
try:
# Close parent's pipe ends
if p2cwrite is not None:
os.close(p2cwrite)
if c2pread is not None:
os.close(c2pread)
if errread is not None:
os.close(errread)
os.close(errpipe_read)
# When duping fds, if there arises a situation
# where one of the fds is either 0, 1 or 2, it
# is possible that it is overwritten (#12607).
if c2pwrite == 0:
c2pwrite = os.dup(c2pwrite)
if errwrite == 0 or errwrite == 1:
errwrite = os.dup(errwrite)
# Dup fds for child
def _dup2(a, b):
# dup2() removes the CLOEXEC flag but
# we must do it ourselves if dup2()
# would be a no-op (issue #10806).
if a == b:
self._set_cloexec_flag(a, False)
elif a is not None:
os.dup2(a, b)
_dup2(p2cread, 0)
_dup2(c2pwrite, 1)
_dup2(errwrite, 2)
# Close pipe fds. Make sure we don't close the
# same fd more than once, or standard fds.
closed = { None }
for fd in [p2cread, c2pwrite, errwrite]:
if fd not in closed and fd > 2:
os.close(fd)
closed.add(fd)
if cwd is not None:
os.chdir(cwd)
if preexec_fn:
preexec_fn()
# Close all other fds, if asked for - after
# preexec_fn(), which may open FDs.
if close_fds:
self._close_fds(but=errpipe_write)
if env is None:
os.execvp(executable, args)
else:
os.execvpe(executable, args, env)
except:
exc_type, exc_value, tb = sys.exc_info()
# Save the traceback and attach it to the exception object
exc_lines = traceback.format_exception(exc_type,
exc_value,
tb)
exc_value.child_traceback = ''.join(exc_lines)
os.write(errpipe_write, pickle.dumps(exc_value))
# This exitcode won't be reported to applications, so it
# really doesn't matter what we return.
os._exit(255)
# Parent
if gc_was_enabled:
gc.enable()
finally:
# be sure the FD is closed no matter what
os.close(errpipe_write)
# Wait for exec to fail or succeed; possibly raising exception
data = _eintr_retry_call(os.read, errpipe_read, 1048576)
pickle_bits = []
while data:
pickle_bits.append(data)
data = _eintr_retry_call(os.read, errpipe_read, 1048576)
data = "".join(pickle_bits)
finally:
if p2cread is not None and p2cwrite is not None:
_close_in_parent(p2cread)
if c2pwrite is not None and c2pread is not None:
_close_in_parent(c2pwrite)
if errwrite is not None and errread is not None:
_close_in_parent(errwrite)
# be sure the FD is closed no matter what
os.close(errpipe_read)
if data != "":
try:
_eintr_retry_call(os.waitpid, self.pid, 0)
except OSError as e:
if e.errno != errno.ECHILD:
raise
child_exception = pickle.loads(data)
> raise child_exception
E OSError: [Errno 2] No such file or directory
/usr/lib64/python2.7/subprocess.py:1024: OSError
---------------------------- Captured stdout setup -----------------------------
cmd 'git init'
_____________________ ERROR at setup of test_git_worktree ______________________
wd = <conftest.Wd object at 0x7fb5e2039f90>
@pytest.fixture
def wd(wd):
> wd('git init')
testing/test_git.py:10:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
testing/conftest.py:30: in __call__
return do(cmd, self.cwd)
setuptools_scm/utils.py:79: in do
out, err, ret = do_ex(cmd, cwd)
setuptools_scm/utils.py:67: in do_ex
p = _popen_pipes(cmd, cwd)
setuptools_scm/utils.py:57: in _popen_pipes
HGPLAIN='1',
/usr/lib64/python2.7/subprocess.py:390: in __init__
errread, errwrite)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
self = <subprocess.Popen object at 0x7fb5e2039ad0>, args = ['git', 'init']
executable = 'git', preexec_fn = None, close_fds = False
cwd = '/tmp/B.HVALGw/BUILD/tmp/pytest-of-builder/pytest-0/test_git_worktree0/wd'
env = {'CC': 'x86_64-pld-linux-gcc', 'CFLAGS': ' -O2 -fwrapv -pipe -Wformat -Werror=format-security -gdwarf-4 -fno-debug-typ...es/Java:/usr/local/lib64/GNUstep/Libraries/Java:/usr/lib64/GNUstep/Libraries/Java', 'CXX': 'x86_64-pld-linux-g++', ...}
universal_newlines = False, startupinfo = None, creationflags = 0, shell = False
to_close = set([9, 12]), p2cread = None, p2cwrite = None, c2pread = 9
c2pwrite = 11, errread = 12, errwrite = 13
def _execute_child(self, args, executable, preexec_fn, close_fds,
cwd, env, universal_newlines,
startupinfo, creationflags, shell, to_close,
p2cread, p2cwrite,
c2pread, c2pwrite,
errread, errwrite):
"""Execute program (POSIX version)"""
if isinstance(args, types.StringTypes):
args = [args]
else:
args = list(args)
if shell:
args = ["/bin/sh", "-c"] + args
if executable:
args[0] = executable
if executable is None:
executable = args[0]
def _close_in_parent(fd):
os.close(fd)
to_close.remove(fd)
# For transferring possible exec failure from child to parent
# The first char specifies the exception type: 0 means
# OSError, 1 means some other error.
errpipe_read, errpipe_write = self.pipe_cloexec()
try:
try:
gc_was_enabled = gc.isenabled()
# Disable gc to avoid bug where gc -> file_dealloc ->
# write to stderr -> hang. http://bugs.python.org/issue1336
gc.disable()
try:
self.pid = os.fork()
except:
if gc_was_enabled:
gc.enable()
raise
self._child_created = True
if self.pid == 0:
# Child
try:
# Close parent's pipe ends
if p2cwrite is not None:
os.close(p2cwrite)
if c2pread is not None:
os.close(c2pread)
if errread is not None:
os.close(errread)
os.close(errpipe_read)
# When duping fds, if there arises a situation
# where one of the fds is either 0, 1 or 2, it
# is possible that it is overwritten (#12607).
if c2pwrite == 0:
c2pwrite = os.dup(c2pwrite)
if errwrite == 0 or errwrite == 1:
errwrite = os.dup(errwrite)
# Dup fds for child
def _dup2(a, b):
# dup2() removes the CLOEXEC flag but
# we must do it ourselves if dup2()
# would be a no-op (issue #10806).
if a == b:
self._set_cloexec_flag(a, False)
elif a is not None:
os.dup2(a, b)
_dup2(p2cread, 0)
_dup2(c2pwrite, 1)
_dup2(errwrite, 2)
# Close pipe fds. Make sure we don't close the
# same fd more than once, or standard fds.
closed = { None }
for fd in [p2cread, c2pwrite, errwrite]:
if fd not in closed and fd > 2:
os.close(fd)
closed.add(fd)
if cwd is not None:
os.chdir(cwd)
if preexec_fn:
preexec_fn()
# Close all other fds, if asked for - after
# preexec_fn(), which may open FDs.
if close_fds:
self._close_fds(but=errpipe_write)
if env is None:
os.execvp(executable, args)
else:
os.execvpe(executable, args, env)
except:
exc_type, exc_value, tb = sys.exc_info()
# Save the traceback and attach it to the exception object
exc_lines = traceback.format_exception(exc_type,
exc_value,
tb)
exc_value.child_traceback = ''.join(exc_lines)
os.write(errpipe_write, pickle.dumps(exc_value))
# This exitcode won't be reported to applications, so it
# really doesn't matter what we return.
os._exit(255)
# Parent
if gc_was_enabled:
gc.enable()
finally:
# be sure the FD is closed no matter what
os.close(errpipe_write)
# Wait for exec to fail or succeed; possibly raising exception
data = _eintr_retry_call(os.read, errpipe_read, 1048576)
pickle_bits = []
while data:
pickle_bits.append(data)
data = _eintr_retry_call(os.read, errpipe_read, 1048576)
data = "".join(pickle_bits)
finally:
if p2cread is not None and p2cwrite is not None:
_close_in_parent(p2cread)
if c2pwrite is not None and c2pread is not None:
_close_in_parent(c2pwrite)
if errwrite is not None and errread is not None:
_close_in_parent(errwrite)
# be sure the FD is closed no matter what
os.close(errpipe_read)
if data != "":
try:
_eintr_retry_call(os.waitpid, self.pid, 0)
except OSError as e:
if e.errno != errno.ECHILD:
raise
child_exception = pickle.loads(data)
> raise child_exception
E OSError: [Errno 2] No such file or directory
/usr/lib64/python2.7/subprocess.py:1024: OSError
---------------------------- Captured stdout setup -----------------------------
cmd 'git init'
____________________ ERROR at setup of test_git_dirty_notag ____________________
wd = <conftest.Wd object at 0x7fb5e1fd8a50>
@pytest.fixture
def wd(wd):
> wd('git init')
testing/test_git.py:10:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
testing/conftest.py:30: in __call__
return do(cmd, self.cwd)
setuptools_scm/utils.py:79: in do
out, err, ret = do_ex(cmd, cwd)
setuptools_scm/utils.py:67: in do_ex
p = _popen_pipes(cmd, cwd)
setuptools_scm/utils.py:57: in _popen_pipes
HGPLAIN='1',
/usr/lib64/python2.7/subprocess.py:390: in __init__
errread, errwrite)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
self = <subprocess.Popen object at 0x7fb5e1fd8d90>, args = ['git', 'init']
executable = 'git', preexec_fn = None, close_fds = False
cwd = '/tmp/B.HVALGw/BUILD/tmp/pytest-of-builder/pytest-0/test_git_dirty_notag0/wd'
env = {'CC': 'x86_64-pld-linux-gcc', 'CFLAGS': ' -O2 -fwrapv -pipe -Wformat -Werror=format-security -gdwarf-4 -fno-debug-typ...es/Java:/usr/local/lib64/GNUstep/Libraries/Java:/usr/lib64/GNUstep/Libraries/Java', 'CXX': 'x86_64-pld-linux-g++', ...}
universal_newlines = False, startupinfo = None, creationflags = 0, shell = False
to_close = set([9, 12]), p2cread = None, p2cwrite = None, c2pread = 9
c2pwrite = 11, errread = 12, errwrite = 13
def _execute_child(self, args, executable, preexec_fn, close_fds,
cwd, env, universal_newlines,
startupinfo, creationflags, shell, to_close,
p2cread, p2cwrite,
c2pread, c2pwrite,
errread, errwrite):
"""Execute program (POSIX version)"""
if isinstance(args, types.StringTypes):
args = [args]
else:
args = list(args)
if shell:
args = ["/bin/sh", "-c"] + args
if executable:
args[0] = executable
if executable is None:
executable = args[0]
def _close_in_parent(fd):
os.close(fd)
to_close.remove(fd)
# For transferring possible exec failure from child to parent
# The first char specifies the exception type: 0 means
# OSError, 1 means some other error.
errpipe_read, errpipe_write = self.pipe_cloexec()
try:
try:
gc_was_enabled = gc.isenabled()
# Disable gc to avoid bug where gc -> file_dealloc ->
# write to stderr -> hang. http://bugs.python.org/issue1336
gc.disable()
try:
self.pid = os.fork()
except:
if gc_was_enabled:
gc.enable()
raise
self._child_created = True
if self.pid == 0:
# Child
try:
# Close parent's pipe ends
if p2cwrite is not None:
os.close(p2cwrite)
if c2pread is not None:
os.close(c2pread)
if errread is not None:
os.close(errread)
os.close(errpipe_read)
# When duping fds, if there arises a situation
# where one of the fds is either 0, 1 or 2, it
# is possible that it is overwritten (#12607).
if c2pwrite == 0:
c2pwrite = os.dup(c2pwrite)
if errwrite == 0 or errwrite == 1:
errwrite = os.dup(errwrite)
# Dup fds for child
def _dup2(a, b):
# dup2() removes the CLOEXEC flag but
# we must do it ourselves if dup2()
# would be a no-op (issue #10806).
if a == b:
self._set_cloexec_flag(a, False)
elif a is not None:
os.dup2(a, b)
_dup2(p2cread, 0)
_dup2(c2pwrite, 1)
_dup2(errwrite, 2)
# Close pipe fds. Make sure we don't close the
# same fd more than once, or standard fds.
closed = { None }
for fd in [p2cread, c2pwrite, errwrite]:
if fd not in closed and fd > 2:
os.close(fd)
closed.add(fd)
if cwd is not None:
os.chdir(cwd)
if preexec_fn:
preexec_fn()
# Close all other fds, if asked for - after
# preexec_fn(), which may open FDs.
if close_fds:
self._close_fds(but=errpipe_write)
if env is None:
os.execvp(executable, args)
else:
os.execvpe(executable, args, env)
except:
exc_type, exc_value, tb = sys.exc_info()
# Save the traceback and attach it to the exception object
exc_lines = traceback.format_exception(exc_type,
exc_value,
tb)
exc_value.child_traceback = ''.join(exc_lines)
os.write(errpipe_write, pickle.dumps(exc_value))
# This exitcode won't be reported to applications, so it
# really doesn't matter what we return.
os._exit(255)
# Parent
if gc_was_enabled:
gc.enable()
finally:
# be sure the FD is closed no matter what
os.close(errpipe_write)
# Wait for exec to fail or succeed; possibly raising exception
data = _eintr_retry_call(os.read, errpipe_read, 1048576)
pickle_bits = []
while data:
pickle_bits.append(data)
data = _eintr_retry_call(os.read, errpipe_read, 1048576)
data = "".join(pickle_bits)
finally:
if p2cread is not None and p2cwrite is not None:
_close_in_parent(p2cread)
if c2pwrite is not None and c2pread is not None:
_close_in_parent(c2pwrite)
if errwrite is not None and errread is not None:
_close_in_parent(errwrite)
# be sure the FD is closed no matter what
os.close(errpipe_read)
if data != "":
try:
_eintr_retry_call(os.waitpid, self.pid, 0)
except OSError as e:
if e.errno != errno.ECHILD:
raise
child_exception = pickle.loads(data)
> raise child_exception
E OSError: [Errno 2] No such file or directory
/usr/lib64/python2.7/subprocess.py:1024: OSError
---------------------------- Captured stdout setup -----------------------------
cmd 'git init'
________________ ERROR at setup of test_git_parse_shallow_warns ________________
wd = <conftest.Wd object at 0x7fb5e1f9f850>
@pytest.fixture
def wd(wd):
> wd('git init')
testing/test_git.py:10:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
testing/conftest.py:30: in __call__
return do(cmd, self.cwd)
setuptools_scm/utils.py:79: in do
out, err, ret = do_ex(cmd, cwd)
setuptools_scm/utils.py:67: in do_ex
p = _popen_pipes(cmd, cwd)
setuptools_scm/utils.py:57: in _popen_pipes
HGPLAIN='1',
/usr/lib64/python2.7/subprocess.py:390: in __init__
errread, errwrite)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
self = <subprocess.Popen object at 0x7fb5e1fcde90>, args = ['git', 'init']
executable = 'git', preexec_fn = None, close_fds = False
cwd = '/tmp/B.HVALGw/BUILD/tmp/pytest-of-builder/pytest-0/test_git_parse_shallow_warns0/wd'
env = {'CC': 'x86_64-pld-linux-gcc', 'CFLAGS': ' -O2 -fwrapv -pipe -Wformat -Werror=format-security -gdwarf-4 -fno-debug-typ...es/Java:/usr/local/lib64/GNUstep/Libraries/Java:/usr/lib64/GNUstep/Libraries/Java', 'CXX': 'x86_64-pld-linux-g++', ...}
universal_newlines = False, startupinfo = None, creationflags = 0, shell = False
to_close = set([9, 12]), p2cread = None, p2cwrite = None, c2pread = 9
c2pwrite = 11, errread = 12, errwrite = 13
def _execute_child(self, args, executable, preexec_fn, close_fds,
cwd, env, universal_newlines,
startupinfo, creationflags, shell, to_close,
p2cread, p2cwrite,
c2pread, c2pwrite,
errread, errwrite):
"""Execute program (POSIX version)"""
if isinstance(args, types.StringTypes):
args = [args]
else:
args = list(args)
if shell:
args = ["/bin/sh", "-c"] + args
if executable:
args[0] = executable
if executable is None:
executable = args[0]
def _close_in_parent(fd):
os.close(fd)
to_close.remove(fd)
# For transferring possible exec failure from child to parent
# The first char specifies the exception type: 0 means
# OSError, 1 means some other error.
errpipe_read, errpipe_write = self.pipe_cloexec()
try:
try:
gc_was_enabled = gc.isenabled()
# Disable gc to avoid bug where gc -> file_dealloc ->
# write to stderr -> hang. http://bugs.python.org/issue1336
gc.disable()
try:
self.pid = os.fork()
except:
if gc_was_enabled:
gc.enable()
raise
self._child_created = True
if self.pid == 0:
# Child
try:
# Close parent's pipe ends
if p2cwrite is not None:
os.close(p2cwrite)
if c2pread is not None:
os.close(c2pread)
if errread is not None:
os.close(errread)
os.close(errpipe_read)
# When duping fds, if there arises a situation
# where one of the fds is either 0, 1 or 2, it
# is possible that it is overwritten (#12607).
if c2pwrite == 0:
c2pwrite = os.dup(c2pwrite)
if errwrite == 0 or errwrite == 1:
errwrite = os.dup(errwrite)
# Dup fds for child
def _dup2(a, b):
# dup2() removes the CLOEXEC flag but
# we must do it ourselves if dup2()
# would be a no-op (issue #10806).
if a == b:
self._set_cloexec_flag(a, False)
elif a is not None:
os.dup2(a, b)
_dup2(p2cread, 0)
_dup2(c2pwrite, 1)
_dup2(errwrite, 2)
# Close pipe fds. Make sure we don't close the
# same fd more than once, or standard fds.
closed = { None }
for fd in [p2cread, c2pwrite, errwrite]:
if fd not in closed and fd > 2:
os.close(fd)
closed.add(fd)
if cwd is not None:
os.chdir(cwd)
if preexec_fn:
preexec_fn()
# Close all other fds, if asked for - after
# preexec_fn(), which may open FDs.
if close_fds:
self._close_fds(but=errpipe_write)
if env is None:
os.execvp(executable, args)
else:
os.execvpe(executable, args, env)
except:
exc_type, exc_value, tb = sys.exc_info()
# Save the traceback and attach it to the exception object
exc_lines = traceback.format_exception(exc_type,
exc_value,
tb)
exc_value.child_traceback = ''.join(exc_lines)
os.write(errpipe_write, pickle.dumps(exc_value))
# This exitcode won't be reported to applications, so it
# really doesn't matter what we return.
os._exit(255)
# Parent
if gc_was_enabled:
gc.enable()
finally:
# be sure the FD is closed no matter what
os.close(errpipe_write)
# Wait for exec to fail or succeed; possibly raising exception
data = _eintr_retry_call(os.read, errpipe_read, 1048576)
pickle_bits = []
while data:
pickle_bits.append(data)
data = _eintr_retry_call(os.read, errpipe_read, 1048576)
data = "".join(pickle_bits)
finally:
if p2cread is not None and p2cwrite is not None:
_close_in_parent(p2cread)
if c2pwrite is not None and c2pread is not None:
_close_in_parent(c2pwrite)
if errwrite is not None and errread is not None:
_close_in_parent(errwrite)
# be sure the FD is closed no matter what
os.close(errpipe_read)
if data != "":
try:
_eintr_retry_call(os.waitpid, self.pid, 0)
except OSError as e:
if e.errno != errno.ECHILD:
raise
child_exception = pickle.loads(data)
> raise child_exception
E OSError: [Errno 2] No such file or directory
/usr/lib64/python2.7/subprocess.py:1024: OSError
---------------------------- Captured stdout setup -----------------------------
cmd 'git init'
________________ ERROR at setup of test_git_parse_shallow_fail _________________
wd = <conftest.Wd object at 0x7fb5e1c21650>
@pytest.fixture
def wd(wd):
> wd('git init')
testing/test_git.py:10:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
testing/conftest.py:30: in __call__
return do(cmd, self.cwd)
setuptools_scm/utils.py:79: in do
out, err, ret = do_ex(cmd, cwd)
setuptools_scm/utils.py:67: in do_ex
p = _popen_pipes(cmd, cwd)
setuptools_scm/utils.py:57: in _popen_pipes
HGPLAIN='1',
/usr/lib64/python2.7/subprocess.py:390: in __init__
errread, errwrite)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
self = <subprocess.Popen object at 0x7fb5e1c21250>, args = ['git', 'init']
executable = 'git', preexec_fn = None, close_fds = False
cwd = '/tmp/B.HVALGw/BUILD/tmp/pytest-of-builder/pytest-0/test_git_parse_shallow_fail0/wd'
env = {'CC': 'x86_64-pld-linux-gcc', 'CFLAGS': ' -O2 -fwrapv -pipe -Wformat -Werror=format-security -gdwarf-4 -fno-debug-typ...es/Java:/usr/local/lib64/GNUstep/Libraries/Java:/usr/lib64/GNUstep/Libraries/Java', 'CXX': 'x86_64-pld-linux-g++', ...}
universal_newlines = False, startupinfo = None, creationflags = 0, shell = False
to_close = set([9, 12]), p2cread = None, p2cwrite = None, c2pread = 9
c2pwrite = 11, errread = 12, errwrite = 13
def _execute_child(self, args, executable, preexec_fn, close_fds,
cwd, env, universal_newlines,
startupinfo, creationflags, shell, to_close,
p2cread, p2cwrite,
c2pread, c2pwrite,
errread, errwrite):
"""Execute program (POSIX version)"""
if isinstance(args, types.StringTypes):
args = [args]
else:
args = list(args)
if shell:
args = ["/bin/sh", "-c"] + args
if executable:
args[0] = executable
if executable is None:
executable = args[0]
def _close_in_parent(fd):
os.close(fd)
to_close.remove(fd)
# For transferring possible exec failure from child to parent
# The first char specifies the exception type: 0 means
# OSError, 1 means some other error.
errpipe_read, errpipe_write = self.pipe_cloexec()
try:
try:
gc_was_enabled = gc.isenabled()
# Disable gc to avoid bug where gc -> file_dealloc ->
# write to stderr -> hang. http://bugs.python.org/issue1336
gc.disable()
try:
self.pid = os.fork()
except:
if gc_was_enabled:
gc.enable()
raise
self._child_created = True
if self.pid == 0:
# Child
try:
# Close parent's pipe ends
if p2cwrite is not None:
os.close(p2cwrite)
if c2pread is not None:
os.close(c2pread)
if errread is not None:
os.close(errread)
os.close(errpipe_read)
# When duping fds, if there arises a situation
# where one of the fds is either 0, 1 or 2, it
# is possible that it is overwritten (#12607).
if c2pwrite == 0:
c2pwrite = os.dup(c2pwrite)
if errwrite == 0 or errwrite == 1:
errwrite = os.dup(errwrite)
# Dup fds for child
def _dup2(a, b):
# dup2() removes the CLOEXEC flag but
# we must do it ourselves if dup2()
# would be a no-op (issue #10806).
if a == b:
self._set_cloexec_flag(a, False)
elif a is not None:
os.dup2(a, b)
_dup2(p2cread, 0)
_dup2(c2pwrite, 1)
_dup2(errwrite, 2)
# Close pipe fds. Make sure we don't close the
# same fd more than once, or standard fds.
closed = { None }
for fd in [p2cread, c2pwrite, errwrite]:
if fd not in closed and fd > 2:
os.close(fd)
closed.add(fd)
if cwd is not None:
os.chdir(cwd)
if preexec_fn:
preexec_fn()
# Close all other fds, if asked for - after
# preexec_fn(), which may open FDs.
if close_fds:
self._close_fds(but=errpipe_write)
if env is None:
os.execvp(executable, args)
else:
os.execvpe(executable, args, env)
except:
exc_type, exc_value, tb = sys.exc_info()
# Save the traceback and attach it to the exception object
exc_lines = traceback.format_exception(exc_type,
exc_value,
tb)
exc_value.child_traceback = ''.join(exc_lines)
os.write(errpipe_write, pickle.dumps(exc_value))
# This exitcode won't be reported to applications, so it
# really doesn't matter what we return.
os._exit(255)
# Parent
if gc_was_enabled:
gc.enable()
finally:
# be sure the FD is closed no matter what
os.close(errpipe_write)
# Wait for exec to fail or succeed; possibly raising exception
data = _eintr_retry_call(os.read, errpipe_read, 1048576)
pickle_bits = []
while data:
pickle_bits.append(data)
data = _eintr_retry_call(os.read, errpipe_read, 1048576)
data = "".join(pickle_bits)
finally:
if p2cread is not None and p2cwrite is not None:
_close_in_parent(p2cread)
if c2pwrite is not None and c2pread is not None:
_close_in_parent(c2pwrite)
if errwrite is not None and errread is not None:
_close_in_parent(errwrite)
# be sure the FD is closed no matter what
os.close(errpipe_read)
if data != "":
try:
_eintr_retry_call(os.waitpid, self.pid, 0)
except OSError as e:
if e.errno != errno.ECHILD:
raise
child_exception = pickle.loads(data)
> raise child_exception
E OSError: [Errno 2] No such file or directory
/usr/lib64/python2.7/subprocess.py:1024: OSError
---------------------------- Captured stdout setup -----------------------------
cmd 'git init'
________________ ERROR at setup of test_git_shallow_autocorrect ________________
wd = <conftest.Wd object at 0x7fb5e1d4ef10>
@pytest.fixture
def wd(wd):
> wd('git init')
testing/test_git.py:10:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
testing/conftest.py:30: in __call__
return do(cmd, self.cwd)
setuptools_scm/utils.py:79: in do
out, err, ret = do_ex(cmd, cwd)
setuptools_scm/utils.py:67: in do_ex
p = _popen_pipes(cmd, cwd)
setuptools_scm/utils.py:57: in _popen_pipes
HGPLAIN='1',
/usr/lib64/python2.7/subprocess.py:390: in __init__
errread, errwrite)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
self = <subprocess.Popen object at 0x7fb5e1d4e950>, args = ['git', 'init']
executable = 'git', preexec_fn = None, close_fds = False
cwd = '/tmp/B.HVALGw/BUILD/tmp/pytest-of-builder/pytest-0/test_git_shallow_autocorrect0/wd'
env = {'CC': 'x86_64-pld-linux-gcc', 'CFLAGS': ' -O2 -fwrapv -pipe -Wformat -Werror=format-security -gdwarf-4 -fno-debug-typ...es/Java:/usr/local/lib64/GNUstep/Libraries/Java:/usr/lib64/GNUstep/Libraries/Java', 'CXX': 'x86_64-pld-linux-g++', ...}
universal_newlines = False, startupinfo = None, creationflags = 0, shell = False
to_close = set([9, 12]), p2cread = None, p2cwrite = None, c2pread = 9
c2pwrite = 11, errread = 12, errwrite = 13
def _execute_child(self, args, executable, preexec_fn, close_fds,
cwd, env, universal_newlines,
startupinfo, creationflags, shell, to_close,
p2cread, p2cwrite,
c2pread, c2pwrite,
errread, errwrite):
"""Execute program (POSIX version)"""
if isinstance(args, types.StringTypes):
args = [args]
else:
args = list(args)
if shell:
args = ["/bin/sh", "-c"] + args
if executable:
args[0] = executable
if executable is None:
executable = args[0]
def _close_in_parent(fd):
os.close(fd)
to_close.remove(fd)
# For transferring possible exec failure from child to parent
# The first char specifies the exception type: 0 means
# OSError, 1 means some other error.
errpipe_read, errpipe_write = self.pipe_cloexec()
try:
try:
gc_was_enabled = gc.isenabled()
# Disable gc to avoid bug where gc -> file_dealloc ->
# write to stderr -> hang. http://bugs.python.org/issue1336
gc.disable()
try:
self.pid = os.fork()
except:
if gc_was_enabled:
gc.enable()
raise
self._child_created = True
if self.pid == 0:
# Child
try:
# Close parent's pipe ends
if p2cwrite is not None:
os.close(p2cwrite)
if c2pread is not None:
os.close(c2pread)
if errread is not None:
os.close(errread)
os.close(errpipe_read)
# When duping fds, if there arises a situation
# where one of the fds is either 0, 1 or 2, it
# is possible that it is overwritten (#12607).
if c2pwrite == 0:
c2pwrite = os.dup(c2pwrite)
if errwrite == 0 or errwrite == 1:
errwrite = os.dup(errwrite)
# Dup fds for child
def _dup2(a, b):
# dup2() removes the CLOEXEC flag but
# we must do it ourselves if dup2()
# would be a no-op (issue #10806).
if a == b:
self._set_cloexec_flag(a, False)
elif a is not None:
os.dup2(a, b)
_dup2(p2cread, 0)
_dup2(c2pwrite, 1)
_dup2(errwrite, 2)
# Close pipe fds. Make sure we don't close the
# same fd more than once, or standard fds.
closed = { None }
for fd in [p2cread, c2pwrite, errwrite]:
if fd not in closed and fd > 2:
os.close(fd)
closed.add(fd)
if cwd is not None:
os.chdir(cwd)
if preexec_fn:
preexec_fn()
# Close all other fds, if asked for - after
# preexec_fn(), which may open FDs.
if close_fds:
self._close_fds(but=errpipe_write)
if env is None:
os.execvp(executable, args)
else:
os.execvpe(executable, args, env)
except:
exc_type, exc_value, tb = sys.exc_info()
# Save the traceback and attach it to the exception object
exc_lines = traceback.format_exception(exc_type,
exc_value,
tb)
exc_value.child_traceback = ''.join(exc_lines)
os.write(errpipe_write, pickle.dumps(exc_value))
# This exitcode won't be reported to applications, so it
# really doesn't matter what we return.
os._exit(255)
# Parent
if gc_was_enabled:
gc.enable()
finally:
# be sure the FD is closed no matter what
os.close(errpipe_write)
# Wait for exec to fail or succeed; possibly raising exception
data = _eintr_retry_call(os.read, errpipe_read, 1048576)
pickle_bits = []
while data:
pickle_bits.append(data)
data = _eintr_retry_call(os.read, errpipe_read, 1048576)
data = "".join(pickle_bits)
finally:
if p2cread is not None and p2cwrite is not None:
_close_in_parent(p2cread)
if c2pwrite is not None and c2pread is not None:
_close_in_parent(c2pwrite)
if errwrite is not None and errread is not None:
_close_in_parent(errwrite)
# be sure the FD is closed no matter what
os.close(errpipe_read)
if data != "":
try:
_eintr_retry_call(os.waitpid, self.pid, 0)
except OSError as e:
if e.errno != errno.ECHILD:
raise
child_exception = pickle.loads(data)
> raise child_exception
E OSError: [Errno 2] No such file or directory
/usr/lib64/python2.7/subprocess.py:1024: OSError
---------------------------- Captured stdout setup -----------------------------
cmd 'git init'
______________ ERROR at setup of test_find_files_stop_at_root_git ______________
wd = <conftest.Wd object at 0x7fb5e1c21910>
@pytest.fixture
def wd(wd):
> wd('git init')
testing/test_git.py:10:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
testing/conftest.py:30: in __call__
return do(cmd, self.cwd)
setuptools_scm/utils.py:79: in do
out, err, ret = do_ex(cmd, cwd)
setuptools_scm/utils.py:67: in do_ex
p = _popen_pipes(cmd, cwd)
setuptools_scm/utils.py:57: in _popen_pipes
HGPLAIN='1',
/usr/lib64/python2.7/subprocess.py:390: in __init__
errread, errwrite)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
self = <subprocess.Popen object at 0x7fb5e1c21a10>, args = ['git', 'init']
executable = 'git', preexec_fn = None, close_fds = False
cwd = '/tmp/B.HVALGw/BUILD/tmp/pytest-of-builder/pytest-0/test_find_files_stop_at_root_g0/wd'
env = {'CC': 'x86_64-pld-linux-gcc', 'CFLAGS': ' -O2 -fwrapv -pipe -Wformat -Werror=format-security -gdwarf-4 -fno-debug-typ...es/Java:/usr/local/lib64/GNUstep/Libraries/Java:/usr/lib64/GNUstep/Libraries/Java', 'CXX': 'x86_64-pld-linux-g++', ...}
universal_newlines = False, startupinfo = None, creationflags = 0, shell = False
to_close = set([9, 12]), p2cread = None, p2cwrite = None, c2pread = 9
c2pwrite = 11, errread = 12, errwrite = 13
def _execute_child(self, args, executable, preexec_fn, close_fds,
cwd, env, universal_newlines,
startupinfo, creationflags, shell, to_close,
p2cread, p2cwrite,
c2pread, c2pwrite,
errread, errwrite):
"""Execute program (POSIX version)"""
if isinstance(args, types.StringTypes):
args = [args]
else:
args = list(args)
if shell:
args = ["/bin/sh", "-c"] + args
if executable:
args[0] = executable
if executable is None:
executable = args[0]
def _close_in_parent(fd):
os.close(fd)
to_close.remove(fd)
# For transferring possible exec failure from child to parent
# The first char specifies the exception type: 0 means
# OSError, 1 means some other error.
errpipe_read, errpipe_write = self.pipe_cloexec()
try:
try:
gc_was_enabled = gc.isenabled()
# Disable gc to avoid bug where gc -> file_dealloc ->
# write to stderr -> hang. http://bugs.python.org/issue1336
gc.disable()
try:
self.pid = os.fork()
except:
if gc_was_enabled:
gc.enable()
raise
self._child_created = True
if self.pid == 0:
# Child
try:
# Close parent's pipe ends
if p2cwrite is not None:
os.close(p2cwrite)
if c2pread is not None:
os.close(c2pread)
if errread is not None:
os.close(errread)
os.close(errpipe_read)
# When duping fds, if there arises a situation
# where one of the fds is either 0, 1 or 2, it
# is possible that it is overwritten (#12607).
if c2pwrite == 0:
c2pwrite = os.dup(c2pwrite)
if errwrite == 0 or errwrite == 1:
errwrite = os.dup(errwrite)
# Dup fds for child
def _dup2(a, b):
# dup2() removes the CLOEXEC flag but
# we must do it ourselves if dup2()
# would be a no-op (issue #10806).
if a == b:
self._set_cloexec_flag(a, False)
elif a is not None:
os.dup2(a, b)
_dup2(p2cread, 0)
_dup2(c2pwrite, 1)
_dup2(errwrite, 2)
# Close pipe fds. Make sure we don't close the
# same fd more than once, or standard fds.
closed = { None }
for fd in [p2cread, c2pwrite, errwrite]:
if fd not in closed and fd > 2:
os.close(fd)
closed.add(fd)
if cwd is not None:
os.chdir(cwd)
if preexec_fn:
preexec_fn()
# Close all other fds, if asked for - after
# preexec_fn(), which may open FDs.
if close_fds:
self._close_fds(but=errpipe_write)
if env is None:
os.execvp(executable, args)
else:
os.execvpe(executable, args, env)
except:
exc_type, exc_value, tb = sys.exc_info()
# Save the traceback and attach it to the exception object
exc_lines = traceback.format_exception(exc_type,
exc_value,
tb)
exc_value.child_traceback = ''.join(exc_lines)
os.write(errpipe_write, pickle.dumps(exc_value))
# This exitcode won't be reported to applications, so it
# really doesn't matter what we return.
os._exit(255)
# Parent
if gc_was_enabled:
gc.enable()
finally:
# be sure the FD is closed no matter what
os.close(errpipe_write)
# Wait for exec to fail or succeed; possibly raising exception
data = _eintr_retry_call(os.read, errpipe_read, 1048576)
pickle_bits = []
while data:
pickle_bits.append(data)
data = _eintr_retry_call(os.read, errpipe_read, 1048576)
data = "".join(pickle_bits)
finally:
if p2cread is not None and p2cwrite is not None:
_close_in_parent(p2cread)
if c2pwrite is not None and c2pread is not None:
_close_in_parent(c2pwrite)
if errwrite is not None and errread is not None:
_close_in_parent(errwrite)
# be sure the FD is closed no matter what
os.close(errpipe_read)
if data != "":
try:
_eintr_retry_call(os.waitpid, self.pid, 0)
except OSError as e:
if e.errno != errno.ECHILD:
raise
child_exception = pickle.loads(data)
> raise child_exception
E OSError: [Errno 2] No such file or directory
/usr/lib64/python2.7/subprocess.py:1024: OSError
---------------------------- Captured stdout setup -----------------------------
cmd 'git init'
________________ ERROR at setup of test_alphanumeric_tags_match ________________
wd = <conftest.Wd object at 0x7fb5e1d4e110>
@pytest.fixture
def wd(wd):
> wd('git init')
testing/test_git.py:10:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
testing/conftest.py:30: in __call__
return do(cmd, self.cwd)
setuptools_scm/utils.py:79: in do
out, err, ret = do_ex(cmd, cwd)
setuptools_scm/utils.py:67: in do_ex
p = _popen_pipes(cmd, cwd)
setuptools_scm/utils.py:57: in _popen_pipes
HGPLAIN='1',
/usr/lib64/python2.7/subprocess.py:390: in __init__
errread, errwrite)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
self = <subprocess.Popen object at 0x7fb5e1d4ed90>, args = ['git', 'init']
executable = 'git', preexec_fn = None, close_fds = False
cwd = '/tmp/B.HVALGw/BUILD/tmp/pytest-of-builder/pytest-0/test_alphanumeric_tags_match0/wd'
env = {'CC': 'x86_64-pld-linux-gcc', 'CFLAGS': ' -O2 -fwrapv -pipe -Wformat -Werror=format-security -gdwarf-4 -fno-debug-typ...es/Java:/usr/local/lib64/GNUstep/Libraries/Java:/usr/lib64/GNUstep/Libraries/Java', 'CXX': 'x86_64-pld-linux-g++', ...}
universal_newlines = False, startupinfo = None, creationflags = 0, shell = False
to_close = set([9, 12]), p2cread = None, p2cwrite = None, c2pread = 9
c2pwrite = 11, errread = 12, errwrite = 13
def _execute_child(self, args, executable, preexec_fn, close_fds,
cwd, env, universal_newlines,
startupinfo, creationflags, shell, to_close,
p2cread, p2cwrite,
c2pread, c2pwrite,
errread, errwrite):
"""Execute program (POSIX version)"""
if isinstance(args, types.StringTypes):
args = [args]
else:
args = list(args)
if shell:
args = ["/bin/sh", "-c"] + args
if executable:
args[0] = executable
if executable is None:
executable = args[0]
def _close_in_parent(fd):
os.close(fd)
to_close.remove(fd)
# For transferring possible exec failure from child to parent
# The first char specifies the exception type: 0 means
# OSError, 1 means some other error.
errpipe_read, errpipe_write = self.pipe_cloexec()
try:
try:
gc_was_enabled = gc.isenabled()
# Disable gc to avoid bug where gc -> file_dealloc ->
# write to stderr -> hang. http://bugs.python.org/issue1336
gc.disable()
try:
self.pid = os.fork()
except:
if gc_was_enabled:
gc.enable()
raise
self._child_created = True
if self.pid == 0:
# Child
try:
# Close parent's pipe ends
if p2cwrite is not None:
os.close(p2cwrite)
if c2pread is not None:
os.close(c2pread)
if errread is not None:
os.close(errread)
os.close(errpipe_read)
# When duping fds, if there arises a situation
# where one of the fds is either 0, 1 or 2, it
# is possible that it is overwritten (#12607).
if c2pwrite == 0:
c2pwrite = os.dup(c2pwrite)
if errwrite == 0 or errwrite == 1:
errwrite = os.dup(errwrite)
# Dup fds for child
def _dup2(a, b):
# dup2() removes the CLOEXEC flag but
# we must do it ourselves if dup2()
# would be a no-op (issue #10806).
if a == b:
self._set_cloexec_flag(a, False)
elif a is not None:
os.dup2(a, b)
_dup2(p2cread, 0)
_dup2(c2pwrite, 1)
_dup2(errwrite, 2)
# Close pipe fds. Make sure we don't close the
# same fd more than once, or standard fds.
closed = { None }
for fd in [p2cread, c2pwrite, errwrite]:
if fd not in closed and fd > 2:
os.close(fd)
closed.add(fd)
if cwd is not None:
os.chdir(cwd)
if preexec_fn:
preexec_fn()
# Close all other fds, if asked for - after
# preexec_fn(), which may open FDs.
if close_fds:
self._close_fds(but=errpipe_write)
if env is None:
os.execvp(executable, args)
else:
os.execvpe(executable, args, env)
except:
exc_type, exc_value, tb = sys.exc_info()
# Save the traceback and attach it to the exception object
exc_lines = traceback.format_exception(exc_type,
exc_value,
tb)
exc_value.child_traceback = ''.join(exc_lines)
os.write(errpipe_write, pickle.dumps(exc_value))
# This exitcode won't be reported to applications, so it
# really doesn't matter what we return.
os._exit(255)
# Parent
if gc_was_enabled:
gc.enable()
finally:
# be sure the FD is closed no matter what
os.close(errpipe_write)
# Wait for exec to fail or succeed; possibly raising exception
data = _eintr_retry_call(os.read, errpipe_read, 1048576)
pickle_bits = []
while data:
pickle_bits.append(data)
data = _eintr_retry_call(os.read, errpipe_read, 1048576)
data = "".join(pickle_bits)
finally:
if p2cread is not None and p2cwrite is not None:
_close_in_parent(p2cread)
if c2pwrite is not None and c2pread is not None:
_close_in_parent(c2pwrite)
if errwrite is not None and errread is not None:
_close_in_parent(errwrite)
# be sure the FD is closed no matter what
os.close(errpipe_read)
if data != "":
try:
_eintr_retry_call(os.waitpid, self.pid, 0)
except OSError as e:
if e.errno != errno.ECHILD:
raise
child_exception = pickle.loads(data)
> raise child_exception
E OSError: [Errno 2] No such file or directory
/usr/lib64/python2.7/subprocess.py:1024: OSError
---------------------------- Captured stdout setup -----------------------------
cmd 'git init'
______________ ERROR at setup of test_find_files_stop_at_root_hg _______________
wd = <conftest.Wd object at 0x7fb5e1ce82d0>
@pytest.fixture
def wd(wd):
> wd('hg init')
testing/test_mercurial.py:10:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
testing/conftest.py:30: in __call__
return do(cmd, self.cwd)
setuptools_scm/utils.py:79: in do
out, err, ret = do_ex(cmd, cwd)
setuptools_scm/utils.py:67: in do_ex
p = _popen_pipes(cmd, cwd)
setuptools_scm/utils.py:57: in _popen_pipes
HGPLAIN='1',
/usr/lib64/python2.7/subprocess.py:390: in __init__
errread, errwrite)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
self = <subprocess.Popen object at 0x7fb5e1ce8b10>, args = ['hg', 'init']
executable = 'hg', preexec_fn = None, close_fds = False
cwd = '/tmp/B.HVALGw/BUILD/tmp/pytest-of-builder/pytest-0/test_find_files_stop_at_root_h0/wd'
env = {'CC': 'x86_64-pld-linux-gcc', 'CFLAGS': ' -O2 -fwrapv -pipe -Wformat -Werror=format-security -gdwarf-4 -fno-debug-typ...es/Java:/usr/local/lib64/GNUstep/Libraries/Java:/usr/lib64/GNUstep/Libraries/Java', 'CXX': 'x86_64-pld-linux-g++', ...}
universal_newlines = False, startupinfo = None, creationflags = 0, shell = False
to_close = set([9, 12]), p2cread = None, p2cwrite = None, c2pread = 9
c2pwrite = 11, errread = 12, errwrite = 13
def _execute_child(self, args, executable, preexec_fn, close_fds,
cwd, env, universal_newlines,
startupinfo, creationflags, shell, to_close,
p2cread, p2cwrite,
c2pread, c2pwrite,
errread, errwrite):
"""Execute program (POSIX version)"""
if isinstance(args, types.StringTypes):
args = [args]
else:
args = list(args)
if shell:
args = ["/bin/sh", "-c"] + args
if executable:
args[0] = executable
if executable is None:
executable = args[0]
def _close_in_parent(fd):
os.close(fd)
to_close.remove(fd)
# For transferring possible exec failure from child to parent
# The first char specifies the exception type: 0 means
# OSError, 1 means some other error.
errpipe_read, errpipe_write = self.pipe_cloexec()
try:
try:
gc_was_enabled = gc.isenabled()
# Disable gc to avoid bug where gc -> file_dealloc ->
# write to stderr -> hang. http://bugs.python.org/issue1336
gc.disable()
try:
self.pid = os.fork()
except:
if gc_was_enabled:
gc.enable()
raise
self._child_created = True
if self.pid == 0:
# Child
try:
# Close parent's pipe ends
if p2cwrite is not None:
os.close(p2cwrite)
if c2pread is not None:
os.close(c2pread)
if errread is not None:
os.close(errread)
os.close(errpipe_read)
# When duping fds, if there arises a situation
# where one of the fds is either 0, 1 or 2, it
# is possible that it is overwritten (#12607).
if c2pwrite == 0:
c2pwrite = os.dup(c2pwrite)
if errwrite == 0 or errwrite == 1:
errwrite = os.dup(errwrite)
# Dup fds for child
def _dup2(a, b):
# dup2() removes the CLOEXEC flag but
# we must do it ourselves if dup2()
# would be a no-op (issue #10806).
if a == b:
self._set_cloexec_flag(a, False)
elif a is not None:
os.dup2(a, b)
_dup2(p2cread, 0)
_dup2(c2pwrite, 1)
_dup2(errwrite, 2)
# Close pipe fds. Make sure we don't close the
# same fd more than once, or standard fds.
closed = { None }
for fd in [p2cread, c2pwrite, errwrite]:
if fd not in closed and fd > 2:
os.close(fd)
closed.add(fd)
if cwd is not None:
os.chdir(cwd)
if preexec_fn:
preexec_fn()
# Close all other fds, if asked for - after
# preexec_fn(), which may open FDs.
if close_fds:
self._close_fds(but=errpipe_write)
if env is None:
os.execvp(executable, args)
else:
os.execvpe(executable, args, env)
except:
exc_type, exc_value, tb = sys.exc_info()
# Save the traceback and attach it to the exception object
exc_lines = traceback.format_exception(exc_type,
exc_value,
tb)
exc_value.child_traceback = ''.join(exc_lines)
os.write(errpipe_write, pickle.dumps(exc_value))
# This exitcode won't be reported to applications, so it
# really doesn't matter what we return.
os._exit(255)
# Parent
if gc_was_enabled:
gc.enable()
finally:
# be sure the FD is closed no matter what
os.close(errpipe_write)
# Wait for exec to fail or succeed; possibly raising exception
data = _eintr_retry_call(os.read, errpipe_read, 1048576)
pickle_bits = []
while data:
pickle_bits.append(data)
data = _eintr_retry_call(os.read, errpipe_read, 1048576)
data = "".join(pickle_bits)
finally:
if p2cread is not None and p2cwrite is not None:
_close_in_parent(p2cread)
if c2pwrite is not None and c2pread is not None:
_close_in_parent(c2pwrite)
if errwrite is not None and errread is not None:
_close_in_parent(errwrite)
# be sure the FD is closed no matter what
os.close(errpipe_read)
if data != "":
try:
_eintr_retry_call(os.waitpid, self.pid, 0)
except OSError as e:
if e.errno != errno.ECHILD:
raise
child_exception = pickle.loads(data)
> raise child_exception
E OSError: [Errno 2] No such file or directory
/usr/lib64/python2.7/subprocess.py:1024: OSError
---------------------------- Captured stdout setup -----------------------------
cmd 'hg init'
__________________ ERROR at setup of test_version_from_hg_id ___________________
wd = <conftest.Wd object at 0x7fb5e1d4ad90>
@pytest.fixture
def wd(wd):
> wd('hg init')
testing/test_mercurial.py:10:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
testing/conftest.py:30: in __call__
return do(cmd, self.cwd)
setuptools_scm/utils.py:79: in do
out, err, ret = do_ex(cmd, cwd)
setuptools_scm/utils.py:67: in do_ex
p = _popen_pipes(cmd, cwd)
setuptools_scm/utils.py:57: in _popen_pipes
HGPLAIN='1',
/usr/lib64/python2.7/subprocess.py:390: in __init__
errread, errwrite)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
self = <subprocess.Popen object at 0x7fb5e1d4a390>, args = ['hg', 'init']
executable = 'hg', preexec_fn = None, close_fds = False
cwd = '/tmp/B.HVALGw/BUILD/tmp/pytest-of-builder/pytest-0/test_version_from_hg_id0/wd'
env = {'CC': 'x86_64-pld-linux-gcc', 'CFLAGS': ' -O2 -fwrapv -pipe -Wformat -Werror=format-security -gdwarf-4 -fno-debug-typ...es/Java:/usr/local/lib64/GNUstep/Libraries/Java:/usr/lib64/GNUstep/Libraries/Java', 'CXX': 'x86_64-pld-linux-g++', ...}
universal_newlines = False, startupinfo = None, creationflags = 0, shell = False
to_close = set([9, 12]), p2cread = None, p2cwrite = None, c2pread = 9
c2pwrite = 11, errread = 12, errwrite = 13
def _execute_child(self, args, executable, preexec_fn, close_fds,
cwd, env, universal_newlines,
startupinfo, creationflags, shell, to_close,
p2cread, p2cwrite,
c2pread, c2pwrite,
errread, errwrite):
"""Execute program (POSIX version)"""
if isinstance(args, types.StringTypes):
args = [args]
else:
args = list(args)
if shell:
args = ["/bin/sh", "-c"] + args
if executable:
args[0] = executable
if executable is None:
executable = args[0]
def _close_in_parent(fd):
os.close(fd)
to_close.remove(fd)
# For transferring possible exec failure from child to parent
# The first char specifies the exception type: 0 means
# OSError, 1 means some other error.
errpipe_read, errpipe_write = self.pipe_cloexec()
try:
try:
gc_was_enabled = gc.isenabled()
# Disable gc to avoid bug where gc -> file_dealloc ->
# write to stderr -> hang. http://bugs.python.org/issue1336
gc.disable()
try:
self.pid = os.fork()
except:
if gc_was_enabled:
gc.enable()
raise
self._child_created = True
if self.pid == 0:
# Child
try:
# Close parent's pipe ends
if p2cwrite is not None:
os.close(p2cwrite)
if c2pread is not None:
os.close(c2pread)
if errread is not None:
os.close(errread)
os.close(errpipe_read)
# When duping fds, if there arises a situation
# where one of the fds is either 0, 1 or 2, it
# is possible that it is overwritten (#12607).
if c2pwrite == 0:
c2pwrite = os.dup(c2pwrite)
if errwrite == 0 or errwrite == 1:
errwrite = os.dup(errwrite)
# Dup fds for child
def _dup2(a, b):
# dup2() removes the CLOEXEC flag but
# we must do it ourselves if dup2()
# would be a no-op (issue #10806).
if a == b:
self._set_cloexec_flag(a, False)
elif a is not None:
os.dup2(a, b)
_dup2(p2cread, 0)
_dup2(c2pwrite, 1)
_dup2(errwrite, 2)
# Close pipe fds. Make sure we don't close the
# same fd more than once, or standard fds.
closed = { None }
for fd in [p2cread, c2pwrite, errwrite]:
if fd not in closed and fd > 2:
os.close(fd)
closed.add(fd)
if cwd is not None:
os.chdir(cwd)
if preexec_fn:
preexec_fn()
# Close all other fds, if asked for - after
# preexec_fn(), which may open FDs.
if close_fds:
self._close_fds(but=errpipe_write)
if env is None:
os.execvp(executable, args)
else:
os.execvpe(executable, args, env)
except:
exc_type, exc_value, tb = sys.exc_info()
# Save the traceback and attach it to the exception object
exc_lines = traceback.format_exception(exc_type,
exc_value,
tb)
exc_value.child_traceback = ''.join(exc_lines)
os.write(errpipe_write, pickle.dumps(exc_value))
# This exitcode won't be reported to applications, so it
# really doesn't matter what we return.
os._exit(255)
# Parent
if gc_was_enabled:
gc.enable()
finally:
# be sure the FD is closed no matter what
os.close(errpipe_write)
# Wait for exec to fail or succeed; possibly raising exception
data = _eintr_retry_call(os.read, errpipe_read, 1048576)
pickle_bits = []
while data:
pickle_bits.append(data)
data = _eintr_retry_call(os.read, errpipe_read, 1048576)
data = "".join(pickle_bits)
finally:
if p2cread is not None and p2cwrite is not None:
_close_in_parent(p2cread)
if c2pwrite is not None and c2pread is not None:
_close_in_parent(c2pwrite)
if errwrite is not None and errread is not None:
_close_in_parent(errwrite)
# be sure the FD is closed no matter what
os.close(errpipe_read)
if data != "":
try:
_eintr_retry_call(os.waitpid, self.pid, 0)
except OSError as e:
if e.errno != errno.ECHILD:
raise
child_exception = pickle.loads(data)
> raise child_exception
E OSError: [Errno 2] No such file or directory
/usr/lib64/python2.7/subprocess.py:1024: OSError
---------------------------- Captured stdout setup -----------------------------
cmd 'hg init'
_________________ ERROR at setup of test_version_from_archival _________________
wd = <conftest.Wd object at 0x7fb5e1d5bed0>
@pytest.fixture
def wd(wd):
> wd('hg init')
testing/test_mercurial.py:10:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
testing/conftest.py:30: in __call__
return do(cmd, self.cwd)
setuptools_scm/utils.py:79: in do
out, err, ret = do_ex(cmd, cwd)
setuptools_scm/utils.py:67: in do_ex
p = _popen_pipes(cmd, cwd)
setuptools_scm/utils.py:57: in _popen_pipes
HGPLAIN='1',
/usr/lib64/python2.7/subprocess.py:390: in __init__
errread, errwrite)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
self = <subprocess.Popen object at 0x7fb5e1d5b890>, args = ['hg', 'init']
executable = 'hg', preexec_fn = None, close_fds = False
cwd = '/tmp/B.HVALGw/BUILD/tmp/pytest-of-builder/pytest-0/test_version_from_archival0/wd'
env = {'CC': 'x86_64-pld-linux-gcc', 'CFLAGS': ' -O2 -fwrapv -pipe -Wformat -Werror=format-security -gdwarf-4 -fno-debug-typ...es/Java:/usr/local/lib64/GNUstep/Libraries/Java:/usr/lib64/GNUstep/Libraries/Java', 'CXX': 'x86_64-pld-linux-g++', ...}
universal_newlines = False, startupinfo = None, creationflags = 0, shell = False
to_close = set([9, 12]), p2cread = None, p2cwrite = None, c2pread = 9
c2pwrite = 11, errread = 12, errwrite = 13
def _execute_child(self, args, executable, preexec_fn, close_fds,
cwd, env, universal_newlines,
startupinfo, creationflags, shell, to_close,
p2cread, p2cwrite,
c2pread, c2pwrite,
errread, errwrite):
"""Execute program (POSIX version)"""
if isinstance(args, types.StringTypes):
args = [args]
else:
args = list(args)
if shell:
args = ["/bin/sh", "-c"] + args
if executable:
args[0] = executable
if executable is None:
executable = args[0]
def _close_in_parent(fd):
os.close(fd)
to_close.remove(fd)
# For transferring possible exec failure from child to parent
# The first char specifies the exception type: 0 means
# OSError, 1 means some other error.
errpipe_read, errpipe_write = self.pipe_cloexec()
try:
try:
gc_was_enabled = gc.isenabled()
# Disable gc to avoid bug where gc -> file_dealloc ->
# write to stderr -> hang. http://bugs.python.org/issue1336
gc.disable()
try:
self.pid = os.fork()
except:
if gc_was_enabled:
gc.enable()
raise
self._child_created = True
if self.pid == 0:
# Child
try:
# Close parent's pipe ends
if p2cwrite is not None:
os.close(p2cwrite)
if c2pread is not None:
os.close(c2pread)
if errread is not None:
os.close(errread)
os.close(errpipe_read)
# When duping fds, if there arises a situation
# where one of the fds is either 0, 1 or 2, it
# is possible that it is overwritten (#12607).
if c2pwrite == 0:
c2pwrite = os.dup(c2pwrite)
if errwrite == 0 or errwrite == 1:
errwrite = os.dup(errwrite)
# Dup fds for child
def _dup2(a, b):
# dup2() removes the CLOEXEC flag but
# we must do it ourselves if dup2()
# would be a no-op (issue #10806).
if a == b:
self._set_cloexec_flag(a, False)
elif a is not None:
os.dup2(a, b)
_dup2(p2cread, 0)
_dup2(c2pwrite, 1)
_dup2(errwrite, 2)
# Close pipe fds. Make sure we don't close the
# same fd more than once, or standard fds.
closed = { None }
for fd in [p2cread, c2pwrite, errwrite]:
if fd not in closed and fd > 2:
os.close(fd)
closed.add(fd)
if cwd is not None:
os.chdir(cwd)
if preexec_fn:
preexec_fn()
# Close all other fds, if asked for - after
# preexec_fn(), which may open FDs.
if close_fds:
self._close_fds(but=errpipe_write)
if env is None:
os.execvp(executable, args)
else:
os.execvpe(executable, args, env)
except:
exc_type, exc_value, tb = sys.exc_info()
# Save the traceback and attach it to the exception object
exc_lines = traceback.format_exception(exc_type,
exc_value,
tb)
exc_value.child_traceback = ''.join(exc_lines)
os.write(errpipe_write, pickle.dumps(exc_value))
# This exitcode won't be reported to applications, so it
# really doesn't matter what we return.
os._exit(255)
# Parent
if gc_was_enabled:
gc.enable()
finally:
# be sure the FD is closed no matter what
os.close(errpipe_write)
# Wait for exec to fail or succeed; possibly raising exception
data = _eintr_retry_call(os.read, errpipe_read, 1048576)
pickle_bits = []
while data:
pickle_bits.append(data)
data = _eintr_retry_call(os.read, errpipe_read, 1048576)
data = "".join(pickle_bits)
finally:
if p2cread is not None and p2cwrite is not None:
_close_in_parent(p2cread)
if c2pwrite is not None and c2pread is not None:
_close_in_parent(c2pwrite)
if errwrite is not None and errread is not None:
_close_in_parent(errwrite)
# be sure the FD is closed no matter what
os.close(errpipe_read)
if data != "":
try:
_eintr_retry_call(os.waitpid, self.pid, 0)
except OSError as e:
if e.errno != errno.ECHILD:
raise
child_exception = pickle.loads(data)
> raise child_exception
E OSError: [Errno 2] No such file or directory
/usr/lib64/python2.7/subprocess.py:1024: OSError
---------------------------- Captured stdout setup -----------------------------
cmd 'hg init'
___________________ ERROR at setup of test_version_in_merge ____________________
wd = <conftest.Wd object at 0x7fb5e1d548d0>
@pytest.fixture
def wd(wd):
> wd('hg init')
testing/test_mercurial.py:10:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
testing/conftest.py:30: in __call__
return do(cmd, self.cwd)
setuptools_scm/utils.py:79: in do
out, err, ret = do_ex(cmd, cwd)
setuptools_scm/utils.py:67: in do_ex
p = _popen_pipes(cmd, cwd)
setuptools_scm/utils.py:57: in _popen_pipes
HGPLAIN='1',
/usr/lib64/python2.7/subprocess.py:390: in __init__
errread, errwrite)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
self = <subprocess.Popen object at 0x7fb5e1d54bd0>, args = ['hg', 'init']
executable = 'hg', preexec_fn = None, close_fds = False
cwd = '/tmp/B.HVALGw/BUILD/tmp/pytest-of-builder/pytest-0/test_version_in_merge0/wd'
env = {'CC': 'x86_64-pld-linux-gcc', 'CFLAGS': ' -O2 -fwrapv -pipe -Wformat -Werror=format-security -gdwarf-4 -fno-debug-typ...es/Java:/usr/local/lib64/GNUstep/Libraries/Java:/usr/lib64/GNUstep/Libraries/Java', 'CXX': 'x86_64-pld-linux-g++', ...}
universal_newlines = False, startupinfo = None, creationflags = 0, shell = False
to_close = set([9, 12]), p2cread = None, p2cwrite = None, c2pread = 9
c2pwrite = 11, errread = 12, errwrite = 13
def _execute_child(self, args, executable, preexec_fn, close_fds,
cwd, env, universal_newlines,
startupinfo, creationflags, shell, to_close,
p2cread, p2cwrite,
c2pread, c2pwrite,
errread, errwrite):
"""Execute program (POSIX version)"""
if isinstance(args, types.StringTypes):
args = [args]
else:
args = list(args)
if shell:
args = ["/bin/sh", "-c"] + args
if executable:
args[0] = executable
if executable is None:
executable = args[0]
def _close_in_parent(fd):
os.close(fd)
to_close.remove(fd)
# For transferring possible exec failure from child to parent
# The first char specifies the exception type: 0 means
# OSError, 1 means some other error.
errpipe_read, errpipe_write = self.pipe_cloexec()
try:
try:
gc_was_enabled = gc.isenabled()
# Disable gc to avoid bug where gc -> file_dealloc ->
# write to stderr -> hang. http://bugs.python.org/issue1336
gc.disable()
try:
self.pid = os.fork()
except:
if gc_was_enabled:
gc.enable()
raise
self._child_created = True
if self.pid == 0:
# Child
try:
# Close parent's pipe ends
if p2cwrite is not None:
os.close(p2cwrite)
if c2pread is not None:
os.close(c2pread)
if errread is not None:
os.close(errread)
os.close(errpipe_read)
# When duping fds, if there arises a situation
# where one of the fds is either 0, 1 or 2, it
# is possible that it is overwritten (#12607).
if c2pwrite == 0:
c2pwrite = os.dup(c2pwrite)
if errwrite == 0 or errwrite == 1:
errwrite = os.dup(errwrite)
# Dup fds for child
def _dup2(a, b):
# dup2() removes the CLOEXEC flag but
# we must do it ourselves if dup2()
# would be a no-op (issue #10806).
if a == b:
self._set_cloexec_flag(a, False)
elif a is not None:
os.dup2(a, b)
_dup2(p2cread, 0)
_dup2(c2pwrite, 1)
_dup2(errwrite, 2)
# Close pipe fds. Make sure we don't close the
# same fd more than once, or standard fds.
closed = { None }
for fd in [p2cread, c2pwrite, errwrite]:
if fd not in closed and fd > 2:
os.close(fd)
closed.add(fd)
if cwd is not None:
os.chdir(cwd)
if preexec_fn:
preexec_fn()
# Close all other fds, if asked for - after
# preexec_fn(), which may open FDs.
if close_fds:
self._close_fds(but=errpipe_write)
if env is None:
os.execvp(executable, args)
else:
os.execvpe(executable, args, env)
except:
exc_type, exc_value, tb = sys.exc_info()
# Save the traceback and attach it to the exception object
exc_lines = traceback.format_exception(exc_type,
exc_value,
tb)
exc_value.child_traceback = ''.join(exc_lines)
os.write(errpipe_write, pickle.dumps(exc_value))
# This exitcode won't be reported to applications, so it
# really doesn't matter what we return.
os._exit(255)
# Parent
if gc_was_enabled:
gc.enable()
finally:
# be sure the FD is closed no matter what
os.close(errpipe_write)
# Wait for exec to fail or succeed; possibly raising exception
data = _eintr_retry_call(os.read, errpipe_read, 1048576)
pickle_bits = []
while data:
pickle_bits.append(data)
data = _eintr_retry_call(os.read, errpipe_read, 1048576)
data = "".join(pickle_bits)
finally:
if p2cread is not None and p2cwrite is not None:
_close_in_parent(p2cread)
if c2pwrite is not None and c2pread is not None:
_close_in_parent(c2pwrite)
if errwrite is not None and errread is not None:
_close_in_parent(errwrite)
# be sure the FD is closed no matter what
os.close(errpipe_read)
if data != "":
try:
_eintr_retry_call(os.waitpid, self.pid, 0)
except OSError as e:
if e.errno != errno.ECHILD:
raise
child_exception = pickle.loads(data)
> raise child_exception
E OSError: [Errno 2] No such file or directory
/usr/lib64/python2.7/subprocess.py:1024: OSError
---------------------------- Captured stdout setup -----------------------------
cmd 'hg init'
=================================== FAILURES ===================================
____________________________ test_pkginfo_noscmroot ____________________________
tmpdir = local('/tmp/B.HVALGw/BUILD/tmp/pytest-of-builder/pytest-0/test_pkginfo_noscmroot0')
monkeypatch = <_pytest.monkeypatch.monkeypatch instance at 0x7fb5e1be5830>
def test_pkginfo_noscmroot(tmpdir, monkeypatch):
"""if we are indeed a sdist, the root does not apply"""
monkeypatch.delenv("SETUPTOOLS_SCM_DEBUG")
# we should get the version from pkg-info if git is broken
p = tmpdir.ensure('sub/package', dir=1)
tmpdir.mkdir('.git')
p.join('setup.py').write(
'from setuptools import setup;'
'setup(use_scm_version={"root": ".."})')
_, stderr, ret = do_ex('python setup.py --version', p)
assert 'setuptools-scm was unable to detect version for' in stderr
assert ret == 1
p.join("PKG-INFO").write('Version: 1.0')
res = do('python setup.py --version', p)
assert res == '1.0'
> do('git init', p.dirpath())
testing/test_regressions.py:27:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
setuptools_scm/utils.py:79: in do
out, err, ret = do_ex(cmd, cwd)
setuptools_scm/utils.py:67: in do_ex
p = _popen_pipes(cmd, cwd)
setuptools_scm/utils.py:57: in _popen_pipes
HGPLAIN='1',
/usr/lib64/python2.7/subprocess.py:390: in __init__
errread, errwrite)
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
self = <subprocess.Popen object at 0x7fb5e1feb410>, args = ['git', 'init']
executable = 'git', preexec_fn = None, close_fds = False
cwd = '/tmp/B.HVALGw/BUILD/tmp/pytest-of-builder/pytest-0/test_pkginfo_noscmroot0/sub'
env = {'CC': 'x86_64-pld-linux-gcc', 'CFLAGS': ' -O2 -fwrapv -pipe -Wformat -Werror=format-security -gdwarf-4 -fno-debug-typ...es/Java:/usr/local/lib64/GNUstep/Libraries/Java:/usr/lib64/GNUstep/Libraries/Java', 'CXX': 'x86_64-pld-linux-g++', ...}
universal_newlines = False, startupinfo = None, creationflags = 0, shell = False
to_close = set([9, 12]), p2cread = None, p2cwrite = None, c2pread = 9
c2pwrite = 11, errread = 12, errwrite = 13
def _execute_child(self, args, executable, preexec_fn, close_fds,
cwd, env, universal_newlines,
startupinfo, creationflags, shell, to_close,
p2cread, p2cwrite,
c2pread, c2pwrite,
errread, errwrite):
"""Execute program (POSIX version)"""
if isinstance(args, types.StringTypes):
args = [args]
else:
args = list(args)
if shell:
args = ["/bin/sh", "-c"] + args
if executable:
args[0] = executable
if executable is None:
executable = args[0]
def _close_in_parent(fd):
os.close(fd)
to_close.remove(fd)
# For transferring possible exec failure from child to parent
# The first char specifies the exception type: 0 means
# OSError, 1 means some other error.
errpipe_read, errpipe_write = self.pipe_cloexec()
try:
try:
gc_was_enabled = gc.isenabled()
# Disable gc to avoid bug where gc -> file_dealloc ->
# write to stderr -> hang. http://bugs.python.org/issue1336
gc.disable()
try:
self.pid = os.fork()
except:
if gc_was_enabled:
gc.enable()
raise
self._child_created = True
if self.pid == 0:
# Child
try:
# Close parent's pipe ends
if p2cwrite is not None:
os.close(p2cwrite)
if c2pread is not None:
os.close(c2pread)
if errread is not None:
os.close(errread)
os.close(errpipe_read)
# When duping fds, if there arises a situation
# where one of the fds is either 0, 1 or 2, it
# is possible that it is overwritten (#12607).
if c2pwrite == 0:
c2pwrite = os.dup(c2pwrite)
if errwrite == 0 or errwrite == 1:
errwrite = os.dup(errwrite)
# Dup fds for child
def _dup2(a, b):
# dup2() removes the CLOEXEC flag but
# we must do it ourselves if dup2()
# would be a no-op (issue #10806).
if a == b:
self._set_cloexec_flag(a, False)
elif a is not None:
os.dup2(a, b)
_dup2(p2cread, 0)
_dup2(c2pwrite, 1)
_dup2(errwrite, 2)
# Close pipe fds. Make sure we don't close the
# same fd more than once, or standard fds.
closed = { None }
for fd in [p2cread, c2pwrite, errwrite]:
if fd not in closed and fd > 2:
os.close(fd)
closed.add(fd)
if cwd is not None:
os.chdir(cwd)
if preexec_fn:
preexec_fn()
# Close all other fds, if asked for - after
# preexec_fn(), which may open FDs.
if close_fds:
self._close_fds(but=errpipe_write)
if env is None:
os.execvp(executable, args)
else:
os.execvpe(executable, args, env)
except:
exc_type, exc_value, tb = sys.exc_info()
# Save the traceback and attach it to the exception object
exc_lines = traceback.format_exception(exc_type,
exc_value,
tb)
exc_value.child_traceback = ''.join(exc_lines)
os.write(errpipe_write, pickle.dumps(exc_value))
# This exitcode won't be reported to applications, so it
# really doesn't matter what we return.
os._exit(255)
# Parent
if gc_was_enabled:
gc.enable()
finally:
# be sure the FD is closed no matter what
os.close(errpipe_write)
# Wait for exec to fail or succeed; possibly raising exception
data = _eintr_retry_call(os.read, errpipe_read, 1048576)
pickle_bits = []
while data:
pickle_bits.append(data)
data = _eintr_retry_call(os.read, errpipe_read, 1048576)
data = "".join(pickle_bits)
finally:
if p2cread is not None and p2cwrite is not None:
_close_in_parent(p2cread)
if c2pwrite is not None and c2pread is not None:
_close_in_parent(c2pwrite)
if errwrite is not None and errread is not None:
_close_in_parent(errwrite)
# be sure the FD is closed no matter what
os.close(errpipe_read)
if data != "":
try:
_eintr_retry_call(os.waitpid, self.pid, 0)
except OSError as e:
if e.errno != errno.ECHILD:
raise
child_exception = pickle.loads(data)
> raise child_exception
E OSError: [Errno 2] No such file or directory
/usr/lib64/python2.7/subprocess.py:1024: OSError
----------------------------- Captured stdout call -----------------------------
cmd 'python setup.py --version'
err 'Traceback (most recent call last):\n File "setup.py", line 1, in <module>\n from setuptools import setup;setup(use_scm_version={"root": ".."})\n File "/usr/lib64/python2.7/distutils/core.py", line 111, in setup\n _setup_distribution = dist = klass(attrs)\n File "/usr/share/python2.7/site-packages/setuptools/dist.py", line 272, in __init__\n File "/usr/lib64/python2.7/distutils/dist.py", line 287, in __init__\n self.finalize_options()\n File "/usr/share/python2.7/site-packages/setuptools/dist.py", line 327, in finalize_options\n File "/usr/share/python2.7/site-packages/setuptools_scm/integration.py", line 19, in version_keyword\n File "/usr/share/python2.7/site-packages/setuptools_scm/__init__.py", line 104, in get_version\n File "/usr/share/python2.7/site-packages/setuptools_scm/__init__.py", line 82, in _do_parse\nLookupError: setuptools-scm was unable to detect version for \'/tmp/B.HVALGw/BUILD/tmp/pytest-of-builder/pytest-0/test_pkginfo_noscmroot0/sub\'.\n\nMake sure you\'re either building from a fully intact git repository or PyPI tarballs. Most other sources (such as GitHub\'s tarballs, a git checkout without the .git folder) don\'t contain the necessary metadata and will not work.\n\nFor example, if you\'re using pip, instead of https://github.com/user/proj/archive/master.zip use git+https://github.com/user/proj.git#egg=proj\n'
ret 1
cmd 'python setup.py --version'
out '1.0\n'
cmd 'git init'
=========== 1 failed, 33 passed, 1 skipped, 12 error in 2.43 seconds ===========
error: Bad exit status from /tmp/B.HVALGw/BUILD/tmp/rpm-tmp.47033 (%build)
RPM build errors:
Bad exit status from /tmp/B.HVALGw/BUILD/tmp/rpm-tmp.47033 (%build)
ended at: Sat Mar 11 19:50:28 2017, done in 0:00:04.158014
error: No files produced.
mesg: ttyname failed: Inappropriate ioctl for device
+ chmod -R u+rwX /tmp/B.HVALGw/BUILD
+ rm -rf /tmp/B.HVALGw/tmp /tmp/B.HVALGw/BUILD
mesg: ttyname failed: Inappropriate ioctl for device
+ rm -rf /tmp/B.HVALGw
Begin-PLD-Builder-Info
Build-Time: user:4.24s sys:0.53s real:6.79s (faults io:1 non-io:209648)
End-PLD-Builder-Info
|
|