[Python-checkins] python/nondist/peps pep-0301.txt,1.2,1.3
goodger@projects.sourceforge.net
goodger@projects.sourceforge.net
Sun, 17 Nov 2002 18:02:45 -0800
Update of /cvsroot/python/python/nondist/peps
In directory sc8-pr-cvs1:/tmp/cvs-serv6402/python/nondist/peps
Modified Files:
pep-0301.txt
Log Message:
Changes from Richard Jones:
- changes to the success/failure indicators used by the register.py
command. Originally I had copied the idea of using X-PyPI-* headers
from PEP 243. Upon advice from Greg Stein, I have switched to using
HTTP response codes.
- clarifications to Roles
- added PKG-INFO upload interface
Index: pep-0301.txt
===================================================================
RCS file: /cvsroot/python/python/nondist/peps/pep-0301.txt,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -d -r1.2 -r1.3
*** pep-0301.txt 8 Nov 2002 22:22:55 -0000 1.2
--- pep-0301.txt 18 Nov 2002 02:02:43 -0000 1.3
***************
*** 100,104 ****
**submit**
! Accepts a POST form submission of metadata about a package. The
"name" and "version" fields are mandatory, as they uniquely identify
an entry in the index. **Submit** will automatically determine
--- 100,104 ----
**submit**
! Accepts a POST submission of metadata about a package. The
"name" and "version" fields are mandatory, as they uniquely identify
an entry in the index. **Submit** will automatically determine
***************
*** 112,115 ****
--- 112,119 ----
and updating for those who do not use Distutils.
+ **submit_pkg_info**
+ Accepts a POST submission of a PKG-INFO file and performs the same
+ function as the **submit** interface.
+
**user**
Registers a new user with the index. Requires username, password and
***************
*** 129,148 ****
3. User visits URL with the key and confirms registration.
! Several user Roles will exist:
!
! Admin
! Can assign Owner Role - they decide who may submit for a given
! package name.
Owner
Owns a package name, may assign Maintainer Role for that name. The
! first user to register information about a package is deemed owner
of the package name. The Admin user may change this if necessary.
Maintainer
! Can submit and update info for a particular package name
! Manual (through-the-web) user registration is also available through
! an HTML form.
**roles**
--- 133,150 ----
3. User visits URL with the key and confirms registration.
! Several user Roles will exist, generally revolving around a
! particular package name:
Owner
Owns a package name, may assign Maintainer Role for that name. The
! first user to register information about a package is deemed Owner
of the package name. The Admin user may change this if necessary.
+ May submit updates for the package name.
Maintainer
! Can submit and update info for a particular package name.
! Admin
! Can assign Owner Role and edit user details.
**roles**
***************
*** 156,159 ****
--- 158,174 ----
preferably over an HTTPS connection.
+ The server interface will indicate success or failure of the commands
+ through a subset of the standard HTTP response codes:
+
+ ===== ============== ================================================
+ Code Meaning Register command implications
+ ===== ============== ================================================
+ 200 OK Everything worked just fine
+ 400 Bad request Data provided for submission was malformed
+ 401 Unauthorised The username or password supplied were incorrect
+ 403 Forbidden User does not have permission to update the
+ package information (not Owner or Maintainer)
+ ===== ============== ================================================
+
Distutils *register* Command
***************
*** 184,197 ****
discriminators.
- The index server will return custom headers (inspired by PEP 243)
- which the *register* command will use to give feedback to the user:
-
- **X-Pypi-Status**
- Either "success" or "fail".
-
- **X-Pypi-Reason**
- A description of the reason for failure, or additional information
- in the case of a success.
-
Distutils Trove Categorisation
--- 199,202 ----
***************
*** 281,284 ****
--- 286,305 ----
+ Rejected Proposals
+ ==================
+
+ Originally, the index server was to return custom headers (inspired by
+ PEP 243):
+
+ **X-Pypi-Status**
+ Either "success" or "fail".
+
+ **X-Pypi-Reason**
+ A description of the reason for failure, or additional information
+ in the case of a success.
+
+ However, it has been pointed out [8]_ that this is a bad scheme to use.
+
+
References
==========
***************
*** 305,308 ****
--- 326,332 ----
(http://www.python.org/peps/pep-0262.html)
+ .. [8] [PEP243] upload status is bogus
+ (http://mail.python.org/pipermail/distutils-sig/2001-March/002262.html)
+
Copyright
***************
*** 320,323 ****
--- 344,350 ----
A.M. Kuchling for support including hosting the second prototype.
+ Greg Stein for recommending that the register command interpret the
+ HTTP response codes rather than custom X-PyPI-* headers.
+
The many participants of the Distutils and Catalog SIGs for their
ideas over the years.
***************
*** 331,332 ****
--- 358,360 ----
fill-column: 70
End:
+