Skip to content

Commit 14580ab

Browse files
jwodderncoghlan
authored andcommitted
Expand the section on the "name" argument (pypa#329)
Als updates reference to be to PEP 508 instead of 426
1 parent d2a8ccf commit 14580ab

File tree

1 file changed

+17
-4
lines changed

1 file changed

+17
-4
lines changed

source/tutorials/distributing-packages.rst

Lines changed: 17 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -142,10 +142,23 @@ name
142142

143143
name='sample',
144144

145-
This is the name of your project, and will determine how your project is listed
146-
on :term:`PyPI <Python Package Index (PyPI)>`. For details on permitted
147-
characters, see the :pep:`name <426#name>`
148-
section from :pep:`426`.
145+
This is the name of your project, determining how your project is listed on
146+
:term:`PyPI <Python Package Index (PyPI)>`. Per :pep:`508`, valid project
147+
names must:
148+
149+
- Consist only of ASCII letters, digits, underscores (``_``), hyphens (``-``),
150+
and/or periods (``.``), and
151+
- Start & end with an ASCII letter or digit
152+
153+
Comparison of project names is case insensitive and treats arbitrarily-long
154+
runs of underscores, hyphens, and/or periods as equal. For example, if you
155+
register a project named ``cool-stuff``, users will be able to download it or
156+
declare a dependency on it using any of the following spellings::
157+
158+
Cool-Stuff
159+
cool.stuff
160+
COOL_STUFF
161+
CoOl__-.-__sTuFF
149162

150163

151164
version

0 commit comments

Comments
 (0)