http://www.turbogears.org/preview/
0.9a6 (May 9, 2006)
-------------------
*Backwards Incompatibilities*
* `i18n.runTemplateFilter` in the config file has been renamed
`i18n.run_template_filter` (#796)
* For people using FastData (experimental): `get_add_url`,
`get_edit_url` and `get_delete_url` all are passed the row instead
of the ID now, allowing you to use something other than the ID
if desired.
* In widgets, if you were using a dictionary as a params be aware that now
the dictionary is not updated at construction or display/render time but
simply replaced with the new one.
If you were using it to provide default attributes for your widget, take a
look at how the TableForm does that.
*Features*
* A new function, `turbogears.util.find_precision`, to tell you
how many decimal places of precision are required. (To help
with `i18n.format.format_decimal` which needs to know the
precision.)
* tg-admin info shows which eggs require TurboGears
* In widgets, SelectionField now supports grouped options,
SingleSelectField and MultipleSelectField widgets take advantage of this
to provide an optgroup tag. The format of a grouped options list is like
the following:
options = [(None, [(1, "a"), (2, "b")]), ("Others", [(3, "c"), (4, "d")])]
* The Widget Browser now displays the source of the example and the
template provided by default in the widget (to allow for easier
complete customization) (#840, #841)
* Tabber and Syntax Highlighter widgets are now included
*Changes*
* sqlite database URIs can now be specified as sqlite:///c:/foo/bar on
Windows, which is more natural for users. (The sqlite:///c|/foo/bar
syntax still works.)
* ValueError is raised if an InputWidget contains "." or "-", which are
reserved for use by the widgets
* Package name is used instead of `your_project` in the quickstart
logging config.
*Fixes*
* QUICKSTART: an exception comes up if a user logs in but is not in
a group that is required for access. The line with
`if not identity.current.anonymous and identity.was_login_attempted()`
in controllers.py or root.py needs an additional
`and not identity.get_identity_errors()` condition. (#834)
* QUICKSTART: quickstart projects that used identity would generate
a table called "user", which is invalid for some databases. The
new quickstart model.py generates tables called `tg_user`. #805
* QUICKSTART: there were problems with the model template for SQLAlchemy
(#801)
* SQLAlchemy's identity provider was not selected by default when you
quickstart a new project. (#806)
* Core widgets all include WidgetDescriptions now and appear in the
Widget Browser in the Toolbox (#727)
* Access logging to a file wasn't working correctly (#816)
* Bug fix for convert/`from_python` for compound and repeating widgets
* User name is now encoded to the DB encoding before a query is run
in the SQLObject identity provider
* JSLink widgets can now specify a location
* LocalizableJSLink (and the calendar widget) now work in IE (#846)
* Added scheduler to `turbogears.__init__.__all__` so that references
to it work properly.
* tg-admin info and Toolbox info commands now work properly and show
the same information.
* Fixed a serious bug in Python 2.3 compatibility (#853)
*Project Updates*
* MochiKit updated to 1.3.1 (#804)
*Contributors*
Max Ischenko, Claudio Martinez, Matt Good, Rune Hansen, Michele Cella,
Jorge Godoy, Alberto Valverde González, Simon Belak, Jeroen Dekkers,
Mark Ramm-Christensen, Ronald Jaramillo,
Richard Standbrook, Roger Demetrescu, Patrick Lewis, Hal Wine,
Jorge Vargas, Bob Kuehne.
--
Kevin Dangoor
TurboGears / Zesty News
email: k...@blazingthings.com
company: http://www.BlazingThings.com
blog: http://www.BlueSkyOnMars.com
Could someone give me some tips on how to setup Identity with SQLAlchemy
please?
I've done a fresh install of TurboGears 0.9a6. The install went no problem.
I then ran the tg-admin as below:
$ tg-admin quickstart testme
Enter package name [testme]:
Do you need Identity (usernames/passwords) in this project? [no] yes
Select your provider sqlobject or sqlalchemy [sqlobject]: sqlalchemy
The tg-admin script completed no problem.
I then modified the dev.cfg and change the following line
sqlobject.dburi="sqlite://%(current_dir_uri)s/devdata.sqlite"
to
sqlalchemy.dburi="sqlite://%(current_dir_uri)s/testmedb.sqlite"
I also change "myApp" in the model.py file to "testme".
I then start the app with start-testme.py but I got exception about
"AttributeError: 'thread._local' object has no attribute 'engine'".
Below is the error log.
2006-05-11 10:18:30,030 turbogears.visit INFO Visit Tracking starting
2006-05-11 10:18:30,036 turbogears.visit INFO Visit filter initialised
Unhandled exception in thread started by <bound method Server._start of
<cherrypy._cpserver.Server object at 0xb7bf95ac>>
Traceback (most recent call last):
File "CherryPy-2.2.1-py2.4.egg/cherrypy/_cpserver.py", line 78, in _start
File "CherryPy-2.2.1-py2.4.egg/cherrypy/_cpengine.py", line 108, in _start
File "TurboGears-0.9a6-py2.4.egg/turbogears/startup.py", line 219, in
startTurboGears
File "TurboGears-0.9a6-py2.4.egg/turbogears/visit/api.py", line 68, in
start_extension
File "TurboGears-0.9a6-py2.4.egg/turbogears/visit/api.py", line 87, in
create_extension_model
File "TurboGears-0.9a6-py2.4.egg/turbogears/visit/savisit.py", line 22, in
create_model
File "build/bdist.linux-i686/egg/sqlalchemy/schema.py", line 235, in
create
File "build/bdist.linux-i686/egg/sqlalchemy/ext/proxy.py", line 50, in
__getattr__
File "build/bdist.linux-i686/egg/sqlalchemy/ext/proxy.py", line 114, in
get_engine
AttributeError: 'thread._local' object has no attribute 'engine'
Pierre
I *believe* that this has been fixed in a more recent version of
TurboTinyMCE. Maybe we should make the Widget Browser more robust when
it comes to broken third party widgets...
Try
easy_install -U TurboTinyMCE
Kevin
Do you know what is the problem?
What version of SQLAlchemy are you running? There have been *major*
changes to SQLAlchemy in the 0.2 line, and I don't think ActiveMapper
(or Identity) are caught up to that yet.
Kevin
I'm using SQLAlchemy-0.1.7...
http://trac.turbogears.org/turbogears/ticket/833
--
Jorge Godoy <jgo...@gmail.com>