I've just upgraded a system from:
- TG 1.0.3.2
- SA 0.3.10
- Elixir 0.3 (plus a few patchs...)
to Elixir 0.4 (trunk)
and I get some problems when starting my TG application or trying to get
datas when running tg-admin shell.
The error message is always around not locating any engine or connection...
"This SchemaItem is not connected to any Engine or Connection." or
"Could not locate any Engine or Connection bound to mapper
'Mapper|User|tg_user'"
I've read the information in
http://elixir.ematia.de/trac/wiki/Migrate03to04 and browsed the elixir
list but could not find any clear information.
Is it supposed to work or should I also upgrade to TG 1.0.4 ?
I don't know the specifics about the differences between TG 1.0.3.2
and TG 1.0.4 but I don't *think* there is any reason it wouldn't work
if that worked for you before.
My guess is that you are hitting the __metadata__ vs metadata problem.
http://elixir.ematia.de/trac/wiki/Migrate03to04#Module-levelmetadataandsessionattributes
--
Gaëtan de Menten
http://openhex.org
I found these lines in the template that TG 1.0.4 uses when doing a
"tg-admin quickstart".
Another, more explicit (and IMO cleaner) way would be this:
from turbogears.database import metadata
__metadata__ = metadata
or even
from turbogears.database import metadata as __metadata__
>
> I found these lines in the template that TG 1.0.4 uses when doing a
> "tg-admin quickstart".
>
--
or you'll get errors "object '<xxxx object 0x12345678>' is already
attached to session '22222222' (this is '33333333')"
Thanks for the clarification. Since I have never really developed for
TurboGears, I wasn't sure if that was necessary too.