[issue1272] Decode __file__ and co_filename to unicode using fs default

Christian Heimes report at bugs.python.org
Sun Oct 14 02:43:59 CEST 2007


Christian Heimes added the comment:

Guido van Rossum wrote:
> But that function is a terrible example; it was done that way because
> an earlier version of the function *did* allow using the errors
> argument and I wanted to make sure to catch all calls that were still
> passing an errors value. This doesn't apply here, we're creating a
> brand new API.

Ahhh! I really didn't know it. I thought that the non functional
arguments have a purpose.

> Anyway, let me know if you want to change something in Alexandre's
> version or if you want him to check it in.

I'm going to create a new patch based on his fixes and your recommendations.

> Oh. Hm. I still wish that PyCode_New() could just insist that the
> filename argument is a PyUnicode instance. Why can't it? Perhaps the
> caller should be fixed instead?

I'll try.

__________________________________
Tracker <report at bugs.python.org>
<http://bugs.python.org/issue1272>
__________________________________


More information about the Python-bugs-list mailing list