[Distutils] Upcoming changes to PEP 426/440

Vinay Sajip vinay_sajip at yahoo.co.uk
Thu Jul 4 14:31:45 CEST 2013


Donald Stufft <donald <at> stufft.io> writes:

> I would prefer a single entry. It makes the serialization format map to the
> modeling simpler, and I think it's simpler for humans too. I don't see much
> benefit to making it a list except arbitrarily adding another level of
> nesting.

It's a question of

{
  "install": ["a", "b", "c"]
}

versus

{
  "install": "a"
},
{
  "install": "b"
},
{
  "install": "c"
}

and I can't see why you think the latter is in any way better. IMO
implementation details (such as "it's easier for the Django ORM to map it")
should not take precedence over other considerations of
readability/simplicity. In any case, I can't see why there would be any
particular modelling problem with the scheme I've suggested.

Is the modelling work you're doing public? I had a quick look at your
warehouse repo (github.com/dstufft/warehouse) and I don't see any models
beyond User and Email. Is that the correct location? I'd be happy to take a
closer look to get a better understanding of what modelling problem you're
seeing/foreseeing.

FYI the metadata that I'm maintaining on red-dove.com is stored in a SQL
database. While my SQL schema is not yet fully aligned with the PEP (as it's
WIP), I don't see any modelling problem between an RDBMS backend and any of
the JSON formats which have been published in the various revisions of the
PEP. Some more detail would help :-)

Regards,

Vinay Sajip



More information about the Distutils-SIG mailing list