You can modify sys.path in an __init__.py in your context directory: import sys sys.path.insert(0, '/foo/bar')
This is guaranteed to be imported before any of the servlets or PSPs in the directory. - Geoff > -----Original Message----- > From: Andrey Khavryuchenko [mailto:[EMAIL PROTECTED]] > Sent: Monday, May 20, 2002 12:38 PM > To: [EMAIL PROTECTED] > Subject: [Webware-discuss] can I separate directories with > .psp and .py? > > > Hi! > > I'd like to keep core sources separate from user interface psp files. > Thus, I've added context with path of user interface > 'Contexts': { > > 'Admin': '%(WebKitPath)s/Admin', > > 'Examples': '%(WebKitPath)s/Examples', > > 'Docs': '%(WebKitPath)s/Docs', > > 'Testing': '%(WebKitPath)s/Testing', > 'Project': '/bla-bla-bla/project/ui', > > 'default': '%(WebKitPath)s/Examples', ##MAWD > }, > > But, when I try to import core source classes from psp: > <%@page imports="my.project.class"%> > the WebKit can't find it for obvious reasons -- they are located under > /bla-bla-bla/project/src > > Is there a way to add the src path to the sys.path via > configuration file? > > Thanks in advance! > > -- > Andrey V Khavryuchenko http://www.kds.com.ua/ > Offshore Software Development > > _______________________________________________________________ > Hundreds of nodes, one monster rendering program. > Now that's a super model! Visit http://clustering.foundries.sf.net/ > > _______________________________________________ > Webware-discuss mailing list > [EMAIL PROTECTED] > https://lists.sourceforge.net/lists/listinfo/webware-discuss > _______________________________________________________________ Don't miss the 2002 Sprint PCS Application Developer's Conference August 25-28 in Las Vegas -- http://devcon.sprintpcs.com/adp/index.cfm _______________________________________________ Webware-discuss mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/webware-discuss
