Martin Panter added the comment: Using fileobj=sys.stdin.buffer instead should do the trick. The “tarfile” module would expect a binary stream, not a text stream.
Given the documentation currently says, “Use this variant in combination with e.g. sys.stdin, . . .”, I presume that is why you were using plain stdin. The documentation should be clarified. ---------- assignee: -> docs@python components: +Documentation nosy: +docs@python, vadmium _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue23453> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com