From 4bb10aa8b7b41e56965960e6a1f4f5aa8f2c08e7 Mon Sep 17 00:00:00 2001 From: slateny <46876382+slateny@users.noreply.github.com> Date: Thu, 28 Apr 2022 01:50:29 -0700 Subject: [PATCH] Fix parameter name for pipes --- Doc/library/pipes.rst | 2 +- Lib/pipes.py | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/Doc/library/pipes.rst b/Doc/library/pipes.rst index 4de8c51bcae049..a57f40891180ae 100644 --- a/Doc/library/pipes.rst +++ b/Doc/library/pipes.rst @@ -89,7 +89,7 @@ Template objects following methods: arguments. -.. method:: Template.open(file, mode) +.. method:: Template.open(file, rw) Return a file-like object, open to *file*, but read from or written to by the pipeline. Note that only one of ``'r'``, ``'w'`` may be given. diff --git a/Lib/pipes.py b/Lib/pipes.py index 61d63b48d3e4c5..e4065bb803b81c 100644 --- a/Lib/pipes.py +++ b/Lib/pipes.py @@ -48,8 +48,8 @@ exit status of the conversion pipeline. To open a file for reading or writing through a conversion pipeline: - fp = t.open(file, mode) -where mode is 'r' to read the file, or 'w' to write it -- just like + fp = t.open(file, rw) +where rw is 'r' to read the file, or 'w' to write it -- just like for the built-in function open() or for os.popen(). To create a new template object initialized to a given one: