Lars Gustäbel <l...@gustaebel.de> added the comment:

I thought about that myself, too. It is clearly no new feature, it is really 
more some kind of a fix.

Unicode pathnames given to tarfile.open() are just passed through to the open() 
function, which is why this always has been working, except for this particular 
case. There are 6 different possible write modes: "w:", "w:gz", "w:bz2", "w|", 
"w|gz" and "w|bz2". And the only one not working with a unicode pathname is 
"w|gz". Although admittedly tarfile.open() is not supposed to be used with a 
unicode path, people do it anyway, because they don't care, and because it 
works. The patch does not add a new broad functionality, it merely harmonises 
the way the six write modes work.

Neither can we retroactively enforce using string pathnames at this point, nor 
should we let a user run into this strange error. The patch is very small and 
minimally invasive. The error message you get without the patch is completely 
incomprehensible.

----------

_______________________________________
Python tracker <rep...@bugs.python.org>
<http://bugs.python.org/issue13639>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to