guake icon indicating copy to clipboard operation
guake copied to clipboard

Unable to run `make build` with pipenv >=2022.10.9

Open theCapypara opened this issue 1 year ago • 2 comments

Background:

I wanted to add something to Guake and because of this wanted to checkout the code locally and set it up for development. For that I had a look at the CI and tried to run all make commands used there to make sure I am having a stable environment to work with.

Describe the bug

I am however unable to run make build locally without issues.

Expected behavior

When checking out the project from source, as described in the docs ( https://guake.readthedocs.io/en/stable/user/installing.html#install-from-source )I expect make build to run through without errors after installing dependencies via pipenv install --dev.

Actual behavior

The pipenv_to_requirements step fails:

PIPENV_IGNORE_VIRTUALENVS=1 pipenv run pipenv_to_requirements
Traceback (most recent call last):
  File "/home/marco/.local/share/virtualenvs/guake-bcq_gztv/bin/pipenv_to_requirements", line 8, in <module>
    sys.exit(main())
  File "/home/marco/.local/share/virtualenvs/guake-bcq_gztv/lib/python3.10/site-packages/pipenv_to_requirements/__init__.py", line 115, in main
    def_req = parse_pip_file(pipfile, 'default')
  File "/home/marco/.local/share/virtualenvs/guake-bcq_gztv/lib/python3.10/site-packages/pipenv_to_requirements/__init__.py", line 66, in parse_pip_file
    return [clean_version(n, i) for n, i in pipfile.get(section, {}).items()]
AttributeError: 'function' object has no attribute 'get'

Upstream issue: https://github.com/gsemet/pipenv-to-requirements/issues/25 Upstream PR: https://github.com/gsemet/pipenv-to-requirements/pull/26

To Reproduce

See above + see below for my installed package versions.

OS: Arch Linux Python: 3.10.9 pipenv: 2022.12.19 (The last successful build on Github Actions used 2022.11.30 for reference - referring back to the issue above, I'm surprised that this works. The issue might not simply be the pipenv version.)

Installed packages in the venv:

alabaster==0.7.13
astroid==2.13.3
attrs==22.2.0
autopep8==1.5.7
Babel==2.11.0
black==21.8b0
bleach==6.0.0
certifi==2022.12.7
cffi==1.15.1
cfgv==3.3.1
charset-normalizer==3.0.1
click==8.1.3
colorama==0.4.6
colorlog==6.7.0
coverage==7.1.0
cryptography==39.0.0
dbus-python==1.3.2
dill==0.3.6
distlib==0.3.6
docutils==0.17.1
dulwich==0.21.2
entrypoints==0.4
exceptiongroup==1.1.0
filelock==3.9.0
fiximports==0.1.18
flake8==3.9.2
flakehell==0.9.0
-e git+https://github.com/Guake/guake.git@2e5e309e889b15f0ff0970350cf58b70cf12db74#egg=guake
identify==2.5.15
idna==3.4
imagesize==1.4.1
importlib-metadata==6.0.0
iniconfig==2.0.0
isort==5.11.4
jaraco.classes==3.2.3
jeepney==0.8.0
Jinja2==3.1.2
keyring==23.13.1
lazy-object-proxy==1.9.0
markdown-it-py==2.1.0
MarkupSafe==2.1.2
mccabe==0.6.1
mdurl==0.1.2
mock==5.0.1
more-itertools==9.0.0
mypy-extensions==0.4.3
nodeenv==1.7.0
packaging==23.0
pathlib2==2.3.7.post1
pathspec==0.11.0
pbr==5.11.1
pep8==1.7.1
pew==1.2.0
pipenv==2022.12.19
pipenv-to-requirements==0.9.0
pkginfo==1.9.6
platformdirs==2.6.2
pluggy==1.0.0
pre-commit==2.17.0
pycairo==1.23.0
pycodestyle==2.7.0
pycparser==2.21
pyfakefs==5.1.0
pyflakes==2.3.1
Pygments==2.14.0
PyGObject==3.42.2
pylint==2.15.10
pytest==7.2.1
pytest-cov==4.0.0
pytest-mock==3.10.0
pytz==2022.7.1
PyYAML==6.0
readme-renderer==37.3
regex==2022.10.31
reno==3.5.0
requests==2.28.2
requests-toolbelt==0.10.1
rfc3986==2.0.0
rich==13.2.0
scandir==1.10.0
SecretStorage==3.3.3
setuptools-scm==7.1.0
six==1.16.0
snowballstemmer==2.2.0
Sphinx==5.3.0
sphinx-rtd-theme==1.1.1
sphinxcontrib-applehelp==1.0.4
sphinxcontrib-devhelp==1.0.2
sphinxcontrib-htmlhelp==2.0.0
sphinxcontrib-jsmath==1.0.1
sphinxcontrib-programoutput==0.17
sphinxcontrib-qthelp==1.0.3
sphinxcontrib-serializinghtml==1.1.5
toml==0.10.2
tomli==1.2.3
tomlkit==0.11.6
twine==4.0.2
typed-ast==1.5.4
typing==3.7.4.3
typing_extensions==4.4.0
urllib3==1.26.14
virtualenv==20.17.1
virtualenv-clone==0.5.7
webencodings==0.5.1
wrapt==1.14.1
yapf==0.32.0
zipp==3.11.0

theCapypara avatar Jan 25 '23 22:01 theCapypara

Oh, and I can confirm that make build runs when downgrading pipenv to 2022.10.4.

theCapypara avatar Jan 25 '23 22:01 theCapypara

Can confirm pretty similar issue with pipenv, version 2018.11.2

✔ Successfully created virtual environment!
Virtualenv location: /home/spooky/.local/share/virtualenvs/guake-3CFDnMV3
Installing dependencies from Pipfile.lock (3de430)…
Traceback (most recent call last):
  File "/home/spooky/.local/bin/pipenv", line 8, in <module>
    sys.exit(cli())
  File "/home/spooky/.local/lib/python3.10/site-packages/pipenv/vendor/click/core.py", line 764, in __call__
    return self.main(*args, **kwargs)
  File "/home/spooky/.local/lib/python3.10/site-packages/pipenv/vendor/click/core.py", line 717, in main
    rv = self.invoke(ctx)
  File "/home/spooky/.local/lib/python3.10/site-packages/pipenv/vendor/click/core.py", line 1137, in invoke
    return _process_result(sub_ctx.command.invoke(sub_ctx))
  File "/home/spooky/.local/lib/python3.10/site-packages/pipenv/vendor/click/core.py", line 956, in invoke
    return ctx.invoke(self.callback, **ctx.params)
  File "/home/spooky/.local/lib/python3.10/site-packages/pipenv/vendor/click/core.py", line 555, in invoke
    return callback(*args, **kwargs)
  File "/home/spooky/.local/lib/python3.10/site-packages/pipenv/vendor/click/decorators.py", line 64, in new_func
    return ctx.invoke(f, obj, *args, **kwargs)
  File "/home/spooky/.local/lib/python3.10/site-packages/pipenv/vendor/click/core.py", line 555, in invoke
    return callback(*args, **kwargs)
  File "/home/spooky/.local/lib/python3.10/site-packages/pipenv/vendor/click/decorators.py", line 17, in new_func
    return f(get_current_context(), *args, **kwargs)
  File "/home/spooky/.local/lib/python3.10/site-packages/pipenv/cli/command.py", line 235, in install
    retcode = do_install(
  File "/home/spooky/.local/lib/python3.10/site-packages/pipenv/core.py", line 1863, in do_install
    do_init(
  File "/home/spooky/.local/lib/python3.10/site-packages/pipenv/core.py", line 1246, in do_init
    do_install_dependencies(
  File "/home/spooky/.local/lib/python3.10/site-packages/pipenv/core.py", line 809, in do_install_dependencies
    deps_list = list(lockfile.get_requirements(dev=dev, only=requirements))
  File "/home/spooky/.local/lib/python3.10/site-packages/pipenv/vendor/requirementslib/models/lockfile.py", line 272, in get_requirements
    yield Requirement.from_pipfile(k, v)
  File "/home/spooky/.local/lib/python3.10/site-packages/pipenv/vendor/requirementslib/models/requirements.py", line 1185, in from_pipfile
    r = FileRequirement.from_pipfile(name, pipfile)
  File "/home/spooky/.local/lib/python3.10/site-packages/pipenv/vendor/requirementslib/models/requirements.py", line 583, in from_pipfile
    link = create_link(uri)
  File "/home/spooky/.local/lib/python3.10/site-packages/pipenv/vendor/requirementslib/models/utils.py", line 40, in create_link
    return Link(link)
TypeError: 'NoneType' object is not callable
make: *** [Makefile:61: pipenv-install-dev] Error 1
```

0scvr avatar Oct 09 '23 22:10 0scvr