| Hi, Thanks for helping me with the verification and fixing errors! Yes, export MACOSX_DEPLOYMENT_TARGET=10.15 does work. However one of the Python tests failed: pyarrow/tests/test_plasma.py::TestPlasmaClient::test_subscribe_socket ERROR Here is the traceback: |
{\rtf1\ansi\ansicpg1252\cocoartf2513
\cocoatextscaling0\cocoaplatform0{\fonttbl\f0\fnil\fcharset0 Menlo-Regular;\f1\fnil\fcharset0 Menlo-Bold;}
{\colortbl;\red255\green255\blue255;\red0\green0\blue0;\red180\green36\blue25;\red159\green160\blue28;
}
{\*\expandedcolortbl;;\csgray\c0;\cssrgb\c76409\c21698\c12524;\cssrgb\c68468\c68012\c14208;
}
\margl1440\margr1440\vieww10800\viewh8400\viewkind0
\pard\tx560\tx1120\tx1680\tx2240\tx2800\tx3360\tx3920\tx4480\tx5040\tx5600\tx6160\tx6720\pardirnatural\partightenfactor0
\f0\fs22 \cf2 \CocoaLigature0 >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> traceback >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>\
\
plasma_store_memory = 100000000, use_valgrind = False, use_profiler = False, plasma_directory = None, use_hugepages = False, external_store = None\
\
@contextlib.contextmanager\
def start_plasma_store(plasma_store_memory,\
use_valgrind=False, use_profiler=False,\
plasma_directory=None, use_hugepages=False,\
external_store=None):\
"""Start a plasma store process.\
Args:\
plasma_store_memory (int): Capacity of the plasma store in bytes.\
use_valgrind (bool): True if the plasma store should be started inside\
of valgrind. If this is True, use_profiler must be False.\
use_profiler (bool): True if the plasma store should be started inside\
a profiler. If this is True, use_valgrind must be False.\
plasma_directory (str): Directory where plasma memory mapped files\
will be stored.\
use_hugepages (bool): True if the plasma store should use huge pages.\
external_store (str): External store to use for evicted objects.\
Return:\
A tuple of the name of the plasma store socket and the process ID of\
the plasma store process.\
"""\
if use_valgrind and use_profiler:\
raise Exception("Cannot use valgrind and profiler at the same time.")\
\
tmpdir = tempfile.mkdtemp(prefix='test_plasma-')\
try:\
plasma_store_name = os.path.join(tmpdir, 'plasma.sock')\
plasma_store_executable = os.path.join(\
pa.__path__[0], "plasma-store-server")\
if not os.path.exists(plasma_store_executable):\
# Fallback to sys.prefix/bin/ (conda)\
plasma_store_executable = os.path.join(\
sys.prefix, "bin", "plasma-store-server")\
command = [plasma_store_executable,\
"-s", plasma_store_name,\
"-m", str(plasma_store_memory)]\
if plasma_directory:\
command += ["-d", plasma_directory]\
if use_hugepages:\
command += ["-h"]\
if external_store is not None:\
command += ["-e", external_store]\
stdout_file = None\
stderr_file = None\
if use_valgrind:\
command = ["valgrind",\
"--track-origins=yes",\
"--leak-check=full",\
"--show-leak-kinds=all",\
"--leak-check-heuristics=stdstring",\
"--error-exitcode=1"] + command\
proc = subprocess.Popen(command, stdout=stdout_file,\
stderr=stderr_file)\
time.sleep(1.0)\
elif use_profiler:\
command = ["valgrind", "--tool=callgrind"] + command\
proc = subprocess.Popen(command, stdout=stdout_file,\
stderr=stderr_file)\
time.sleep(1.0)\
else:\
proc = subprocess.Popen(command, stdout=stdout_file,\
> stderr=stderr_file)\
\
\f1\b \cf3 pyarrow/plasma.py
\f0\b0 \cf2 :141: \
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ \
\
self = <subprocess.Popen object at 0x7fb911c829e8>\
args = ['/private/var/folders/yb/dc13kd1552vc_x61qzpgmtjh0000gn/T/arrow-3.0.0.XXXXX.vXcdjnYa/apache-arrow-3.0.0/python/pyarro...-server', '-s', '/var/folders/yb/dc13kd1552vc_x61qzpgmtjh0000gn/T/test_plasma-__no_836/plasma.sock', '-m', '100000000']\
bufsize = -1, executable = None, stdin = None, stdout = None, stderr = None, preexec_fn = None, close_fds = True, shell = False, cwd = None, env = None, universal_newlines = False, startupinfo = None, creationflags = 0, restore_signals = True\
start_new_session = False, pass_fds = ()\
\
def __init__(self, args, bufsize=-1, executable=None,\
stdin=None, stdout=None, stderr=None,\
preexec_fn=None, close_fds=_PLATFORM_DEFAULT_CLOSE_FDS,\
shell=False, cwd=None, env=None, universal_newlines=False,\
startupinfo=None, creationflags=0,\
restore_signals=True, start_new_session=False,\
pass_fds=(), *, encoding=None, errors=None):\
"""Create new Popen instance."""\
_cleanup()\
# Held while anything is calling waitpid before returncode has been\
# updated to prevent clobbering returncode if wait() or poll() are\
# called from multiple threads at once. After acquiring the lock,\
# code must re-check self.returncode to see if another thread just\
# finished a waitpid() call.\
self._waitpid_lock = threading.Lock()\
\
self._input = None\
self._communication_started = False\
if bufsize is None:\
bufsize = -1 # Restore default\
if not isinstance(bufsize, int):\
raise TypeError("bufsize must be an integer")\
\
if _mswindows:\
if preexec_fn is not None:\
raise ValueError("preexec_fn is not supported on Windows "\
"platforms")\
any_stdio_set = (stdin is not None or stdout is not None or\
stderr is not None)\
if close_fds is _PLATFORM_DEFAULT_CLOSE_FDS:\
if any_stdio_set:\
close_fds = False\
else:\
close_fds = True\
elif close_fds and any_stdio_set:\
raise ValueError(\
"close_fds is not supported on Windows platforms"\
" if you redirect stdin/stdout/stderr")\
else:\
# POSIX\
if close_fds is _PLATFORM_DEFAULT_CLOSE_FDS:\
close_fds = True\
if pass_fds and not close_fds:\
warnings.warn("pass_fds overriding close_fds.", RuntimeWarning)\
close_fds = True\
if startupinfo is not None:\
raise ValueError("startupinfo is only supported on Windows "\
"platforms")\
if creationflags != 0:\
raise ValueError("creationflags is only supported on Windows "\
"platforms")\
\
self.args = args\
self.stdin = None\
self.stdout = None\
self.stderr = None\
self.pid = None\
self.returncode = None\
self.universal_newlines = universal_newlines\
self.encoding = encoding\
self.errors = errors\
\
# Input and output objects. The general principle is like\
# this:\
#\
# Parent Child\
# ------ -----\
# p2cwrite ---stdin---> p2cread\
# c2pread <--stdout--- c2pwrite\
# errread <--stderr--- errwrite\
#\
# On POSIX, the child objects are file descriptors. On\
# Windows, these are Windows file handles. The parent objects\
# are file descriptors on both platforms. The parent objects\
# are -1 when not using PIPEs. The child objects are -1\
# when not redirecting.\
\
(p2cread, p2cwrite,\
c2pread, c2pwrite,\
errread, errwrite) = self._get_handles(stdin, stdout, stderr)\
\
# We wrap OS handles *before* launching the child, otherwise a\
# quickly terminating child could make our fds unwrappable\
# (see #8458).\
\
if _mswindows:\
if p2cwrite != -1:\
p2cwrite = msvcrt.open_osfhandle(p2cwrite.Detach(), 0)\
if c2pread != -1:\
c2pread = msvcrt.open_osfhandle(c2pread.Detach(), 0)\
if errread != -1:\
errread = msvcrt.open_osfhandle(errread.Detach(), 0)\
\
text_mode = encoding or errors or universal_newlines\
\
self._closed_child_pipe_fds = False\
\
try:\
if p2cwrite != -1:\
self.stdin = io.open(p2cwrite, 'wb', bufsize)\
if text_mode:\
self.stdin = io.TextIOWrapper(self.stdin, write_through=True,\
line_buffering=(bufsize == 1),\
encoding=encoding, errors=errors)\
if c2pread != -1:\
self.stdout = io.open(c2pread, 'rb', bufsize)\
if text_mode:\
self.stdout = io.TextIOWrapper(self.stdout,\
encoding=encoding, errors=errors)\
if errread != -1:\
self.stderr = io.open(errread, 'rb', bufsize)\
if text_mode:\
self.stderr = io.TextIOWrapper(self.stderr,\
encoding=encoding, errors=errors)\
\
self._execute_child(args, executable, preexec_fn, close_fds,\
pass_fds, cwd, env,\
startupinfo, creationflags, shell,\
p2cread, p2cwrite,\
c2pread, c2pwrite,\
errread, errwrite,\
> restore_signals, start_new_session)\
\
\f1\b \cf3 /var/folders/yb/dc13kd1552vc_x61qzpgmtjh0000gn/T/arrow-3.0.0.XXXXX.vXcdjnYa/test-miniconda/envs/arrow-test/lib/python3.6/subprocess.py
\f0\b0 \cf2 :729: \
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ \
\
self = <subprocess.Popen object at 0x7fb911c829e8>\
args = ['/private/var/folders/yb/dc13kd1552vc_x61qzpgmtjh0000gn/T/arrow-3.0.0.XXXXX.vXcdjnYa/apache-arrow-3.0.0/python/pyarro...-server', '-s', '/var/folders/yb/dc13kd1552vc_x61qzpgmtjh0000gn/T/test_plasma-__no_836/plasma.sock', '-m', '100000000']\
executable = '/private/var/folders/yb/dc13kd1552vc_x61qzpgmtjh0000gn/T/arrow-3.0.0.XXXXX.vXcdjnYa/apache-arrow-3.0.0/python/pyarrow/plasma-store-server', preexec_fn = None, close_fds = True, pass_fds = (), cwd = None, env = None\
startupinfo = None, creationflags = 0, shell = False, p2cread = -1, p2cwrite = -1, c2pread = -1, c2pwrite = -1, errread = -1, errwrite = -1, restore_signals = True, start_new_session = False\
\
def _execute_child(self, args, executable, preexec_fn, close_fds,\
pass_fds, cwd, env,\
startupinfo, creationflags, shell,\
p2cread, p2cwrite,\
c2pread, c2pwrite,\
errread, errwrite,\
restore_signals, start_new_session):\
"""Execute program (POSIX version)"""\
\
if isinstance(args, (str, bytes)):\
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]\
orig_executable = executable\
\
# For transferring possible exec failure from child to parent.\
# Data format: "exception name:hex errno:description"\
# Pickle is not used; it is complex and involves memory allocation.\
> errpipe_read, errpipe_write = os.pipe()\
\f1\b \cf3 E OSError: [Errno 24] Too many open files
\f0\b0 \cf2 \
\
\f1\b \cf3 /var/folders/yb/dc13kd1552vc_x61qzpgmtjh0000gn/T/arrow-3.0.0.XXXXX.vXcdjnYa/test-miniconda/envs/arrow-test/lib/python3.6/subprocess.py
\f0\b0 \cf2 :1254: OSError\
\
\cf4 During handling of the above exception, another exception occurred:\cf2 \
\
self = <pyarrow.tests.test_plasma.TestPlasmaClient object at 0x7fb910ca51d0>, test_method = <bound method TestPlasmaClient.test_subscribe_socket of <pyarrow.tests.test_plasma.TestPlasmaClient object at 0x7fb910ca51d0>>\
\
def setup_method(self, test_method):\
import pyarrow.plasma as plasma\
# Start Plasma store.\
self.plasma_store_ctx = plasma.start_plasma_store(\
plasma_store_memory=DEFAULT_PLASMA_STORE_MEMORY,\
use_valgrind=USE_VALGRIND)\
> self.plasma_store_name, self.p = self.plasma_store_ctx.__enter__()\
\
\f1\b \cf3 pyarrow/tests/test_plasma.py
\f0\b0 \cf2 :94: \
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ \
\f1\b \cf3 /var/folders/yb/dc13kd1552vc_x61qzpgmtjh0000gn/T/arrow-3.0.0.XXXXX.vXcdjnYa/test-miniconda/envs/arrow-test/lib/python3.6/contextlib.py
\f0\b0 \cf2 :81: in __enter__\
return next(self.gen)\
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ \
\
plasma_store_memory = 100000000, use_valgrind = False, use_profiler = False, plasma_directory = None, use_hugepages = False, external_store = None\
\
@contextlib.contextmanager\
def start_plasma_store(plasma_store_memory,\
use_valgrind=False, use_profiler=False,\
plasma_directory=None, use_hugepages=False,\
external_store=None):\
"""Start a plasma store process.\
Args:\
plasma_store_memory (int): Capacity of the plasma store in bytes.\
use_valgrind (bool): True if the plasma store should be started inside\
of valgrind. If this is True, use_profiler must be False.\
use_profiler (bool): True if the plasma store should be started inside\
a profiler. If this is True, use_valgrind must be False.\
plasma_directory (str): Directory where plasma memory mapped files\
will be stored.\
use_hugepages (bool): True if the plasma store should use huge pages.\
external_store (str): External store to use for evicted objects.\
Return:\
A tuple of the name of the plasma store socket and the process ID of\
the plasma store process.\
"""\
if use_valgrind and use_profiler:\
raise Exception("Cannot use valgrind and profiler at the same time.")\
\
tmpdir = tempfile.mkdtemp(prefix='test_plasma-')\
try:\
plasma_store_name = os.path.join(tmpdir, 'plasma.sock')\
plasma_store_executable = os.path.join(\
pa.__path__[0], "plasma-store-server")\
if not os.path.exists(plasma_store_executable):\
# Fallback to sys.prefix/bin/ (conda)\
plasma_store_executable = os.path.join(\
sys.prefix, "bin", "plasma-store-server")\
command = [plasma_store_executable,\
"-s", plasma_store_name,\
"-m", str(plasma_store_memory)]\
if plasma_directory:\
command += ["-d", plasma_directory]\
if use_hugepages:\
command += ["-h"]\
if external_store is not None:\
command += ["-e", external_store]\
stdout_file = None\
stderr_file = None\
if use_valgrind:\
command = ["valgrind",\
"--track-origins=yes",\
"--leak-check=full",\
"--show-leak-kinds=all",\
"--leak-check-heuristics=stdstring",\
"--error-exitcode=1"] + command\
proc = subprocess.Popen(command, stdout=stdout_file,\
stderr=stderr_file)\
time.sleep(1.0)\
elif use_profiler:\
command = ["valgrind", "--tool=callgrind"] + command\
proc = subprocess.Popen(command, stdout=stdout_file,\
stderr=stderr_file)\
time.sleep(1.0)\
else:\
proc = subprocess.Popen(command, stdout=stdout_file,\
stderr=stderr_file)\
time.sleep(0.1)\
rc = proc.poll()\
if rc is not None:\
raise RuntimeError("plasma_store exited unexpectedly with "\
"code %d" % (rc,))\
\
yield plasma_store_name, proc\
finally:\
> if proc.poll() is None:\
\f1\b \cf3 E UnboundLocalError: local variable 'proc' referenced before assignment
\f0\b0 \cf2 \
\
\f1\b \cf3 pyarrow/plasma.py
\f0\b0 \cf2 :150: UnboundLocalError\
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> entering PDB >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>\
\
>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> PDB post_mortem (IO-capturing turned off) >>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>\
> /private/var/folders/yb/dc13kd1552vc_x61qzpgmtjh0000gn/T/arrow-3.0.0.XXXXX.vXcdjnYa/apache-arrow-3.0.0/python/pyarrow/plasma.py(150)start_plasma_store()\
-> if proc.poll() is None:\
(Pdb) \
}Thanks, Ying
|
