Skip to content

tasks.py path lookup bug with virtualenv and pip dependency on github project #91

@zheller

Description

@zheller

Hey,

I was using invoke in a project, which had another project as a dependency that was installed via pip's -e flag from a github repository at a specific hash. This dependency also uses invoke and had a tasks.py file.

What happened was that invoke traversed the directory tree backwords and ended up using the tasks.py file in my virtualenv. What happens internally as far as I can tell is pip downloads the repos source in .virtualenv/src and then runs python setup.py develop in order to install it. The tasks.py file in my virtualenv/src directory from my depenedency ended up taking precedence over the tasks.py file in my project repository's top level directory, despite using the -r flag and setting the project root.

For reference, I use virtualenvwrapper and the directory structure looks something like this

~/src/.virtualenvs/<env-name>/src/
~/src/my-project

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions