Skip to content

Commit 65c5fb6

Browse files
committed
Update docs/writing/style.rst
rpartition() takes a seperator as argument
1 parent d3218d4 commit 65c5fb6

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

docs/writing/style.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -286,7 +286,7 @@ will not need that variable, use ``__``:
286286
.. code-block:: python
287287
288288
filename = 'foobar.txt'
289-
basename, __, ext = filename.rpartition()
289+
basename, __, ext = filename.rpartition('.')
290290
291291
.. note::
292292

0 commit comments

Comments
 (0)