Usually when I see "TypeError Exception Value: coercing to Unicode" it means that some Model isn't returning the right thing in def __unicode__. Looking at your code, I recommend checking out the canvas returned by desenha_grafico. I wasn't able to find the documentation for matplotlib, so I'm not sure which functions require strings.
On May 23, 2012, at 6:53 AM, Waleria wrote:
> It shows this line:
>
> File "C:\simuladores\..\simuladores\detector\views.py" in pdf
> 259. canvas.print_pdf(response, facecolor='w', edgecolor='w')
> File "C:\Python26\Lib\site-packages\matplotlib\backend_bases.py" in
> print_pdf
> 1334. return pdf.print_pdf(*args, **kwargs)
>
> In my code this line is: dir(canvas.print_pdf)
> canvas.print_pdf(response, facecolor='w', edgecolor='w')
>
> but I do not know about solving.
>
> On 23 maio, 09:37, kenneth gonsalves <law...@thenilgiris.com> wrote:
>> On Wed, 2012-05-23 at 05:16 -0700, Waleria wrote:
>>> Exception Type: TypeError Exception Value: coercing to Unicode: need
>>> string or buffer, dict found
>>
>> you have to find out where in the code the error is coming. Then you
>> will find that you are passing a dict instead of a string.
>> --
>> regards
>> Kenneth Gonsalves
>
> --
> You received this message because you are subscribed to the Google Groups "Django users" group.
> To post to this group, send email to django-users@googlegroups.com.
> To unsubscribe from this group, send email to django-users+unsubscribe@googlegroups.com.
> For more options, visit this group at http://groups.google.com/group/django-users?hl=en.
>
Peter of the Norse
RahmCoff@Radio1190.org
--
You received this message because you are subscribed to the Google Groups "Django users" group.
To post to this group, send email to django-users@googlegroups.com.
To unsubscribe from this group, send email to django-users+unsubscribe@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/django-users?hl=en.
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment