shaunvxc / envy

:memo: safely make edits and sync local changes to files living in the site-packages of your virtualenvs
MIT License
39 stars 3 forks source link

envy assumes the package directory is the same as the package name #10

Closed amitsaha closed 8 years ago

amitsaha commented 8 years ago

I could be wrong, but I think envy assumes that the package lives in a sub-directory which is of the same name as the package itself (Ref: https://github.com/shaunvxc/envy/blob/c5a08ea6ee4218eb3b66dd97fd1c750faae03dd6/envy/application.py#L99)

It's probably easy to reproduce by having a setup.py where the packages_dir is set to something else other than name.

shaunvxc commented 8 years ago

@amitsaha Can you give me more details regarding this? Were you running envy edit or envy sync? It would be helpful if you provide some detail of the package structure for which you were having issues, so that I can reproduce!

Thanks!

amitsaha commented 8 years ago

Hi @shaunvxc i was running envy sync. I will share an easy reproducer for you in the next days. But for the moment, you may try with a setup.py which has find_packages() in it and the package directory is named something other than the package name you use in setup.py.

shaunvxc commented 8 years ago

@amitsaha can you confirm you were passing envy sync the package name and not the distribution name?

envy uses the imp module to find the location of the package-- so as long as you pass envy the package name, it should work.

Let me know if otherwise!

shaunvxc commented 8 years ago

@amitsaha can you confirm the above please when you have the chance? Would like to close this assuming the above is correct.

Thanks!

shaunvxc commented 8 years ago

@amitsaha I'm going to close this. Re-open please if you are still having issues.