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