File tree Expand file tree Collapse file tree 1 file changed +7
-8
lines changed
Expand file tree Collapse file tree 1 file changed +7
-8
lines changed Original file line number Diff line number Diff line change @@ -78,19 +78,18 @@ directory rather than a file. No item is added to ``sys.path`` more than
7878once. Blank lines and lines beginning with ``# `` are skipped. Lines starting
7979with ``import `` (followed by space or tab) are executed.
8080
81+ .. note ::
82+ On Windows, a file whose name has the form :file: `._pth ` is handled
83+ differently; it is used by the Windows-only "embeddable distribution"
84+ to provide a self-contained Python environment. See
85+ :ref: `finding_modules ` for more details.
86+
8187.. note ::
8288
8389 An executable line in a :file: `.pth ` file is run at every Python startup,
8490 regardless of whether a particular module is actually going to be used.
8591 Its impact should thus be kept to a minimum.
86- The primary intended purpose of executable lines is to make the
87- corresponding module(s) importable
88- (load 3rd-party import hooks, adjust :envvar: `PATH ` etc).
89- Any other initialization is supposed to be done upon a module's
90- actual import, if and when it happens.
91- Limiting a code chunk to a single line is a deliberate measure
92- to discourage putting anything more complex here.
93-
92+
9493.. versionchanged :: 3.13
9594 The :file: `.pth ` files are now decoded by UTF-8 at first and then by the
9695 :term: `locale encoding ` if it fails.
You can’t perform that action at this time.
0 commit comments