Skip to content

[3.8] bpo-37408: Precise that Tarfile "format" argument only concerns writing. (GH-14389) #16465

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Sep 30, 2019
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions Doc/library/tarfile.rst
Original file line number Diff line number Diff line change
Expand Up @@ -290,9 +290,10 @@ be finalized; only the internally used file object will be closed. See the

*fileobj* is not closed, when :class:`TarFile` is closed.

*format* controls the archive format. It must be one of the constants
*format* controls the archive format for writing. It must be one of the constants
:const:`USTAR_FORMAT`, :const:`GNU_FORMAT` or :const:`PAX_FORMAT` that are
defined at module level.
defined at module level. When reading, format will be automatically detected, even
if different formats are present in a single archive.

The *tarinfo* argument can be used to replace the default :class:`TarInfo` class
with a different one.
Expand Down