On 2005-11-03 21:42:43 -0800, modmans2ndcoming wrote: > > eh, I gave up and used an abs path. > > it would be nice though. I think the issue is that the SQLite binary is > located in a different location than your TG files so if you use a rel > path, it will look in the directory that the SQLite binary is.
you could take sort of an intermediate solution and do something like:
import os.path
db_path =
os.path.abspath(os.path.normpath(os.path.join(os.path.dirname(__file__),
"../my_database.db")))
it's a little ugly to look at but lets you basically figure out an
absolute path for the file based on a path relative to whatever .py file
that code is in.
--
anders pearson : http://www.columbia.edu/~anders/
C C N M T L : http://www.ccnmtl.columbia.edu/
weblog : http://thraxil.org/
pgpQ2Q1DxkpFb.pgp
Description: PGP signature

