PEP 423 states that project names and package names should be the same and later gives an example where the project/package name contains a dot:
Yes:
Package name: "kheops.pyramid", i.e.import kheops.pyramid
Project name: "kheops.pyramid", i.e.pip install kheops.pyramid
What would the directory structure be for kheops.pyramid
and how would setup.py
be written (specifically the name
and packages
values) for that directory structure?
I've also seen that PEP 503 states that names should be normalized by replacing _
, -
, and .
with -
. Does this mean that kheops-pyramid
should be used rather than kheops.pyramid
? If so, wouldn't I need a package whose directory name is kheops-pyramid
and wouldn't the -
cause issues (eg. syntax error) when trying to import kheops-pyramid
?
EDIT:
I tried to make a project/package kheops.pyramid
to adhere to PEP 423 but I cannot figure out what directory structure and setup.py
combination will allow me to import kheops.pyramid
after pip install kheops.pyramid
without an error like ImportError: No module named kheops.pyramid
.
.
in the name and failing? – Bovineusername.package
to adhere to PEP 423 python.org/dev/peps/pep-0423/… but I cannot figure out what directory structure andsetup.py
combination will allow me toimport username.package
afterpip install username.package
without an error likeImportError: No module named username.package
. Will edit the question to make this more apparent. – Carliekheops
to exist first in order forkheops.pyramid
to be possible. – Forefendkheops
is in your comment: project, package, directory? – Carlie