http://hg.python.org/peps/rev/4ad34ebe2a06 changeset: 5368:4ad34ebe2a06 user: Nick Coghlan <ncoghlan@gmail.com> date: Thu Jan 30 22:18:50 2014 +1000 summary: Wording tweaks files: pep-0427.txt | 29 +++++++++++++++-------------- 1 files changed, 15 insertions(+), 14 deletions(-) diff --git a/pep-0427.txt b/pep-0427.txt --- a/pep-0427.txt +++ b/pep-0427.txt @@ -400,17 +400,18 @@ Is it possible to import Python code directly from a wheel file? ---------------------------------------------------------------- - Technically, a subset of wheel files *do* support being placed directly - on ``sys.path`` (due to the combination of supporting installation - via simple extraction and using an archive format that is compatible - with ``zipimport``), but actually doing so is generally discouraged. + Technically, due to the combination of supporting installation via + simple extraction and using an archive format that is compatible with + ``zipimport``, a subset of wheel files *do* support being placed directly + on ``sys.path``. However, while this behaviour is a natural consequence + of the format design, actually relying on it is generally discouraged. - Firstly, wheel *is* designed primarily as an installation format, so - skipping the installation step means deliberately avoiding any reliance - on features that assume full installation (such as being able to use - standard tools like ``pip`` and ``virtualenv`` to capture and manage - dependencies in a way that can be properly tracked for auditing and - security update purposes, or integrating fully with the standard + Firstly, wheel *is* designed primarily as a distribution format, so + skipping the installation step also means deliberately avoiding any + reliance on features that assume full installation (such as being able + to use standard tools like ``pip`` and ``virtualenv`` to capture and + manage dependencies in a way that can be properly tracked for auditing + and security update purposes, or integrating fully with the standard build machinery for C extensions by publishing header files in the appropriate place). @@ -426,10 +427,10 @@ a zip archive the ``__file__`` attribute no longer refers to an ordinary filesystem path, but to a combination path that includes both the location of the zip archive on the filesystem and the - relative path to the module inside the archive). Even when software - uses the abstract resource APIs correctly internally, interfacing with - external components may still require the available of an actual on-disk - file. + relative path to the module inside the archive. Even when software + correctly uses the abstract resource APIs internally, interfacing with + external components may still require the availability of an actual + on-disk file. Like metaclasses, monkeypatching and metapath importers, if you're not already sure you need to take advantage of this feature, you almost -- Repository URL: http://hg.python.org/peps
participants (1)
-
nick.coghlan