You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm trying to package your module as an rpm package. So I'm using the typical PEP517 based build, install and test cycle used on building packages from non-root account.
python3 -sBm build -w --no-isolation
because I'm calling build with --no-isolation I'm using during all processes only locally installed modules
install .whl file in </install/prefix>
run pytest with PYTHONPATH pointing to sitearch and sitelib inside </install/prefix>
Here is pytest output:
+ PYTHONPATH=/home/tkloczko/rpmbuild/BUILDROOT/python-jupyter-client-7.2.0-2.fc35.x86_64/usr/lib64/python3.8/site-packages:/home/tkloczko/rpmbuild/BUILDROOT/python-jupyter-client-7.2.0-2.fc35.x86_64/usr/lib/python3.8/site-packages+ /usr/bin/pytest -ra=========================================================================== test session starts ============================================================================platform linux -- Python 3.8.12, pytest-7.1.1, pluggy-1.0.0rootdir: /home/tkloczko/rpmbuild/BUILD/jupyter_client-7.2.0, configfile: pyproject.toml, testpaths: jupyter_client/tests/plugins: asyncio-0.18.2, timeout-2.1.0, forked-1.4.0, xdist-2.5.0asyncio: mode=legacytimeout: 300.0stimeout method: signaltimeout func_only: Falsecollected 181 itemsjupyter_client/tests/test_adapter.py ........................... [ 14%]jupyter_client/tests/test_client.py ........ [ 19%]jupyter_client/tests/test_connect.py ........... [ 25%]jupyter_client/tests/test_jsonutil.py ..... [ 28%]jupyter_client/tests/test_kernelapp.py . [ 28%]jupyter_client/tests/test_kernelmanager.py .....................s.s.s............ [ 49%]jupyter_client/tests/test_kernelspec.py ............. [ 56%]jupyter_client/tests/test_localinterfaces.py . [ 57%]jupyter_client/tests/test_manager.py . [ 58%]jupyter_client/tests/test_multikernelmanager.py .............................. [ 74%]jupyter_client/tests/test_provisioning.py ........... [ 80%]jupyter_client/tests/test_public_api.py .... [ 82%]jupyter_client/tests/test_restarter.py ........ [ 87%]jupyter_client/tests/test_session.py .........s........... [ 98%]jupyter_client/tests/test_ssh.py . [ 99%]jupyter_client/tests/test_utils.py . [100%]============================================================================= warnings summary =============================================================================../../../../../usr/lib/python3.8/site-packages/pytest_asyncio/plugin.py:191 /usr/lib/python3.8/site-packages/pytest_asyncio/plugin.py:191: DeprecationWarning: The 'asyncio_mode' default value will change to 'strict' in future, please explicitly use 'asyncio_mode=strict' or 'asyncio_mode=auto' in pytest configuration file. config.issue_config_time_warning(LEGACY_MODE, stacklevel=2)../../../../../usr/lib/python3.8/site-packages/ipykernel/iostream.py:9 /usr/lib/python3.8/site-packages/ipykernel/iostream.py:9: DeprecationWarning: the imp module is deprecated in favour of importlib; see the module's documentation for alternative uses from imp import lock_held as import_lock_held../../../../../usr/lib/python3.8/site-packages/pytest_asyncio/plugin.py:226 /usr/lib/python3.8/site-packages/pytest_asyncio/plugin.py:226: DeprecationWarning: '@pytest.fixture' is applied to <fixture start_async_kernel, file=/home/tkloczko/rpmbuild/BUILD/jupyter_client-7.2.0/jupyter_client/tests/test_kernelmanager.py, line=126> in 'legacy' mode, please replace it with '@pytest_asyncio.fixture' as a preparation for switching to 'strict' mode (or use 'auto' mode to seamlessly handle all these fixtures as asyncio-driven). warnings.warn(jupyter_client/tests/test_session.py::TestSession::test_tracking /usr/lib64/python3.8/site-packages/zmq/eventloop/zmqstream.py:101: DeprecationWarning: zmq.eventloop.ioloop is deprecated in pyzmq 17. pyzmq now works with default tornado and asyncio eventloops. self.io_loop = io_loop or IOLoop.current()-- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html=========================================================================== slowest 10 durations ===========================================================================18.98s call jupyter_client/tests/test_kernelmanager.py::TestParallel::test_start_sequence_kernels[tcp]18.52s call jupyter_client/tests/test_kernelmanager.py::TestParallel::test_start_sequence_kernels[ipc]18.14s call jupyter_client/tests/test_restarter.py::test_async_restarter_gives_up[tcp]18.14s call jupyter_client/tests/test_restarter.py::test_async_restarter_gives_up[ipc]12.72s call jupyter_client/tests/test_kernelmanager.py::TestParallel::test_start_parallel_process_kernels[tcp]12.71s call jupyter_client/tests/test_kernelmanager.py::TestParallel::test_start_parallel_thread_kernels[tcp]12.67s call jupyter_client/tests/test_kernelmanager.py::TestParallel::test_start_sequence_process_kernels[tcp]9.29s call jupyter_client/tests/test_restarter.py::test_async_restart_check[tcp]9.24s call jupyter_client/tests/test_restarter.py::test_async_restart_check[ipc]9.16s call jupyter_client/tests/test_restarter.py::test_restart_check[ipc]========================================================================= short test summary info ==========================================================================SKIPPED [1] jupyter_client/tests/test_kernelmanager.py:367: IPC transport is currently not working for this test!SKIPPED [1] jupyter_client/tests/test_kernelmanager.py:383: IPC transport is currently not working for this test!SKIPPED [1] jupyter_client/tests/test_kernelmanager.py:399: IPC transport is currently not working for this test!SKIPPED [1] jupyter_client/tests/test_session.py:307: could not import 'msgpack': No module named 'msgpack'========================================================== 177 passed, 4 skipped, 4 warnings in 247.37s (0:04:07) ==========================================================Task exception was never retrievedfuture: <Task finished name='Task-1675' coro=<MultiKernelManager._add_kernel_when_ready() done, defined at /home/tkloczko/rpmbuild/BUILD/jupyter_client-7.2.0/jupyter_client/multikernelmanager.py:166> exception=FileNotFoundError(2, 'No such file or directory')>Traceback (most recent call last): File "/home/tkloczko/rpmbuild/BUILD/jupyter_client-7.2.0/jupyter_client/tests/test_multikernelmanager.py", line 590, in test_bad_kernelspec_pending await km.get_kernel(kernel_id).ready File "/usr/lib64/python3.8/asyncio/tasks.py", line 280, in __step result = coro.send(None) File "/home/tkloczko/rpmbuild/BUILD/jupyter_client-7.2.0/jupyter_client/multikernelmanager.py", line 170, in _add_kernel_when_ready await kernel_awaitable File "/home/tkloczko/rpmbuild/BUILD/jupyter_client-7.2.0/jupyter_client/utils.py", line 34, in ensure_async return await obj File "/home/tkloczko/rpmbuild/BUILD/jupyter_client-7.2.0/jupyter_client/manager.py", line 79, in wrapper raise e File "/home/tkloczko/rpmbuild/BUILD/jupyter_client-7.2.0/jupyter_client/manager.py", line 71, in wrapper out = await method(self, *args, **kwargs) File "/home/tkloczko/rpmbuild/BUILD/jupyter_client-7.2.0/jupyter_client/manager.py", line 380, in _async_start_kernel await ensure_async(self._launch_kernel(kernel_cmd, **kw)) File "/home/tkloczko/rpmbuild/BUILD/jupyter_client-7.2.0/jupyter_client/utils.py", line 34, in ensure_async return await obj File "/home/tkloczko/rpmbuild/BUILD/jupyter_client-7.2.0/jupyter_client/manager.py", line 300, in _async_launch_kernel connection_info = await self.provisioner.launch_kernel(kernel_cmd, **kw) File "/home/tkloczko/rpmbuild/BUILD/jupyter_client-7.2.0/jupyter_client/provisioning/local_provisioner.py", line 199, in launch_kernel self.process = launch_kernel(cmd, **scrubbed_kwargs) File "/home/tkloczko/rpmbuild/BUILD/jupyter_client-7.2.0/jupyter_client/launcher.py", line 169, in launch_kernel raise ex File "/home/tkloczko/rpmbuild/BUILD/jupyter_client-7.2.0/jupyter_client/launcher.py", line 157, in launch_kernel proc = Popen(cmd, **kwargs) File "/usr/lib64/python3.8/subprocess.py", line 858, in __init__ self._execute_child(args, executable, preexec_fn, close_fds, File "/usr/lib64/python3.8/subprocess.py", line 1704, in _execute_child raise child_exception_type(errno_num, err_msg, err_filename)FileNotFoundError: [Errno 2] No such file or directory: 'non_existent_executable'
Despite that printed call stack pytest finishes with exit 0.
List of modules isntalled in build env:
Thanks @kloczek for opening an issue.
It's strange because the FileNotFound exception should be captured by pytest. We don't have this traceback in our CI.
Sorry I don't have a solution right now. I don't think Mr ZeroMQ will answer here either 😄
I'm trying to package your module as an rpm package. So I'm using the typical PEP517 based build, install and test cycle used on building packages from non-root account.
python3 -sBm build -w --no-isolation
build
with--no-isolation
I'm using during all processes only locally installed modulesHere is pytest output:
Despite that printed call stack pytest finishes with exit 0.
List of modules isntalled in build env:
The text was updated successfully, but these errors were encountered: