I'm having a similar problem with SQLAlchemy and Json and I'm using
the latest TurboJson:
Page handler: <bound method Root.index of <vpstest.controllers.Root
object at 0x2a99eaf410>>
Traceback (most recent call last):
File "/usr/local/lib/python2.5/site-packages/CherryPy-2.2.1-
py2.5.egg/cherrypy/_cphttptools.py", line 105, in _run
self.main()
File "/usr/local/lib/python2.5/site-packages/CherryPy-2.2.1-
py2.5.egg/cherrypy/_cphttptools.py", line 254, in main
body = page_handler(*virtual_path, **self.params)
File "<string>", line 3, in index
File "/home/vps/turbogears/branches/1.0/turbogears/turbogears/
controllers.py", line 352, in <lambda>
expose = lambda func, *args, **kw: func(*args, **kw)
File "<string>", line 3, in index
File "/home/vps/turbogears/branches/1.0/turbogears/turbogears/
controllers.py", line 344, in expose
*args, **kw)
File "<string>", line 5, in run_with_transaction
File "/home/vps/turbogears/branches/1.0/turbogears/turbogears/
database.py", line 366, in sa_rwt
retval = func(*args, **kw)
File "<string>", line 5, in _expose
File "/home/vps/turbogears/branches/1.0/turbogears/turbogears/
controllers.py", line 239, in <lambda>
_func, "json", None, None, None, False, args, kw))
File "/home/vps/turbogears/branches/1.0/turbogears/turbogears/
controllers.py", line 399, in _execute_func
return _process_output(output, template, format, content_type,
mapping, fragment)
File "/home/vps/turbogears/branches/1.0/turbogears/turbogears/
controllers.py", line 86, in _process_output
fragment=fragment)
File "/home/vps/turbogears/branches/1.0/turbogears/turbogears/view/
base.py", line 129, in render
return engine.render(**kw)
File "/home/vps/TurboJson/trunk/turbojson/jsonsupport.py", line 24,
in render
return jsonify.encode(info)
File "/home/vps/TurboJson/trunk/turbojson/jsonify.py", line 115, in
encode
return _instance.encode(obj)
File "build/bdist.linux-x86_64/egg/simplejson/encoder.py", line 352,
in encode
chunks = list(self.iterencode(o))
File "build/bdist.linux-x86_64/egg/simplejson/encoder.py", line 297,
in _iterencode
for chunk in self._iterencode_dict(o, markers):
File "build/bdist.linux-x86_64/egg/simplejson/encoder.py", line 263,
in _iterencode_dict
for chunk in self._iterencode(value, markers):
File "build/bdist.linux-x86_64/egg/simplejson/encoder.py", line 305,
in _iterencode
for chunk in self._iterencode_default(o, markers):
File "build/bdist.linux-x86_64/egg/simplejson/encoder.py", line 311,
in _iterencode_default
newobj = self.default(o)
File "/home/vps/TurboJson/trunk/turbojson/jsonify.py", line 107, in
default
return jsonify(obj)
File "<string>", line 5, in jsonify
File "_d_speedups.pyx", line 403, in
_d_speedups.BaseDispatcher.__getitem__
File "build/bdist.linux-x86_64/egg/dispatch/interfaces.py", line 15,
in __call__
raise self.__class__(*self.args+(args,kw))
NoApplicableMethods: ((<sqlalchemy.engine.base.ResultProxy object at
0x2a987a3790>,), {})
It works fine without an SA object.
Chris
On Aug 24, 6:13 pm, Paul Johnston <[EMAIL PROTECTED]> wrote:
> Hi,
>
> >I am new in TG and still going through examples and documentation. So
> >I tried to connect TG andflexlike Bruce Eckel and James Ward did in
> >video tutorial, but instead of using SQLObject I am using Sqlalchemy.
>
> Ok, this is now possible with the latest development version of
> TurboJSON. To install it:
>
> easy_installhttp://svn.turbogears.org/projects/TurboJson/trunk
>
> Paul
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"TurboGears" 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/turbogears?hl=en
-~----------~----~----~----~------~----~------~--~---