On 2/22/07, Pearl <[EMAIL PROTECTED]> wrote:
>
> > In Kid page used it
> > ----------------------------
> > onclick="edituser(${jsonify(conf_info)}, ${rowid})"
>
> I made a change,  added tg.jsonify:
> onclick="edituser(${tg.jsonify(conf_info)}, ${rowid})"

Right.. sorry I forgot that earlier.

> For a dictionary dic returned from the python code
> dic = {'a':'fdf','b':'dsdsd','c':'erere'}
>
> The error displayed is :
>   File "<string>", line 5, in jsonify
>   File "_speedups.pyx", line 362, in
> _speedups.BaseDispatcher.__getitem__
>   File "C:\Python24\lib\site-packages\ruledispatch-0.5a0.dev_r2115-
> py2.4-win32.egg\dispatch\interfaces.py", line 15, in __call__
> NoApplicableMethods: (({'a': 'fdf', 'c': 'erere', 'b': 'dsdsd'},), {})
> Error in code generated from template file 'C:\\The....
>
> Please let me know where I am doing the wrong thing.

Ditto to Diez's post, what exactly is conf_info?

To clarify the error, jsonify uses ruledispatch generics to dispatch
to the correct jsonifiier based on what kind of objects you send to
jsonify. The rule is saying that it can't find an applicable method
for the type of object you sent down.

It can definately handle dicts - so conf_info must be something else.

Arnar

--~--~---------~--~----~------------~-------~--~----~
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
-~----------~----~----~----~------~----~------~--~---

Reply via email to