From c729d6e35af5ed3135cdc7f338f3359450dc4ed5 Mon Sep 17 00:00:00 2001 From: Josh Cannon Date: Thu, 22 May 2025 16:32:00 -0500 Subject: [PATCH] Avoid `__file__` in `hashlib` example (GH-134540) (cherry picked from commit 9b292ff0223dab0f999d5c1e13355552fd7cd528) Co-authored-by: Josh Cannon --- Doc/library/hashlib.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Doc/library/hashlib.rst b/Doc/library/hashlib.rst index bb2d2fad23bdb8..4818a4944a512a 100644 --- a/Doc/library/hashlib.rst +++ b/Doc/library/hashlib.rst @@ -284,7 +284,7 @@ a file or file-like object. Example: >>> import io, hashlib, hmac - >>> with open(hashlib.__file__, "rb") as f: + >>> with open("library/hashlib.rst", "rb") as f: ... digest = hashlib.file_digest(f, "sha256") ... >>> digest.hexdigest() # doctest: +ELLIPSIS