Malcolm,

Thanks for the explanation, I did mean to reply to your other message,
sorry for working on your nerves.

I understand now why it's a bad idea to use setdefaultencoding().

Bert

On Nov 1, 4:12 am, Malcolm Tredinnick <[EMAIL PROTECTED]>
wrote:
> On Wed, 2007-10-31 at 10:10 -0700, Bert Heymans wrote:
> > Malcolm,
>
> > I found this thread, someone who claims to maintain the Python FAQ
> > says it's OK to use the routine but(!) only in sitecustomize.py:
>
> By "that routine", I guess you meant setdefaultencoding() [see the
> problem with top-posting... there's no context for your answer, and in
> this case, even reading the entire message of mine you quote, I can't
> see where this arose in that message. Still, let's struggle onwards.]
>
> >http://groups.google.com/group/comp.lang.python/browse_frm/thread/464...
>
> Search on django-dev. There are a number of posts where it's recommended
> not to use it, by developers (e.g. in [1]). It's been considered an
> error that it wasn't removed after the initial experimentation period.
> Customizing your site, particularly your site encoding introduces the
> risk of non-portability, since assumptions that are made throughout
> Python are now not necessarily true.
>
> Change the default encoding at your own risk and, if things break, stop
> doing that. You can't rely on it being true on other machines, after
> all, so if you want code that is at all portable, you must assume the
> default encoding is ASCII.
>
> [1]http://mail.python.org/pipermail/python-dev/2007-June/073593.html
>
>
>
> > I'm kind of confused now, ...
>
> > Especially after reading PEP100:
>
> >http://www.python.org/dev/peps/pep-0100/
>
> PEP 100 is quite old. As it mentions, it actually pre-dates PEPs and
> whilst it discusses setdefaultencoding(), it doesn't recommend using it
> (or not recommend -- it's a spec, not a best practices document, for
> better or worse) .
>
> Malcolm
>
> --
> Plan to be spontaneous - tomorrow.http://www.pointy-stick.com/blog/


--~--~---------~--~----~------------~-------~--~----~
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 [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/django-users?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to