Virtual env related Error when trying to install ERPNext

Error when running this command
bench init frappe-bench --frappe-branch version-13

Here is the error stack

Setting Up Environment
$ /usr/bin/virtualenv --quiet env -p python3
/usr/local/lib/python3.10/dist-packages/setuptools/command/ SetuptoolsDeprecationWarning: install is deprecated. Use build and pip and other standards-based tools.
$ /home/bench/frappe-bench/env/bin/python -m pip install --quiet --upgrade pip
Traceback (most recent call last):
  File "/usr/local/lib/python3.9/dist-packages/bench/commands/", line 70, in init
  File "/usr/local/lib/python3.9/dist-packages/bench/utils/", line 95, in wrapper_fn
    return fn(*args, **kwargs)
  File "/usr/local/lib/python3.9/dist-packages/bench/utils/", line 65, in init
  File "/usr/local/lib/python3.9/dist-packages/bench/utils/", line 110, in wrapper_fn
    return fn(*args, **kwargs)
  File "/usr/local/lib/python3.9/dist-packages/bench/", line 360, in env
  File "/usr/local/lib/python3.9/dist-packages/bench/utils/", line 110, in wrapper_fn
    return fn(*args, **kwargs)
  File "/usr/local/lib/python3.9/dist-packages/bench/", line 392, in pip
    return"{self.bench.python} -m pip install {quiet_flag} --upgrade pip")
  File "/usr/local/lib/python3.9/dist-packages/bench/", line 47, in run
    return exec_cmd(cmd, cwd=cwd or self.cwd)
  File "/usr/local/lib/python3.9/dist-packages/bench/utils/", line 149, in exec_cmd
    return_code =, cwd=cwd, universal_newlines=True, env=env)
  File "/usr/lib/python3.9/", line 349, in call
    with Popen(*popenargs, **kwargs) as p:
  File "/usr/lib/python3.9/", line 951, in __init__
    self._execute_child(args, executable, preexec_fn, close_fds,
  File "/usr/lib/python3.9/", line 1821, in _execute_child
    raise child_exception_type(errno_num, err_msg, err_filename)
FileNotFoundError: [Errno 2] No such file or directory: '/home/bench/frappe-bench/env/bin/python'

Python Version: 3.10.5
virtualenv Version: 20.0.17
OS: Ubuntu 20.04

1 Like