List Info

Thread: permissive trove classification




permissive trove classification
country flaguser name
United States
2007-12-26 11:43:53
Hello,


I am implementing a PyPI-like server, to allow people using
it as a
cheeseshop alternative. It may have its own trove
classification though,
that differs from PyPI. This is intended because the server
provide a
"package center" that has its own domain-specific
categories.

To make `file_upload` work on both Pypi and my
implementation, it has to be
permissive on the classifiers passed in the metadata.

In other words, if the classifier is not found in the
server, it doesn't use
it. This would allow a distribution of eggs on several
servers and a
decentralized way to manage troves.

I've tried to upload a file with a classifier that doesn't
exists on Pypi
and it fails silently. The result was the lost of all
metadata on the
package.

I would like to suggest a "permissive trove
classification" on servers that
implement a package index.

I can work on a more formal document (some kind of PEP?) to
explain the
changes needed in the current
PyPI implementation and on a formal definition of a PyPI
(server side) api
(a bit like the DB API). I am also willing to spend the time
needed to code
it.

Regards

Tarek

-- 
View this message in context: http://www.nabble.com/permissive-t
rove-classification-tp14504481p14504481.html
Sent from the Python - catalog-sig mailing list archive at
Nabble.com.

_______________________________________________
Catalog-SIG mailing list
Catalog-SIGpython.org
h
ttp://mail.python.org/mailman/listinfo/catalog-sig

Re: permissive trove classification
country flaguser name
United States
2007-12-26 12:07:21
As a package owner/maintainer, I would much rather have a
warning or  
error message from the server when I upload something with
an unknown  
category. That way I can correct any typographical mistakes.
 If the  
server completely ignores the bad data, I don't have an easy
way to  
realize something is wrong.

Doug

On Dec 26, 2007, at 12:43 PM, Tarek Ziadé wrote:

>
> Hello,
>
>
> I am implementing a PyPI-like server, to allow people
using it as a
> cheeseshop alternative. It may have its own trove
classification  
> though,
> that differs from PyPI. This is intended because the
server provide a
> "package center" that has its own
domain-specific categories.
>
> To make `file_upload` work on both Pypi and my
implementation, it  
> has to be
> permissive on the classifiers passed in the metadata.
>
> In other words, if the classifier is not found in the
server, it  
> doesn't use
> it. This would allow a distribution of eggs on several
servers and a
> decentralized way to manage troves.
>
> I've tried to upload a file with a classifier that
doesn't exists  
> on Pypi
> and it fails silently. The result was the lost of all
metadata on the
> package.
>
> I would like to suggest a "permissive trove
classification" on  
> servers that
> implement a package index.
>
> I can work on a more formal document (some kind of
PEP?) to explain  
> the
> changes needed in the current
> PyPI implementation and on a formal definition of a
PyPI (server  
> side) api
> (a bit like the DB API). I am also willing to spend the
time needed  
> to code
> it.
>
> Regards
>
> Tarek
>
> -- 
> View this message in context: http://www.nabble.c
om/permissive- 
> trove-classification-tp14504481p14504481.html
> Sent from the Python - catalog-sig mailing list archive
at Nabble.com.
>
> _______________________________________________
> Catalog-SIG mailing list
> Catalog-SIGpython.org
> h
ttp://mail.python.org/mailman/listinfo/catalog-sig

_______________________________________________
Catalog-SIG mailing list
Catalog-SIGpython.org
h
ttp://mail.python.org/mailman/listinfo/catalog-sig

Re: permissive trove classification
country flaguser name
United States
2007-12-26 12:17:50

Doug Hellmann wrote:
> 
> As a package owner/maintainer, I would much rather have
a warning or  
> error message from the server when I upload something
with an unknown  
> category. That way I can correct any typographical
mistakes.  If the  
> server completely ignores the bad data, I don't have an
easy way to  
> realize something is wrong.
> 

A warning would be fine, as long as the server treats the
other items.
An error would block the process.

For example, if we have 2 pypi servers, one that deals with
1..n categories,
one with A..Z,
we could have a package with such classifiers:

classifiers = ['category 1', 'category A', 'category 2']

Each server could pick the categories it knows.

Tarek
-- 
View this message in context: http://www.nabble.com/permissive-t
rove-classification-tp14504481p14504721.html
Sent from the Python - catalog-sig mailing list archive at
Nabble.com.

_______________________________________________
Catalog-SIG mailing list
Catalog-SIGpython.org
h
ttp://mail.python.org/mailman/listinfo/catalog-sig

Re: permissive trove classification
country flaguser name
United States
2007-12-26 13:13:52
Offering a warning and accepting the known categories seems
like a  
reasonable compromise.  Is it an error if there are no known
 
categories in the list?

Doug

On Dec 26, 2007, at 1:17 PM, Tarek Ziadé wrote:

>
>
> Doug Hellmann wrote:
>>
>> As a package owner/maintainer, I would much rather
have a warning or
>> error message from the server when I upload
something with an unknown
>> category. That way I can correct any typographical
mistakes.  If the
>> server completely ignores the bad data, I don't
have an easy way to
>> realize something is wrong.
>>
>
> A warning would be fine, as long as the server treats
the other items.
> An error would block the process.
>
> For example, if we have 2 pypi servers, one that deals
with 1..n  
> categories,
> one with A..Z,
> we could have a package with such classifiers:
>
> classifiers = ['category 1', 'category A', 'category
2']
>
> Each server could pick the categories it knows.
>
> Tarek
> -- 
> View this message in context: http://www.nabble.c
om/permissive- 
> trove-classification-tp14504481p14504721.html
> Sent from the Python - catalog-sig mailing list archive
at Nabble.com.
>
> _______________________________________________
> Catalog-SIG mailing list
> Catalog-SIGpython.org
> h
ttp://mail.python.org/mailman/listinfo/catalog-sig

_______________________________________________
Catalog-SIG mailing list
Catalog-SIGpython.org
h
ttp://mail.python.org/mailman/listinfo/catalog-sig

Re: permissive trove classification
country flaguser name
United States
2007-12-27 04:44:04

Doug Hellmann wrote:
> 
> Offering a warning and accepting the known categories
seems like a  
> reasonable compromise.  Is it an error if there are no
known  
> categories in the list?
> 

Well if all classifiers are unknown from any server, this
would just not do
anything on those
servers. Each server takes care of its trove and browse the
classifiers sent
by the package
to pick the one it knows. It means that if you made a
mistake on the
category name intended
for a given server, it will not raise an error and pop a
warning.

Let's take an example: I have a server that deals with Zope
packages. The
trove for PyPI is:

  Development Status :: 5 - Production/Stable
  Intended Audience :: Developers
  License :: OSI Approved :: Zope Public License
  Programming Language :: Python
  Topic :: Database
  Topic :: Software Development :: Libraries :: Python
Modules
  Operating System :: Microsoft :: Windows
  Operating System :: Unix

Now my company "ACME", classifies packages in two
categories: public,
private. It has a copy
of the PyPI trove too.
So my classifier become:

  ACME :: Visibility :: Public 
  Development Status :: 5 - Production/Stable
  Intended Audience :: Developers
  License :: OSI Approved :: Zope Public License
  Programming Language :: Python
  Topic :: Database
  Topic :: Software Development :: Libraries :: Python
Modules
  Operating System :: Microsoft :: Windows
  Operating System :: Unix

When I upload it to the cheeseshop, I would expect something
like this in
return:

Warning "ACME :: Visibility :: Public" classifier
not found on the server
200 - OK 

When I upload in ACME:

200 - OK 
-- 
View this message in context: http://www.nabble.com/permissive-t
rove-classification-tp14504481p14511741.html
Sent from the Python - catalog-sig mailing list archive at
Nabble.com.

_______________________________________________
Catalog-SIG mailing list
Catalog-SIGpython.org
h
ttp://mail.python.org/mailman/listinfo/catalog-sig

Re: permissive trove classification
country flaguser name
United States
2007-12-27 06:57:00
On Dec 27, 2007, at 5:44 AM, Tarek Ziadé wrote:

>
>
> Doug Hellmann wrote:
>>
>> Offering a warning and accepting the known
categories seems like a
>> reasonable compromise.  Is it an error if there are
no known
>> categories in the list?
>
> Now my company "ACME", classifies packages in
two categories: public,
> private. It has a copy
> of the PyPI trove too.
> So my classifier become:
>
>   ACME :: Visibility :: Public
>   Development Status :: 5 - Production/Stable
>   Intended Audience :: Developers
>   License :: OSI Approved :: Zope Public License
>   Programming Language :: Python
>   Topic :: Database
>   Topic :: Software Development :: Libraries :: Python
Modules
>   Operating System :: Microsoft :: Windows
>   Operating System :: Unix
>
> When I upload it to the cheeseshop, I would expect
something like  
> this in
> return:
>
> Warning "ACME :: Visibility :: Public"
classifier not found on the  
> server
> 200 - OK

That makes sense.

On the other hand, suppose that for some reason "ACME
::  
Visibility :: Public" was the only category listed for
your software  
(or that you had a long list of ACME-specific categories,
none of  
which are known to PyPI).  What response would you expect
when you  
uploaded it to PyPI?  I would want an error, since the
resulting  
package would not show up in any categories at all.

Doug

_______________________________________________
Catalog-SIG mailing list
Catalog-SIGpython.org
h
ttp://mail.python.org/mailman/listinfo/catalog-sig

Re: permissive trove classification
user name
2007-12-27 07:59:11
> I can work on a more formal document (some kind of
PEP?) to explain the
> changes needed in the current
> PyPI implementation and on a formal definition of a
PyPI (server side) api
> (a bit like the DB API). I am also willing to spend the
time needed to code
> it.

Please do. I would suggest you put any design documents
into
wiki.python.org/moin, with links from

http://wiki
.python.org/moin/CheeseShopDev

The actual patches to PyPI should to the SF tracker.

If you can, please choose wiki names that don't list
CheeseShop
anymore; use PyPI instead.

Regards,
Martin
_______________________________________________
Catalog-SIG mailing list
Catalog-SIGpython.org
h
ttp://mail.python.org/mailman/listinfo/catalog-sig

Re: permissive trove classification
user name
2007-12-27 12:22:39
On Dec 27, 2007 7:57 AM, Doug Hellmann <doughellfly.net> wrote:
> I would want an error, since the resulting
> package would not show up in any categories at all.

But the Trove classifiers are optional now, so I'm not at
all sure it
should be turned into an error.  Leaving it as a warning
seems
sufficient; someone who sees that the warning was caused by
a typo
after all can still go to the web form and edit the set of
classifiers
(or maybe re-register after correcting the metadata; I'm not
sure if
that'll work).

Or are you proposing that the classifiers become required? 
That's
going to cause a lot of packages to require work before new
versions
can be released, which doesn't seem good to me.


  -Fred

-- 
Fred L. Drake, Jr.    <fdrake at gmail.com>
"Chaos is the score upon which reality is
written." --Henry Miller
_______________________________________________
Catalog-SIG mailing list
Catalog-SIGpython.org
h
ttp://mail.python.org/mailman/listinfo/catalog-sig

Re: permissive trove classification
country flaguser name
United States
2007-12-27 12:28:05


&quot;Martin v. Löwis&quot; wrote:
> 
>> I can work on a more formal document (some kind of
PEP?) to explain the
>> changes needed in the current
>> PyPI implementation and on a formal definition of a
PyPI (server side)
>> api
>> (a bit like the DB API). I am also willing to spend
the time needed to
>> code
>> it.
> 
> Please do. I would suggest you put any design documents
into
> wiki.python.org/moin, with links from
> http://wiki
.python.org/moin/CheeseShopDev
> The actual patches to PyPI should to the SF tracker.
> If you can, please choose wiki names that don't list
CheeseShop
> anymore; use PyPI instead.
> 

Ok I will write a doc this week then present it here, in
order to propose a
patch

Regards
Tarek
-- 
View this message in context: http://www.nabble.com/permissive-t
rove-classification-tp14504481p14516698.html
Sent from the Python - catalog-sig mailing list archive at
Nabble.com.

_______________________________________________
Catalog-SIG mailing list
Catalog-SIGpython.org
h
ttp://mail.python.org/mailman/listinfo/catalog-sig
Re: permissive trove classification
country flaguser name
United States
2007-12-27 13:25:42
On Dec 27, 2007, at 1:22 PM, Fred Drake wrote:

> On Dec 27, 2007 7:57 AM, Doug Hellmann <doughellfly.net> wrote:
>> I would want an error, since the resulting
>> package would not show up in any categories at
all.
>
> But the Trove classifiers are optional now, so I'm not
at all sure it
> should be turned into an error.  Leaving it as a
warning seems
> sufficient; someone who sees that the warning was
caused by a typo
> after all can still go to the web form and edit the set
of classifiers
> (or maybe re-register after correcting the metadata;
I'm not sure if
> that'll work).
>
> Or are you proposing that the classifiers become
required?  That's
> going to cause a lot of packages to require work before
new versions
> can be released, which doesn't seem good to me.

Ah, I didn't realize they were optional.  It never occurred
to me to  
try to post a package without any categories listed.  

What I'm trying to do is make it easy to figure out when
I've botched  
something in my configuration.  If there are no categories
listed for  
a package I am uploading, or no *known* categories listed,
that seems  
like it warrants a special message, even if the server warns
me about  
each category I specify that it doesn't know.

But I won't push it.  As long as the server tells me about
categories  
it doesn't recognize, I should be able to figure out if I've
not  
given any valid categories at all, and that's good enough.

Doug

_______________________________________________
Catalog-SIG mailing list
Catalog-SIGpython.org
h
ttp://mail.python.org/mailman/listinfo/catalog-sig

[1-10] [11]

about | contact  Other archives ( Real Estate discussion Medical topics )