question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

"conflict with the backend dependencies" error running pip install in editable mode with pyproject.toml / PEP-517 enabled project

See original GitHub issue

Environment

  • pip version: 19.0.2
  • Python version: 2.7.15
  • OS: travis xenial

Description

Around a day ago, my cron-triggered builds on Travis for one projects started failing with Some build dependencies for file:///home/travis/build/cjw296/carly conflict with the backend dependencies: attrs==19.1.0 is incompatible with attrs<19.0 ,>=18.2. when being installed by poetry. Looks like under the hood, poetry is calling ['/home/travis/virtualenv/python2.7.15/bin/pip', 'install', '-e', '/ home/travis/build/cjw296/carly', '--no-deps'] which would suggest that dependencies should be ignored.

The full build log for this first failure is here: https://travis-ci.org/cjw296/carly/jobs/501041034

There is a poetry issue open for this here: https://github.com/sdispater/poetry/issues/826

It’s unclear whether this is a poetry bug or a pip bug, but it appears that either downgrading to pip 18.x or removing the build-system section from pyproject.toml stop this happening.

What’s super confusing is that my particular builds are run nightly and they only started failing on 3rd March, even though neither pip nor poetry had any releases around that date, and I haven’t made any code changes to carly since 20th Feb.

Expected behavior

This build log shows expected behaviour: https://travis-ci.org/cjw296/carly/jobs/500733549

How to Reproduce

These are the steps: https://github.com/cjw296/carly/blob/6ec7eedea9c8405ea6a61f733cb7ee9dfaa9b801/.travis.yml#L21-L23

These should be run against https://github.com/cjw296/carly/tree/6ec7eedea9c8405ea6a61f733cb7ee9dfaa9b801

Output

$ curl -sSL https://raw.githubusercontent.com/sdispater/poetry/master/get-poetry.py | python
Retrieving Poetry metadata
# Welcome to Poetry!
This will download and install the latest version of Poetry,
a dependency and package manager for Python.
It will add the `poetry` command to Poetry's bin directory, located at:
$HOME/.poetry/bin
This path will then be added to your `PATH` environment variable by
modifying the profile files located at:
$HOME/.profile
$HOME/.bash_profile
You can uninstall at any time with `poetry self:uninstall`,
or by executing this script with the --uninstall option,
and these changes will be reverted.
Installing version: 0.12.11
  - Downloading poetry-0.12.11-linux.tar.gz (8.00MB)
Poetry (0.12.11) is installed now. Great!
To get started you need Poetry's bin directory ($HOME/.poetry/bin) in your `PATH`
environment variable. Next time you log in this will be done
automatically.
To configure your current shell run `source $HOME/.poetry/env`
install.2
0.00s$ source $HOME/.poetry/env
23.50s$ poetry install
Updating dependencies
Resolving dependencies... (5.7s)
Package operations: 12 installs, 1 update, 0 removals
Writing lock file
  - Installing idna (2.8)
  - Updating six (1.11.0 -> 1.12.0)
  - Installing automat (0.7.0)
  - Installing constantly (15.1.0)
  - Installing hyperlink (18.0.0)
  - Installing incremental (17.5.0)
  - Installing pyhamcrest (1.9.0)
  - Installing txaio (18.8.1)
  - Installing zope.interface (4.6.0)
  - Installing autobahn (18.12.1)
  - Installing coverage (4.4.2)
  - Installing testfixtures (6.6.0)
  - Installing twisted (18.9.0)
  - Installing carly (0.9.1)
                                                                                
[EnvCommandError]                                                
Command ['/home/travis/virtualenv/python2.7.15/bin/pip', 'install', '-e', '/        
home/travis/build/cjw296/carly', '--no-deps'] errored with the following out  
put:                                                                          
DEPRECATION: Python 2.7 will reach the end of its life on January 1st, 2020.  
 Please upgrade your Python as Python 2.7 won't be maintained after that dat  
e. A future version of pip will drop support for Python 2.7.                  
Obtaining file:///home/travis/build/cjw296/carly                              
  Installing build dependencies: started                                      
  Installing build dependencies: finished with status 'done'                  
  Getting requirements to build wheel: started                                
  Getting requirements to build wheel: finished with status 'done'            
Some build dependencies for file:///home/travis/build/cjw296/carly conflict   
with the backend dependencies: attrs==19.1.0 is incompatible with attrs<19.0  
,>=18.2.                                                                      
                                                                                
install [--no-dev] [--dry-run] [-E|--extras EXTRAS] [--develop DEVELOP]
The command "poetry install" failed and exited with 1 during .
Your build has been stopped.

Issue Analytics

  • State:closed
  • Created 5 years ago
  • Comments:27 (18 by maintainers)

github_iconTop GitHub Comments

1reaction
takluyvercommented, Mar 6, 2019

Yup, I’m not against trying to specify some hook for editable installs. But I’m happy enough to let it rest for now.

0reactions
lock[bot]commented, May 28, 2019

This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs.

Read more comments on GitHub >

github_iconTop Results From Across the Web

How to install a package using pip in editable mode with ...
ERROR : Project file:///tmp/demo has a 'pyproject.toml' and its build backend is missing the 'build_editable' hook. Since it does not have a 'setup.py'...
Read more >
Pip 19.1 and installing in editable mode with pyproject.toml
projects using a PEP 517 backend that doesn't support python setup.py develop (likely because they don't include a setup.py file) won't be using...
Read more >
History | Poetry - Python dependency management and ...
Fix an issue where the installation of dependencies failed if pip is a dependency and is updated in parallel to other dependencies (#6582)....
Read more >
Search - pip documentation v23.0.dev0
Enable new functionality, that may be backward incompatible. ... pip uses the PEP 517 build_wheel hook that has to be provided by the...
Read more >
Dependency Management With Python Poetry
Start a new Poetry project; Add Poetry to an existing project; Use the pyproject.toml file; Pin dependencies; Install dependencies with poetry.lock ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found