views:

40

answers:

1

I'm trying to code an application that can work for several projects. I'm facing a problem that I have always to specify the name of the project when I do the imports like doing import some_project_name.models inside my app, how can I overcome this coupling so that I can use the app in several projects?

+2  A: 
  1. Move the app to a common directory, outside of any project.

  2. Each project's PYTHONPATH must then include this common directory.

S.Lott