Thanks for your answers, I'll try to choose a solution that suits our
needs best :-)
2009/9/10 Andrew Gwozdziewycz :
>
> This whole discussion is pretty much what virtualenv solves
> http://pypi.python.org/pypi/virtualenv
>
> Basically, for each package that you wanna reuse,
This whole discussion is pretty much what virtualenv solves
http://pypi.python.org/pypi/virtualenv
Basically, for each package that you wanna reuse, install it into the
virtualenv for the project your working on. It works great.
On Sep 10, 2:00 pm, Brian Jones wrote:
> Well,
Well, it's not a solution you'd use in a larger team environment, because it
causes confusion, but if you're just trying to put off the renaming issue
(which really isn't that hard - what's wrong with that solution?), you can
just create a symbolic link to the directory on your PYTHONPATH instead
> Your choice. I prefer the first method. Changing the imports isn't
> terribly difficult (global find and replace) for the few times the
> project folder gets renamed.
Unless of course, you are using distributed source control and want to
have seperate repo for every larger feature. Then it
Well there are really two options I think.
The first option is how you were doing it:
from project_folder.app_name.models import SomeModel
You also found out the problem with this method. If you rename
project_folder, you have to change all the imports in your project.
The other option is to
I would like to ask, what is the blessed way of importing different
modules inside django project. Until this moment I have used something
like this:
from ..models import SomeModel
However, this is no good for me. When I changed name of the directory
holding the project (I have created branch
6 matches
Mail list logo