[Distutils] Moving distribute_setup.py

PJ Eby pje at telecommunity.com
Thu Feb 14 23:34:42 CET 2013


On Thu, Feb 14, 2013 at 2:24 PM, Tarek Ziadé <tarek at ziade.org> wrote:
> On 2/14/13 8:21 PM, PJ Eby wrote:
>>
>> On Thu, Feb 14, 2013 at 1:52 PM, Tarek Ziadé <tarek at ziade.org> wrote:
>>>
>>> On 2/14/13 6:32 PM, Jim Fulton wrote:
>>>>
>>>> On Thu, Feb 14, 2013 at 11:41 AM, Tarek Ziadé <tarek at ziade.org> wrote:
>>>>>
>>>>> Hey
>>>>>
>>>>> As Marc-André suggested, it would be a good thing to move the
>>>>> bootstrapping
>>>>> file to
>>>>>
>>>>> :https://pypi.python.org/packages/source/d/distribute/distribute_setup.py
>>>>
>>>> +1
>>>>
>>>> I need to do something similar for buildout bootstrap files.
>>>> How are you accomplishing this?
>>>
>>>
>>> By POSTing a multipart/form-data, like what the upload command does for
>>> sdists :
>>>
>>> http://hg.python.org/cpython/file/0f827775f7b7/Lib/distutils/command/upload.py#l68
>>>
>>> I can write a small script that does it  (bascially rip off
>>> upload.upload_file() and remove the part about the metadata)
>>>
>>> We could also write a custom sdist that does this, with an
>>> extra_dist_files,
>>> but oh well.. :)
>>
>> Hm.  I just tried to do this with ez_setup.py for setuptools, and
>> PyPI's complaining that a .py file isn't a valid distribution.  (I'm
>> using the web interface, not the upload command, but same basic idea.)
>>
>> AFAICT, we'll need the PyPI admins to implement support for .py
>> uploads for this to work.
>
> Oh you are right, I have not noticed that,
>
> we need to add *.py here:
> https://bitbucket.org/loewis/pypi/src/f18ce0fbe947c1ce778761ea81d6704572cebb24/webui.py?at=default#cl-48
>
> Will poke Catalog-sig

Actually, there's another potential problem I just thought of.
Normally, PyPI rejects repeated uploads of the same filename, so
updating these could be a problem, unless there's an option to replace
an existing file.  (Because versioned bootstrap scripts would mean we
can't give out a canonical URL to download the "current version" of a
project.)


More information about the Distutils-SIG mailing list