This happened to me just recently and I had to explicitly add the full
path to pysqlite to PYTHONPATH. I'm sure there is a better way of
doing it, but (on Windows) I had to add:

C:\Python24\Lib\site-packages\pysqlite2
explicitly, even though I already had the site-packages path added.

Hope this helps.

On 29/09/06, Randy Groves <[EMAIL PROTECTED]> wrote:
>
> Attempting to install the new 0.10 version.  Had a 0.96 installed
> before.  As recommended in the UPGRADE file, I removed the 'trac'
> directory from site-packages, moved the share/trac directories
> aside.  The environment is in its infancy, so I'm starting with a new one.
>
> Pysqlite 2.3.2 is installed, and  Sqlite 3.3.7.  Previous trac worked
> fine with it.
>
> After install of new trac, attempt to init a new environment.  The result:
>
> ...
>
> Database connection string [sqlite:db/trac.db]>
>
>   Please specify the type of version control system,
>   By default, it will be svn.
>
>   If you don't want to use Trac with version control integration,
>   choose the default here and don't specify a repository directory.
>   in the next question.
>
> Repository type [svn]>
>
>   Please specify the absolute path to the version control
>   repository, or leave it blank to use Trac without a repository.
>   You can also set the repository location later.
>
> Path to repository [/path/to/repos]> /usr/local/fiwiki/svn/pyses
>
>   Please enter location of Trac page templates.
>   Default is the location of the site-wide templates installed with Trac.
>
> Templates directory [/usr/local/oss/share/trac/templates]>
> Creating and Initializing Project
> Failed to create environment. global name 'sqlite' is not defined
> Traceback (most recent call last):
>    File
> "/usr/local/oss/lib/python2.4/site-packages/trac/scripts/admin.py",
> line 611, in do_initenv
>      options=options)
>    File "/usr/local/oss/lib/python2.4/site-packages/trac/env.py",
> line 124, in __init__
>      self.create(options)
>    File "/usr/local/oss/lib/python2.4/site-packages/trac/env.py",
> line 228, in create
>      DatabaseManager(self).init_db()
>    File "/usr/local/oss/lib/python2.4/site-packages/trac/db/api.py",
> line 65, in init_db
>      connector.init_db(**args)
>    File
> "/usr/local/oss/lib/python2.4/site-packages/trac/db/sqlite_backend.py",
> line 121, in init_db
>      cnx = sqlite.connect(path, timeout=int(params.get('timeout', 10000)))
> NameError: global name 'sqlite' is not defined
> Failed to initialize environment. 1
> Traceback (most recent call last):
>    File
> "/usr/local/oss/lib/python2.4/site-packages/trac/scripts/admin.py",
> line 615, in do_initenv
>      sys.exit(1)
> SystemExit: 1
>
> What gives?
>
> -randy
>
>
>
> >
>

--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Trac 
Users" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at http://groups.google.com/group/trac-users
-~----------~----~----~----~------~----~------~--~---

Reply via email to