Warning: Can't synchronize with repository "(default)" (Unsupported version control system "svn": No module named svn). Look in the Trac log for more information.

Ticket #1455 (closed enhancement: fixed)

Opened 12 years ago

Last modified 10 years ago

quickstart project without identity should not require a database

Reported by: Chris Arndt Owned by: anonymous
Priority: normal Milestone: 1.1
Component: TurboGears Version: 1.0.3
Severity: normal Keywords: quickstart, identity


A quickstarted project without identity should not require a database by importing a database module (e.g. in model.py) or setting dburi in dev.cfg.

Rationale: in startup.py if dburi is set, it tries to initialize the database. This will fail if SQLAlchemy is not installed. If model.py imports a database module, even if no model classes are defined yet, tg-admin shell or tg-admin sql ... will also fail without the database module.

If the project does not require a database, you should be able to start the project without having an ORM module installed.

The attached patch (for the 1.1. branch) comments out the default dburi in dev.cfg and the imports in model.py, if identity is not enabled.

The downside of this is, when you want to start the toolbox and use the Model Designer or tg-admin shell or tg-admin sql ... to manipulate the database, you'll have to set the dburi in dev.cfg first. At least the latter tool will warn you, when the dburi is not set.


quickstart-nodb.patch Download (2.4 KB) - added by Chris Arndt 12 years ago.

Change History

Changed 12 years ago by Chris Arndt

comment:1 Changed 11 years ago by Chris Arndt

I'm currently unable to test if this is still an issue because this is blocked by ticket #1933.

comment:2 Changed 11 years ago by faide

  • Milestone changed from 1.5 to 1.1

comment:3 Changed 10 years ago by Chris Arndt

  • Status changed from new to closed
  • Resolution set to fixed

This is fixed with r5493 and r5494.

Note: See TracTickets for help on using tickets.