[Distutils] pip and virtualenv release candidates

2013-07-02 Thread Marcus Smith
pip-1.4rc2 and virtualenv-1.10rc3 are available for testing from github.

A few highlights:
 - pip added support for installing and building wheel archives.
   (
http://www.pip-installer.org/en/latest/cookbook.html#building-and-installing-wheels
)
 - virtualenv is now using the new merged setuptools, and no longer
supports distribute.
 - pip now only installs stable versions by default, and offers a new --pre
option to also find pre-releases.
 - Dropped support for Python 2.5.

Changelogs:
 pip: http://www.pip-installer.org/en/release-1.4/news.html
 virtualenv: http://www.virtualenv.org/en/release-1.10/news.html

Download Links:
 pip:
  gz: https://github.com/pypa/pip/archive/1.4rc2.tar.gz
md5=0426430fc8a261c83bcd083fb03fb7d6
  zip: https://github.com/pypa/pip/archive/1.4rc2.zip
md5=c86dc0d94ed787eadba6dceb06f1676f
 virtualenv:
  gz: https://github.com/pypa/virtualenv/archive/1.10rc3.tar.gz
md5=b24cdf59b561acf26ae3f639098d5a34
  zip: https://github.com/pypa/virtualenv/archive/1.10rc3.zip
md5=a6ee1a1570a751aa50f95833d9898649

Installation:
 The easiest way to try them both and *not* affect your current system, is
like so:
 e.g. on Linux:
  $ curl -L -O https://github.com/pypa/virtualenv/archive/1.10rc3.tar.gz
  $ echo "b24cdf59b561acf26ae3f639098d5a34  1.10rc3.tar.gz" | md5sum -c
  1.10rc3.tar.gz: OK
  $ tar zxf 1.10rc3.tar.gz
  $ python virtualenv-1.10rc3/virtualenv.py myVE
  $ myVE/bin/pip --version
   pip 1.4rc2

   *Note*: If instead, you choose to upgrade an existing pip (and
setuptools), know this:
1) pip's wheel support requires setuptools>=0.8b2 (this will become
final before pip is released final)
2) setuptools-0.8bx is not on pypi and can be found here:
https://bitbucket.org/pypa/setuptools/downloads
3) Older pip's can not currently upgrade distribute to setuptools
(until distribute-0.7.3 is released on ~July-7th)
 (for more upgrade details:
http://www.pip-installer.org/en/latest/installing.html#requirements)

Offering Feedback:
 You can respond to this email, or log issues in our tracker:
   https://github.com/pypa/pip/issues?state=open
___
Distutils-SIG maillist  -  Distutils-SIG@python.org
http://mail.python.org/mailman/listinfo/distutils-sig


Re: [Distutils] "Python Packaging User Guide"

2013-07-02 Thread Daniel Holth
On Tue, Jul 2, 2013 at 7:18 PM, Alex Burke  wrote:
> Hi Marcus,
>
> I would very much like to get involved and help with this effort - in fact I 
> was looking to package up some of my own work recently and stumbled on The 
> Hitchhiker’s Guide to Packaging but could tell some of the advice was out of 
> date having followed the discussions for a while now.
>
> What I was thinking is it could be useful my documenting exactly what I'm 
> having to do, things to remember etc and it'd help me learn things much more 
> deeply on the way too. My only concern however would be where to go to find 
> the right 'new world' answers. Aside from reading the PEPs etc, are there any 
> other points of contact? Is it ok to ask such questions on this list?

Sounds like a great idea, assemble your FAQ, and we will remember
what's confusing about packaging when you haven't been embroiled in it
for years.
___
Distutils-SIG maillist  -  Distutils-SIG@python.org
http://mail.python.org/mailman/listinfo/distutils-sig


Re: [Distutils] "Python Packaging User Guide"

2013-07-02 Thread Alex Burke
Hi Marcus,

I would very much like to get involved and help with this effort - in fact I 
was looking to package up some of my own work recently and stumbled on The 
Hitchhiker’s Guide to Packaging but could tell some of the advice was out of 
date having followed the discussions for a while now.

What I was thinking is it could be useful my documenting exactly what I'm 
having to do, things to remember etc and it'd help me learn things much more 
deeply on the way too. My only concern however would be where to go to find the 
right 'new world' answers. Aside from reading the PEPs etc, are there any other 
points of contact? Is it ok to ask such questions on this list?

Thanks, Alex J Burke.
___
Distutils-SIG maillist  -  Distutils-SIG@python.org
http://mail.python.org/mailman/listinfo/distutils-sig


Re: [Distutils] Finding modules in an egg / distribution

2013-07-02 Thread PJ Eby
On Tue, Jul 2, 2013 at 1:30 PM, Iwan Vosloo  wrote:
> On 02/07/2013 17:08, PJ Eby wrote:
>>
>> If you are targeting at least Python 2.5, see:
>> http://docs.python.org/2/library/pkgutil.html#pkgutil.walk_packages
>
>
> We're targeting Python 2.7.
>
> Trouble is that pkgutil.walk_packages needs a path to search from.
> Distribution.location is always your site-packages directory once a
> Distribution is installed, so walking that just gives ALL installed
> packages. If your Distribution contains some sort of main package that
> contains everything in it, you can use that package's .__path__, but then
> you'd need to discover what that package is.
>
> Distributions could also contain more than one package next to each other,
> and top-level modules. (The __path__ of a top-level module is also simply
> the site-packages directory.)
>
> There is a metadata file top_level.txt which one could use to get the names
> of top-level packages/modules in the Distribution. This can however contain
> a namespace package too - and you don't want all the packages inside the
> namespace package - just the bits inside the chosen Distribution...

Ah, well in that case you'll have to inspect either
.egg-info/SOURCES.txt or the PEP 376 installation manifest.  I don't
know of any reliable way to do what you want for system-installed
packages at the moment.
___
Distutils-SIG maillist  -  Distutils-SIG@python.org
http://mail.python.org/mailman/listinfo/distutils-sig


Re: [Distutils] PyPI mirrors

2013-07-02 Thread Donald Stufft
Of course as I look it appears all if the official mirrors are out if date 
again. 

On Jul 2, 2013, at 1:14 PM, Noah Kantrowitz  wrote:

> 
> On Jul 2, 2013, at 2:33 AM, David King wrote:
> 
>> Hi all,
>> 
>> Has the relationship between PyPI mirrors changed since PyPI has started
>> being served behind a CDN? 
>> 
>> I know people have been recommending against using "--use-mirrors" with
>> pip since it doesn't take advantage of the CDN. I've been considering
>> trying to get a public PyPI mirror setup and wanted to know how/if
>> they're still being used.
> 
> Yes, the use of public mirrors is no longer recommended as a best practice. 
> The idea is that mirrors will continue to be an important part of the 
> ecosystem for things like deploy caching, internal company mirrors, etc, but 
> the federated, public mirror network concept is being retired. Several of the 
> public mirrors have already shut down and just point back at PyPI, but others 
> are still available if you want to use them.
> 
> --Noah
> 
> ___
> Distutils-SIG maillist  -  Distutils-SIG@python.org
> http://mail.python.org/mailman/listinfo/distutils-sig
___
Distutils-SIG maillist  -  Distutils-SIG@python.org
http://mail.python.org/mailman/listinfo/distutils-sig


Re: [Distutils] Finding modules in an egg / distribution

2013-07-02 Thread Éric Araujo
Hello Iwan,

This project can answer your questions: https://pypi.python.org/pypi/pkginfo

FTR we planned to include something like it when the distutils2 project
was active; distlib or the variant of distlib that will end up in the
3.4 standard library could include similar features.

Regards
___
Distutils-SIG maillist  -  Distutils-SIG@python.org
http://mail.python.org/mailman/listinfo/distutils-sig


Re: [Distutils] Finding modules in an egg / distribution

2013-07-02 Thread Iwan Vosloo

On 02/07/2013 17:08, PJ Eby wrote:
If you are targeting at least Python 2.5, see: 
http://docs.python.org/2/library/pkgutil.html#pkgutil.walk_packages 


We're targeting Python 2.7.

Trouble is that pkgutil.walk_packages needs a path to search from. 
Distribution.location is always your site-packages directory once a 
Distribution is installed, so walking that just gives ALL installed 
packages. If your Distribution contains some sort of main package that 
contains everything in it, you can use that package's .__path__, but 
then you'd need to discover what that package is.


Distributions could also contain more than one package next to each 
other, and top-level modules. (The __path__ of a top-level module is 
also simply the site-packages directory.)


There is a metadata file top_level.txt which one could use to get the 
names of top-level packages/modules in the Distribution. This can 
however contain a namespace package too - and you don't want all the 
packages inside the namespace package - just the bits inside the chosen 
Distribution...


Regards
- Iwan
___
Distutils-SIG maillist  -  Distutils-SIG@python.org
http://mail.python.org/mailman/listinfo/distutils-sig


[Distutils] "Python Packaging User Guide"

2013-07-02 Thread Marcus Smith
Everyone:

Soon after pycon, the "The Hitchhiker’s Guide to Packaging" (HHGTP) was
forked into the "Python Packaging User Guide".

src: https://bitbucket.org/pypa/python-packaging-user-guide
built: https://python-packaging-user-guide.readthedocs.org/en/latest/

Here's the original discussion on distutils-sig:
http://mail.python.org/pipermail/distutils-sig/2013-March/020215.html

It's a PyPA project, and the goal is for it to become the de facto place
for tutorials and where to find the current state of PEPs and development
efforts.

The idea is that once it's worthy, the python core docs would re-link from
the HHGTP to the new guide, but it **needs work.**

The TOC is sound and some of the sections are OK, but the two main
tutorials are sorely lacking.

I intend to keep working on it when I can, but help is appreciated.

The project is open for issue logging and pull requests.

Thanks,
Marcus
___
Distutils-SIG maillist  -  Distutils-SIG@python.org
http://mail.python.org/mailman/listinfo/distutils-sig


Re: [Distutils] PyPI mirrors

2013-07-02 Thread Noah Kantrowitz

On Jul 2, 2013, at 2:33 AM, David King wrote:

> Hi all,
> 
> Has the relationship between PyPI mirrors changed since PyPI has started
> being served behind a CDN? 
> 
> I know people have been recommending against using "--use-mirrors" with
> pip since it doesn't take advantage of the CDN. I've been considering
> trying to get a public PyPI mirror setup and wanted to know how/if
> they're still being used. 

Yes, the use of public mirrors is no longer recommended as a best practice. The 
idea is that mirrors will continue to be an important part of the ecosystem for 
things like deploy caching, internal company mirrors, etc, but the federated, 
public mirror network concept is being retired. Several of the public mirrors 
have already shut down and just point back at PyPI, but others are still 
available if you want to use them.

--Noah



signature.asc
Description: Message signed with OpenPGP using GPGMail
___
Distutils-SIG maillist  -  Distutils-SIG@python.org
http://mail.python.org/mailman/listinfo/distutils-sig


Re: [Distutils] Finding modules in an egg / distribution

2013-07-02 Thread PJ Eby
On Tue, Jul 2, 2013 at 6:59 AM, Iwan Vosloo  wrote:
> Hi there,
>
> We have been struggling to find a nice way to list all the modules (or
> packages) that are part of a particular Distribution (or egg). Nice should
> also mean that it works when the egg is installed. We have a need to do some
> introspection on the code shipped as an egg.
>
> Any ideas?

If you are targeting at least Python 2.5, see:

http://docs.python.org/2/library/pkgutil.html#pkgutil.walk_packages
___
Distutils-SIG maillist  -  Distutils-SIG@python.org
http://mail.python.org/mailman/listinfo/distutils-sig


[Distutils] PyPI upload failed (302): Moved Temporarily

2013-07-02 Thread W. Trevor King
Hello list!

I'm having a bit of trouble getting a new package setup on PyPI.  I've
done this a few times in the past, but maybe not since the wiki
hacking that inspired the HTTPS transition back in February.  I did
change my password back then, so I don't think that's the problem.
Anyhow, with the old URL (still mentioned in the distutils docs [1]):

  http://www.python.org/pypi

in my ~/.pypirc, I get:

  $ python setup.py register -r pypi
  running register
  running check
  Registering pycalendar to http://www.python.org/pypi
  Server response (403): You are not allowed to store 'pycalendar' package 
information

With https://pypi.python.org/ in my ~/.pypirc, I get:

  $ python setup.py register -r pypi
  running register
  running check
  Registering pycalendar to https://pypi.python.org/
  Server response (200): OK

Ok, how about uploading a tarball?  With the https:// URL:

  $ python setup.py sdist upload -r pypi
…
running upload
  Submitting dist/pycalendar-0.1.tar.gz to https://pypi.python.org/
  Upload failed (302): Moved Temporarily

With the http:// URL:

  $ python setup.py sdist upload -r pypi
…
  running upload
  Submitting dist/pycalendar-0.1.tar.gz to http://www.python.org/pypi
  Upload failed (403): You are not allowed to edit 'pycalendar' package 
information

What am I doing wrong?

Thanks,
Trevor

[1]: http://docs.python.org/3/distutils/packageindex.html#the-pypirc-file

-- 
This email may be signed or encrypted with GnuPG (http://www.gnupg.org).
For more information, see http://en.wikipedia.org/wiki/Pretty_Good_Privacy


signature.asc
Description: OpenPGP digital signature
___
Distutils-SIG maillist  -  Distutils-SIG@python.org
http://mail.python.org/mailman/listinfo/distutils-sig


[Distutils] PyPI mirrors

2013-07-02 Thread David King
Hi all,

Has the relationship between PyPI mirrors changed since PyPI has started
being served behind a CDN? 

I know people have been recommending against using "--use-mirrors" with
pip since it doesn't take advantage of the CDN. I've been considering
trying to get a public PyPI mirror setup and wanted to know how/if
they're still being used. 

Thanks,
Dave,
___
Distutils-SIG maillist  -  Distutils-SIG@python.org
http://mail.python.org/mailman/listinfo/distutils-sig


Re: [Distutils] PyPI upload: zip okay, tar fails with "invalid distribution file"

2013-07-02 Thread Maurits van Rees

Op 01-07-13 21:12, Ethan Furman schreef:

On 07/01/2013 12:11 PM, Paul Moore wrote:

You probably want format gztar rather than tar. I don't think I've
ever seen an uncompressed tar on PyPI - they probably
aren't allowed...


I could've sworn I've used tar before, but at any rate going with gztar
did the trick.


I always use --formats=zip, because in some corner cases Python2.4 has 
problems with the gztar format, not while creating a distribution file 
but when installing it.


--
Maurits van Rees: http://maurits.vanrees.org/
Zest Software: http://zestsoftware.nl

___
Distutils-SIG maillist  -  Distutils-SIG@python.org
http://mail.python.org/mailman/listinfo/distutils-sig


[Distutils] Finding modules in an egg / distribution

2013-07-02 Thread Iwan Vosloo

Hi there,

We have been struggling to find a nice way to list all the modules (or 
packages) that are part of a particular Distribution (or egg). Nice 
should also mean that it works when the egg is installed. We have a need 
to do some introspection on the code shipped as an egg.


Any ideas?

Regards
- Iwan
___
Distutils-SIG maillist  -  Distutils-SIG@python.org
http://mail.python.org/mailman/listinfo/distutils-sig