Skip to content

Instantly share code, notes, and snippets.

@Brawl345
Created January 16, 2024 17:55
Show Gist options
  • Save Brawl345/d1ab7dad0a5d3f939cfec9eca394973e to your computer and use it in GitHub Desktop.
Save Brawl345/d1ab7dad0a5d3f939cfec9eca394973e to your computer and use it in GitHub Desktop.
Nixpkgs
Sourcing python-remove-tests-dir-hook
Sourcing python-catch-conflicts-hook.sh
Sourcing python-remove-bin-bytecode-hook.sh
Sourcing pypa-build-hook
Using pypaBuildPhase
Sourcing python-runtime-deps-check-hook
Using pythonRuntimeDepsCheckHook
Sourcing pypa-install-hook
Using pypaInstallPhase
Sourcing python-imports-check-hook.sh
Using pythonImportsCheckPhase
Sourcing python-namespaces-hook
Sourcing python-catch-conflicts-hook.sh
Sourcing pytest-check-hook
Using pytestCheckPhase
@nix { "action": "setPhase", "phase": "unpackPhase" }
Running phase: unpackPhase
unpacking source archive /nix/store/majy4dqb6xkvr7xah3ipwl7ibzbhv57h-source
source root is source
setting SOURCE_DATE_EPOCH to timestamp 315619200 of file source/tests/vcs/git/test_system.py
@nix { "action": "setPhase", "phase": "patchPhase" }
Running phase: patchPhase
@nix { "action": "setPhase", "phase": "updateAutotoolsGnuConfigScriptsPhase" }
Running phase: updateAutotoolsGnuConfigScriptsPhase
@nix { "action": "setPhase", "phase": "configurePhase" }
Running phase: configurePhase
no configure script, doing nothing
@nix { "action": "setPhase", "phase": "buildPhase" }
Running phase: buildPhase
Executing pypaBuildPhase
Creating a wheel...
* Getting build dependencies for wheel...
* Building wheel...
Successfully built poetry-1.7.1-py3-none-any.whl
Finished creating a wheel...
/private/tmp/nix-build-python3.11-poetry-1.7.1.drv-0/source/dist /private/tmp/nix-build-python3.11-poetry-1.7.1.drv-0/source
Unpacking to: unpacked/poetry-1.7.1...OK
Repacking wheel as ./poetry-1.7.1-py3-none-any.whl...creating './poetry-1.7.1-py3-none-any.whl' and adding 'unpacked/poetry-1.7.1' to it
adding 'poetry/__main__.py'
adding 'poetry/__version__.py'
adding 'poetry/exceptions.py'
adding 'poetry/factory.py'
adding 'poetry/locations.py'
adding 'poetry/poetry.py'
adding 'poetry/py.typed'
adding 'poetry/config/__init__.py'
adding 'poetry/config/config.py'
adding 'poetry/config/config_source.py'
adding 'poetry/config/dict_config_source.py'
adding 'poetry/config/file_config_source.py'
adding 'poetry/config/source.py'
adding 'poetry/console/__init__.py'
adding 'poetry/console/application.py'
adding 'poetry/console/command_loader.py'
adding 'poetry/console/exceptions.py'
adding 'poetry/console/commands/__init__.py'
adding 'poetry/console/commands/about.py'
adding 'poetry/console/commands/add.py'
adding 'poetry/console/commands/build.py'
adding 'poetry/console/commands/check.py'
adding 'poetry/console/commands/command.py'
adding 'poetry/console/commands/config.py'
adding 'poetry/console/commands/env_command.py'
adding 'poetry/console/commands/export.py'
adding 'poetry/console/commands/group_command.py'
adding 'poetry/console/commands/init.py'
adding 'poetry/console/commands/install.py'
adding 'poetry/console/commands/installer_command.py'
adding 'poetry/console/commands/lock.py'
adding 'poetry/console/commands/new.py'
adding 'poetry/console/commands/publish.py'
adding 'poetry/console/commands/remove.py'
adding 'poetry/console/commands/run.py'
adding 'poetry/console/commands/search.py'
adding 'poetry/console/commands/shell.py'
adding 'poetry/console/commands/show.py'
adding 'poetry/console/commands/update.py'
adding 'poetry/console/commands/version.py'
adding 'poetry/console/commands/cache/__init__.py'
adding 'poetry/console/commands/cache/clear.py'
adding 'poetry/console/commands/cache/list.py'
adding 'poetry/console/commands/debug/__init__.py'
adding 'poetry/console/commands/debug/info.py'
adding 'poetry/console/commands/debug/resolve.py'
adding 'poetry/console/commands/env/__init__.py'
adding 'poetry/console/commands/env/info.py'
adding 'poetry/console/commands/env/list.py'
adding 'poetry/console/commands/env/remove.py'
adding 'poetry/console/commands/env/use.py'
adding 'poetry/console/commands/self/__init__.py'
adding 'poetry/console/commands/self/add.py'
adding 'poetry/console/commands/self/install.py'
adding 'poetry/console/commands/self/lock.py'
adding 'poetry/console/commands/self/remove.py'
adding 'poetry/console/commands/self/self_command.py'
adding 'poetry/console/commands/self/update.py'
adding 'poetry/console/commands/self/show/__init__.py'
adding 'poetry/console/commands/self/show/plugins.py'
adding 'poetry/console/commands/source/__init__.py'
adding 'poetry/console/commands/source/add.py'
adding 'poetry/console/commands/source/remove.py'
adding 'poetry/console/commands/source/show.py'
adding 'poetry/console/events/__init__.py'
adding 'poetry/console/events/console_events.py'
adding 'poetry/console/io/__init__.py'
adding 'poetry/console/io/inputs/__init__.py'
adding 'poetry/console/io/inputs/run_argv_input.py'
adding 'poetry/console/logging/__init__.py'
adding 'poetry/console/logging/filters.py'
adding 'poetry/console/logging/io_formatter.py'
adding 'poetry/console/logging/io_handler.py'
adding 'poetry/console/logging/formatters/__init__.py'
adding 'poetry/console/logging/formatters/builder_formatter.py'
adding 'poetry/console/logging/formatters/formatter.py'
adding 'poetry/inspection/__init__.py'
adding 'poetry/inspection/info.py'
adding 'poetry/installation/__init__.py'
adding 'poetry/installation/chef.py'
adding 'poetry/installation/chooser.py'
adding 'poetry/installation/executor.py'
adding 'poetry/installation/installer.py'
adding 'poetry/installation/wheel_installer.py'
adding 'poetry/installation/operations/__init__.py'
adding 'poetry/installation/operations/install.py'
adding 'poetry/installation/operations/operation.py'
adding 'poetry/installation/operations/uninstall.py'
adding 'poetry/installation/operations/update.py'
adding 'poetry/json/__init__.py'
adding 'poetry/json/schemas/poetry.json'
adding 'poetry/layouts/__init__.py'
adding 'poetry/layouts/layout.py'
adding 'poetry/layouts/src.py'
adding 'poetry/layouts/standard.py'
adding 'poetry/masonry/__init__.py'
adding 'poetry/masonry/api.py'
adding 'poetry/masonry/builders/__init__.py'
adding 'poetry/masonry/builders/editable.py'
adding 'poetry/mixology/__init__.py'
adding 'poetry/mixology/assignment.py'
adding 'poetry/mixology/failure.py'
adding 'poetry/mixology/incompatibility.py'
adding 'poetry/mixology/incompatibility_cause.py'
adding 'poetry/mixology/partial_solution.py'
adding 'poetry/mixology/result.py'
adding 'poetry/mixology/set_relation.py'
adding 'poetry/mixology/term.py'
adding 'poetry/mixology/version_solver.py'
adding 'poetry/mixology/solutions/__init__.py'
adding 'poetry/mixology/solutions/providers/__init__.py'
adding 'poetry/mixology/solutions/providers/python_requirement_solution_provider.py'
adding 'poetry/mixology/solutions/solutions/__init__.py'
adding 'poetry/mixology/solutions/solutions/python_requirement_solution.py'
adding 'poetry/packages/__init__.py'
adding 'poetry/packages/dependency_package.py'
adding 'poetry/packages/direct_origin.py'
adding 'poetry/packages/locker.py'
adding 'poetry/packages/package_collection.py'
adding 'poetry/plugins/__init__.py'
adding 'poetry/plugins/application_plugin.py'
adding 'poetry/plugins/base_plugin.py'
adding 'poetry/plugins/plugin.py'
adding 'poetry/plugins/plugin_manager.py'
adding 'poetry/publishing/__init__.py'
adding 'poetry/publishing/publisher.py'
adding 'poetry/publishing/uploader.py'
adding 'poetry/puzzle/__init__.py'
adding 'poetry/puzzle/exceptions.py'
adding 'poetry/puzzle/provider.py'
adding 'poetry/puzzle/solver.py'
adding 'poetry/puzzle/transaction.py'
adding 'poetry/pyproject/__init__.py'
adding 'poetry/pyproject/toml.py'
adding 'poetry/repositories/__init__.py'
adding 'poetry/repositories/abstract_repository.py'
adding 'poetry/repositories/cached_repository.py'
adding 'poetry/repositories/exceptions.py'
adding 'poetry/repositories/http_repository.py'
adding 'poetry/repositories/installed_repository.py'
adding 'poetry/repositories/legacy_repository.py'
adding 'poetry/repositories/lockfile_repository.py'
adding 'poetry/repositories/pypi_repository.py'
adding 'poetry/repositories/repository.py'
adding 'poetry/repositories/repository_pool.py'
adding 'poetry/repositories/single_page_repository.py'
adding 'poetry/repositories/link_sources/__init__.py'
adding 'poetry/repositories/link_sources/base.py'
adding 'poetry/repositories/link_sources/html.py'
adding 'poetry/repositories/link_sources/json.py'
adding 'poetry/repositories/parsers/__init__.py'
adding 'poetry/repositories/parsers/html_page_parser.py'
adding 'poetry/repositories/parsers/pypi_search_parser.py'
adding 'poetry/toml/__init__.py'
adding 'poetry/toml/exceptions.py'
adding 'poetry/toml/file.py'
adding 'poetry/utils/__init__.py'
adding 'poetry/utils/_compat.py'
adding 'poetry/utils/authenticator.py'
adding 'poetry/utils/cache.py'
adding 'poetry/utils/constants.py'
adding 'poetry/utils/dependency_specification.py'
adding 'poetry/utils/extras.py'
adding 'poetry/utils/helpers.py'
adding 'poetry/utils/password_manager.py'
adding 'poetry/utils/patterns.py'
adding 'poetry/utils/pip.py'
adding 'poetry/utils/setup_reader.py'
adding 'poetry/utils/shell.py'
adding 'poetry/utils/source.py'
adding 'poetry/utils/wheel.py'
adding 'poetry/utils/env/__init__.py'
adding 'poetry/utils/env/base_env.py'
adding 'poetry/utils/env/env_manager.py'
adding 'poetry/utils/env/exceptions.py'
adding 'poetry/utils/env/generic_env.py'
adding 'poetry/utils/env/mock_env.py'
adding 'poetry/utils/env/null_env.py'
adding 'poetry/utils/env/script_strings.py'
adding 'poetry/utils/env/site_packages.py'
adding 'poetry/utils/env/system_env.py'
adding 'poetry/utils/env/virtual_env.py'
adding 'poetry/vcs/__init__.py'
adding 'poetry/vcs/git/__init__.py'
adding 'poetry/vcs/git/backend.py'
adding 'poetry/vcs/git/system.py'
adding 'poetry/version/__init__.py'
adding 'poetry/version/version_selector.py'
adding 'poetry-1.7.1.dist-info/LICENSE'
adding 'poetry-1.7.1.dist-info/METADATA'
adding 'poetry-1.7.1.dist-info/WHEEL'
adding 'poetry-1.7.1.dist-info/entry_points.txt'
adding 'poetry-1.7.1.dist-info/RECORD'
OK
/private/tmp/nix-build-python3.11-poetry-1.7.1.drv-0/source
Finished executing pypaBuildPhase
@nix { "action": "setPhase", "phase": "pythonRuntimeDepsCheckHook" }
Running phase: pythonRuntimeDepsCheckHook
Executing pythonRuntimeDepsCheck
Checking runtime dependencies for poetry-1.7.1-py3-none-any.whl
Finished executing pythonRuntimeDepsCheck
@nix { "action": "setPhase", "phase": "installPhase" }
Running phase: installPhase
Executing pypaInstallPhase
Successfully installed poetry-1.7.1-py3-none-any.whl
Finished executing pypaInstallPhase
@nix { "action": "setPhase", "phase": "pythonOutputDistPhase" }
Running phase: pythonOutputDistPhase
Executing pythonOutputDistPhase
Finished executing pythonOutputDistPhase
@nix { "action": "setPhase", "phase": "fixupPhase" }
Running phase: fixupPhase
checking for references to /private/tmp/nix-build-python3.11-poetry-1.7.1.drv-0/ in /nix/store/wh342ns6jx0db2cgqpr4lnrkg977r22w-python3.11-poetry-1.7.1...
patching script interpreter paths in /nix/store/wh342ns6jx0db2cgqpr4lnrkg977r22w-python3.11-poetry-1.7.1
stripping (with command strip and flags -S) in /nix/store/wh342ns6jx0db2cgqpr4lnrkg977r22w-python3.11-poetry-1.7.1/lib /nix/store/wh342ns6jx0db2cgqpr4lnrkg977r22>
checking for references to /private/tmp/nix-build-python3.11-poetry-1.7.1.drv-0/ in /nix/store/0vrsq7xw3ys61vhzpd0nib1l7j6dizks-python3.11-poetry-1.7.1-dist...
patching script interpreter paths in /nix/store/0vrsq7xw3ys61vhzpd0nib1l7j6dizks-python3.11-poetry-1.7.1-dist
Rewriting #!/nix/store/al81jk4wz596q8if684x6a9mqlv7vc3z-python3-3.11.7/bin/python3.11 to #!/nix/store/al81jk4wz596q8if684x6a9mqlv7vc3z-python3-3.11.7
wrapping `/nix/store/wh342ns6jx0db2cgqpr4lnrkg977r22w-python3.11-poetry-1.7.1/bin/poetry'...
Executing pythonRemoveTestsDir
Finished executing pythonRemoveTestsDir
Executing pythonNamespacesHook
Enforcing PEP420 namespace: poetry
Finished executing pythonNamespacesHook
@nix { "action": "setPhase", "phase": "installCheckPhase" }
Running phase: installCheckPhase
no Makefile or custom installCheckPhase, doing nothing
@nix { "action": "setPhase", "phase": "pythonCatchConflictsPhase" }
Running phase: pythonCatchConflictsPhase
@nix { "action": "setPhase", "phase": "pythonRemoveBinBytecodePhase" }
Running phase: pythonRemoveBinBytecodePhase
@nix { "action": "setPhase", "phase": "pythonImportsCheckPhase" }
Running phase: pythonImportsCheckPhase
Executing pythonImportsCheckPhase
@nix { "action": "setPhase", "phase": "pytestXdistHook" }
Running phase: pytestXdistHook
@nix { "action": "setPhase", "phase": "pytestCheckPhase" }
Running phase: pytestCheckPhase
Executing pytestCheckPhase
============================= test session starts ==============================
platform darwin -- Python 3.11.7, pytest-7.4.3, pluggy-1.3.0
rootdir: /private/tmp/nix-build-python3.11-poetry-1.7.1.drv-0/source
configfile: pyproject.toml
testpaths: tests
plugins: mock-3.12.0, xdist-3.5.0
^Mcreated: 10/10 workers^Minitialized: 1/10 workers^Minitialized: 2/10 workers^Minitialized: 3/10 workers^Minitialized: 4/10 workers^Minitialized: 5/10 workers^Mi>
........................................................................ [ 7%]
........................................................................ [ 14%]
........................................................................ [ 21%]
..................................................s..................... [ 28%]
........................................................................ [ 35%]
.....................................................................F.. [ 42%]
........................................................................ [ 49%]
........................................................................ [ 56%]
........................................................................ [ 63%]
........................................................................... [ 70%]
........................................................................ [ 77%]
........................................................................ [ 85%]
..............................s......................................... [ 92%]
........................................................................ [ 99%]
....... [100%]
=================================== FAILURES ===================================
__________________________________ test_shell __________________________________
[gw1] darwin -- Python 3.11.7 /nix/store/al81jk4wz596q8if684x6a9mqlv7vc3z-python3-3.11.7/bin/python3.11
pid = '61932', max_depth = 10
def iter_process_parents(pid, max_depth=10):
"""Try to look up the process tree via the output of `ps`."""
try:
cmd = ["ps", "-ww", "-o", "pid=", "-o", "ppid=", "-o", "args="]
> output = subprocess.check_output(cmd)
/nix/store/ja48yp4srf4d7z0cak9gbf5wrvcca5xh-python3.11-shellingham-1.5.4/lib/python3.11/site-packages/shellingham/posix/ps.py:16:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
/nix/store/al81jk4wz596q8if684x6a9mqlv7vc3z-python3-3.11.7/lib/python3.11/subprocess.py:466: in check_output
return run(*popenargs, stdout=PIPE, timeout=timeout, check=True,
/nix/store/al81jk4wz596q8if684x6a9mqlv7vc3z-python3-3.11.7/lib/python3.11/subprocess.py:548: in run
with Popen(*popenargs, **kwargs) as process:
/nix/store/al81jk4wz596q8if684x6a9mqlv7vc3z-python3-3.11.7/lib/python3.11/subprocess.py:1026: in __init__
self._execute_child(args, executable, preexec_fn, close_fds,
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
self = <Popen: returncode: 255 args: ['ps', '-ww', '-o', 'pid=', '-o', 'ppid=', '-o...>
args = ['ps', '-ww', '-o', 'pid=', '-o', 'ppid=', ...], executable = b'ps'
preexec_fn = None, close_fds = True, pass_fds = (), cwd = None, env = None
startupinfo = None, creationflags = 0, shell = False, p2cread = -1
p2cwrite = -1, c2pread = 14, c2pwrite = 15, errread = -1, errwrite = -1
restore_signals = True, gid = None, gids = None, uid = None, umask = -1
start_new_session = False, process_group = -1
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,
gid, gids, uid, umask,
start_new_session, process_group):
"""Execute program (POSIX version)"""
if isinstance(args, (str, bytes)):
args = [args]
elif isinstance(args, os.PathLike):
if shell:
raise TypeError('path-like args is not allowed when '
'shell is true')
args = [args]
else:
args = list(args)
if shell:
# On Android the default shell is at '/system/bin/sh'.
unix_shell = ('/system/bin/sh' if
hasattr(sys, 'getandroidapilevel') else '/nix/store/lv74m20f3z7pa60mxm3zsvxldq031qph-bash-5.2-p21/bin/sh')
args = [unix_shell, "-c"] + args
if executable:
args[0] = executable
if executable is None:
executable = args[0]
sys.audit("subprocess.Popen", executable, args, cwd, env)
if (_USE_POSIX_SPAWN
and os.path.dirname(executable)
and preexec_fn is None
and not close_fds
and not pass_fds
and cwd is None
and (p2cread == -1 or p2cread > 2)
and (c2pwrite == -1 or c2pwrite > 2)
and (errwrite == -1 or errwrite > 2)
and not start_new_session
and process_group == -1
and gid is None
and gids is None
and uid is None
and umask < 0):
self._posix_spawn(args, executable, env, restore_signals,
p2cread, p2cwrite,
c2pread, c2pwrite,
errread, errwrite)
return
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()
# errpipe_write must not be in the standard io 0, 1, or 2 fd range.
low_fds_to_close = []
while errpipe_write < 3:
low_fds_to_close.append(errpipe_write)
errpipe_write = os.dup(errpipe_write)
for low_fd in low_fds_to_close:
os.close(low_fd)
try:
try:
# We must avoid complex work that could involve
# malloc or free in the child process to avoid
# potential deadlocks, thus we do all this here.
# and pass it to fork_exec()
if env is not None:
env_list = []
for k, v in env.items():
k = os.fsencode(k)
if b'=' in k:
raise ValueError("illegal environment variable name")
env_list.append(k + b'=' + os.fsencode(v))
else:
env_list = None # Use execv instead of execve.
executable = os.fsencode(executable)
if os.path.dirname(executable):
executable_list = (executable,)
else:
# This matches the behavior of os._execvpe().
executable_list = tuple(
os.path.join(os.fsencode(dir), executable)
for dir in os.get_exec_path(env))
fds_to_keep = set(pass_fds)
fds_to_keep.add(errpipe_write)
self.pid = _fork_exec(
args, executable_list,
close_fds, tuple(sorted(map(int, fds_to_keep))),
cwd, env_list,
p2cread, p2cwrite, c2pread, c2pwrite,
errread, errwrite,
errpipe_read, errpipe_write,
restore_signals, start_new_session,
process_group, gid, gids, uid, umask,
preexec_fn, _USE_VFORK)
self._child_created = True
finally:
# be sure the FD is closed no matter what
os.close(errpipe_write)
self._close_pipe_fds(p2cread, p2cwrite,
c2pread, c2pwrite,
errread, errwrite)
# Wait for exec to fail or succeed; possibly raising an
# exception (limited in size)
errpipe_data = bytearray()
while True:
part = os.read(errpipe_read, 50000)
errpipe_data += part
if not part or len(errpipe_data) > 50000:
break
finally:
# be sure the FD is closed no matter what
os.close(errpipe_read)
if errpipe_data:
try:
pid, sts = os.waitpid(self.pid, 0)
if pid == self.pid:
self._handle_exitstatus(sts)
else:
self.returncode = sys.maxsize
except ChildProcessError:
pass
try:
exception_name, hex_errno, err_msg = (
errpipe_data.split(b':', 2))
# The encoding here should match the encoding
# written in by the subprocess implementations
# like _posixsubprocess
err_msg = err_msg.decode()
except ValueError:
exception_name = b'SubprocessError'
hex_errno = b'0'
err_msg = 'Bad exception data from child: {!r}'.format(
bytes(errpipe_data))
child_exception_type = getattr(
builtins, exception_name.decode('ascii'),
SubprocessError)
if issubclass(child_exception_type, OSError) and hex_errno:
errno_num = int(hex_errno, 16)
child_exec_never_called = (err_msg == "noexec")
if child_exec_never_called:
err_msg = ""
# The error must be from chdir(cwd).
err_filename = cwd
else:
err_filename = orig_executable
if errno_num != 0:
err_msg = os.strerror(errno_num)
> raise child_exception_type(errno_num, err_msg, err_filename)
E FileNotFoundError: [Errno 2] No such file or directory: 'ps'
/nix/store/al81jk4wz596q8if684x6a9mqlv7vc3z-python3-3.11.7/lib/python3.11/subprocess.py:1950: FileNotFoundError
During handling of the above exception, another exception occurred:
tester = <cleo.testers.command_tester.CommandTester object at 0x10bc8a710>
mocker = <pytest_mock.plugin.MockerFixture object at 0x10bc67c10>
def test_shell(tester: CommandTester, mocker: MockerFixture) -> None:
shell_activate = mocker.patch("poetry.utils.shell.Shell.activate")
> tester.execute()
tests/console/commands/test_shell.py:28:
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
/nix/store/f044wglc89lyl7rkhl95rml3qhsh9cdh-python3.11-cleo-2.1.0/lib/python3.11/site-packages/cleo/testers/command_tester.py:88: in execute
self._status_code = self._command.run(self._io)
/nix/store/f044wglc89lyl7rkhl95rml3qhsh9cdh-python3.11-cleo-2.1.0/lib/python3.11/site-packages/cleo/commands/base_command.py:117: in run
return self.execute(io) or 0
/nix/store/f044wglc89lyl7rkhl95rml3qhsh9cdh-python3.11-cleo-2.1.0/lib/python3.11/site-packages/cleo/commands/command.py:61: in execute
return self.handle()
/nix/store/wh342ns6jx0db2cgqpr4lnrkg977r22w-python3.11-poetry-1.7.1/lib/python3.11/site-packages/poetry/console/commands/shell.py:45: in handle
shell = Shell.get()
/nix/store/wh342ns6jx0db2cgqpr4lnrkg977r22w-python3.11-poetry-1.7.1/lib/python3.11/site-packages/poetry/utils/shell.py:53: in get
name, path = detect_shell(os.getpid())
/nix/store/ja48yp4srf4d7z0cak9gbf5wrvcca5xh-python3.11-shellingham-1.5.4/lib/python3.11/site-packages/shellingham/__init__.py:20: in detect_shell
shell = get_shell(pid, max_depth=max_depth)
/nix/store/ja48yp4srf4d7z0cak9gbf5wrvcca5xh-python3.11-shellingham-1.5.4/lib/python3.11/site-packages/shellingham/posix/__init__.py:108: in get_shell
for proc_args, _, _ in _iter_process_parents(pid, max_depth):
_ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _ _
pid = '61932', max_depth = 10
def iter_process_parents(pid, max_depth=10):
"""Try to look up the process tree via the output of `ps`."""
try:
cmd = ["ps", "-ww", "-o", "pid=", "-o", "ppid=", "-o", "args="]
output = subprocess.check_output(cmd)
except OSError as e: # Python 2-compatible FileNotFoundError.
if e.errno != errno.ENOENT:
raise
> raise PsNotAvailable("ps not found")
E shellingham.posix.ps.PsNotAvailable: ps not found
/nix/store/ja48yp4srf4d7z0cak9gbf5wrvcca5xh-python3.11-shellingham-1.5.4/lib/python3.11/site-packages/shellingham/posix/ps.py:20: PsNotAvailable
------------------------------ Captured log setup ------------------------------
DEBUG poetry.plugins.plugin_manager:plugin_manager.py:74 Loading the export plugin
=========================== short test summary info ============================
FAILED tests/console/commands/test_shell.py::test_shell - shellingham.posix.ps.PsNotAvailable: ps not found
================== 1 failed, 1015 passed, 2 skipped in 53.12s ==================
/nix/store/8sqsglvyvy56ckbazl8k6pxk8x4wwvj2-stdenv-darwin/setup: line 1566: pop_var_context: head of shell_variables not a function context
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment