File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -44,13 +44,15 @@ package that provides it.
4444What are the links between distribution packages and import packages?
4545=====================================================================
4646
47- By convention , a distribution package usually provides one single import
47+ Most of the time , a distribution package provides one single import
4848package (or non-package module), with a matching name. For example,
4949``pip install numpy `` lets you ``import numpy ``.
5050
51- However, this is only a convention. PyPI and other package indices do
52- not enforce any relationship between the name of a distribution package
53- and the import packages it provides.
51+ However, this is only a convention. PyPI and other package indices *do not
52+ enforce any relationship * between the name of a distribution package and the
53+ import packages it provides. (A consequence of this is that you cannot blindly
54+ install the PyPI package ``foo `` if you see ``import foo ``; this may install an
55+ unintended, and potentially even malicious package.)
5456
5557A distribution package could provide an import package with a different
5658name. An example of this is the popular Pillow _ library for image
You can’t perform that action at this time.
0 commit comments