drlight17/mta-log-parser

pipenv install gives errors

JeffZwolle opened this issue · 2 comments

After creating the previous issue I did not have a lot of time free for this project. Now that I do, I have started the install from scratch. I used the instructions “Install in your system (not recommended)”, because the use of docker is not an option for this system. When using the command “pipenv install” I get this result which does not look quite right I think. I did follow the instructions, but maybe the installation (currently Ubuntu 22.04) is missing something?

Pipfile.lock not found, creating...
Locking [packages] dependencies...
Building requirements...
Resolving dependencies...
✔ Success!
Locking [dev-packages] dependencies...
Updated Pipfile.lock (1d507ac9d99bd9cb1a6cf653ffe38421576e04afe3461e95735bce11e0dd893a)!
Installing dependencies from Pipfile.lock (dd893a)...
Traceback (most recent call last):
  File "/usr/local/bin/pipenv", line 8, in <module>
    sys.exit(cli())
  File "/usr/local/lib/python3.10/dist-packages/pipenv/vendor/click/core.py", line 1157, in __call__
    return self.main(*args, **kwargs)
  File "/usr/local/lib/python3.10/dist-packages/pipenv/cli/options.py", line 58, in main
    return super().main(*args, **kwargs, windows_expand_args=False)
  File "/usr/local/lib/python3.10/dist-packages/pipenv/vendor/click/core.py", line 1078, in main
    rv = self.invoke(ctx)
  File "/usr/local/lib/python3.10/dist-packages/pipenv/vendor/click/core.py", line 1688, in invoke
    return _process_result(sub_ctx.command.invoke(sub_ctx))
  File "/usr/local/lib/python3.10/dist-packages/pipenv/vendor/click/core.py", line 1434, in invoke
    return ctx.invoke(self.callback, **ctx.params)
  File "/usr/local/lib/python3.10/dist-packages/pipenv/vendor/click/core.py", line 783, in invoke
    return __callback(*args, **kwargs)
  File "/usr/local/lib/python3.10/dist-packages/pipenv/vendor/click/decorators.py", line 92, in new_func
    return ctx.invoke(f, obj, *args, **kwargs)
  File "/usr/local/lib/python3.10/dist-packages/pipenv/vendor/click/core.py", line 783, in invoke
    return __callback(*args, **kwargs)
  File "/usr/local/lib/python3.10/dist-packages/pipenv/cli/command.py", line 209, in install
    do_install(
  File "/usr/local/lib/python3.10/dist-packages/pipenv/routines/install.py", line 164, in do_install
    do_init(
  File "/usr/local/lib/python3.10/dist-packages/pipenv/routines/install.py", line 680, in do_init
    do_install_dependencies(
  File "/usr/local/lib/python3.10/dist-packages/pipenv/routines/install.py", line 438, in do_install_dependencies
    batch_install(
  File "/usr/local/lib/python3.10/dist-packages/pipenv/routines/install.py", line 503, in batch_install
    deps_to_install = [
  File "/usr/local/lib/python3.10/dist-packages/pipenv/routines/install.py", line 506, in <listcomp>
    if not project.environment.is_satisfied(dep)
  File "/usr/local/lib/python3.10/dist-packages/pipenv/project.py", line 515, in environment
    self._environment = self.get_environment(allow_global=allow_global)
  File "/usr/local/lib/python3.10/dist-packages/pipenv/project.py", line 501, in get_environment
    environment = Environment(
  File "/usr/local/lib/python3.10/dist-packages/pipenv/environment.py", line 77, in __init__
    self._base_paths = self.get_paths()
  File "/usr/local/lib/python3.10/dist-packages/pipenv/environment.py", line 377, in get_paths
    c = subprocess_run(command)
  File "/usr/local/lib/python3.10/dist-packages/pipenv/utils/processes.py", line 72, in subprocess_run
    return subprocess.run(
  File "/usr/lib/python3.10/subprocess.py", line 503, in run
    with Popen(*popenargs, **kwargs) as process:
  File "/usr/lib/python3.10/subprocess.py", line 971, in __init__
    self._execute_child(args, executable, preexec_fn, close_fds,
  File "/usr/lib/python3.10/subprocess.py", line 1863, in _execute_child
    raise child_exception_type(errno_num, err_msg, err_filename)
FileNotFoundError: [Errno 2] No such file or directory: '/home/mailparser/.local/share/virtualenvs/mta-log-parser-061DVdP6/bin/python'

Hmmm... I didn't had much time for testing non-dockerized applience. I'll check as soon as I can.

(currently Ubuntu 22.04) is missing something?

Hello! Finally had some time for tests. I used the same environment as you (Ubuntu 22.04, Python3.10). I've passed all the steps. One issue was only at python-ldap build. In my case it was fixed by apt-get install build-essentials libsasl2-dev python-dev-is-python3 libldap2-dev libssl-dev before pipenv install. Also I've changed in pipfile required python version to wildcard 3 version, so my pipfile was:

[source]]
name = "pypi"
url = "https://pypi.org/simple"
verify_ssl = true

[dev-packages]

[packages]
privex-helpers = ">=2.14.0"
privex-loghelper = ">=1.0.6"
python-dateutil = "*"
pytz = "*"
rethinkdb = ">=2.4.7"
python-dotenv = "*"
quart = "=0.19.4"
werkzeug = "=3.0.1"
moment = "*"
datefinder = "*"
python-ldap = "*"

[requires]
python_version = "3"

Also make sure you have successfully pre-installed all necessary from the instruction.
I'll add some info to the repo README.
Good luck!
I'll close this issue as I can't reproduce it. If you have some more info about this issue feel free to reopen it.