Google Groups Home
Help | Sign in
setuptools strangeness: bdist_egg works only in svn checkout
There are currently too many topics in this group that display first. To make this topic appear first, remove this option from another topic.
There was an error processing your request. Please try again.
flag
  11 messages - Collapse all
The group you are posting to is a Usenet group. Messages posted to this group will make your email address visible to anyone on the Internet.
Your reply message has not been sent.
Your post was successful
Felix Schwarz  
View profile
 More options Mar 26, 6:20 am
From: Felix Schwarz <felix.schw...@web.de>
Date: Wed, 26 Mar 2008 11:20:50 +0100
Local: Wed, Mar 26 2008 6:20 am
Subject: setuptools strangeness: bdist_egg works only in svn checkout
Hi,

I just noticed a behavior of setuptools which seems very alien to me: If I
checkout the 1.0 branch and issue an "python setup.py bdist_egg", the
resulting egg file is good and contains all files.

If I put the source into another directory (e.g. by using "svn export"),
bdist_egg produces an incomplete egg file. The issue can be reproduced by
using the egg_info command, too which is faster than building the egg. You
will see that SOURCES.txt is only ~10kB afterwards (the good egg has a
SOURCES.txt which is ~20kB big).

Obviously, setuptools gets some information from the svn directories. But how
can I build a complete egg using just the source without svn metadata?

fs


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Florent Aide  
View profile
 More options Mar 26, 6:48 am
From: "Florent Aide" <florent.a...@gmail.com>
Date: Wed, 26 Mar 2008 11:48:43 +0100
Local: Wed, Mar 26 2008 6:48 am
Subject: Re: [TurboGears] setuptools strangeness: bdist_egg works only in svn checkout

On Wed, Mar 26, 2008 at 11:20 AM, Felix Schwarz <felix.schw...@web.de> wrote:

>  Hi,

>  I just noticed a behavior of setuptools which seems very alien to me: If I
>  checkout the 1.0 branch and issue an "python setup.py bdist_egg", the
>  resulting egg file is good and contains all files.

We need to be more explicit in the setup.py file and add data files in
the find_packages or data_files argument to setup()

Florent.


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Christopher Arndt  
View profile
 More options Mar 26, 6:57 am
From: Christopher Arndt <chris.ar...@web.de>
Date: Wed, 26 Mar 2008 11:57:01 +0100
Local: Wed, Mar 26 2008 6:57 am
Subject: Re: setuptools strangeness: bdist_egg works only in svn checkout
Florent Aide schrieb:

> On Wed, Mar 26, 2008 at 11:20 AM, Felix Schwarz <felix.schw...@web.de> wrote:
>>  Hi,

>>  I just noticed a behavior of setuptools which seems very alien to me: If I
>>  checkout the 1.0 branch and issue an "python setup.py bdist_egg", the
>>  resulting egg file is good and contains all files.

> We need to be more explicit in the setup.py file and add data files in
> the find_packages or data_files argument to setup()

What I usually do, is having a MANIFEST.in with something like this:

global-include *.cfg
recursive-include <mypackage>/static *
recursive-include <mypackage>/templates *.kid

graft doc
prune dist
prune build
global-exclude *.bak

This way, "python setup.py sdist" also works as expected. Maybe we
should include this in the quickstart templates?

Also, we should probably include finddata.py in the quickstart
templates, so you don't need TurboGears installed to run the setup.py of
your application.

Chris


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Jorge Godoy  
View profile
 More options Mar 26, 7:21 am
From: Jorge Godoy <jgo...@gmail.com>
Date: Wed, 26 Mar 2008 08:21:40 -0300
Local: Wed, Mar 26 2008 7:21 am
Subject: Re: [TurboGears] Re: setuptools strangeness: bdist_egg works only in svn checkout
Em Wednesday 26 March 2008 07:57:01 Christopher Arndt escreveu:

> What I usually do, is having a MANIFEST.in with something like this:

> global-include *.cfg
> recursive-include <mypackage>/static *
> recursive-include <mypackage>/templates *.kid

> graft doc
> prune dist
> prune build
> global-exclude *.bak

> This way, "python setup.py sdist" also works as expected. Maybe we
> should include this in the quickstart templates?

+1000 for that.

> Also, we should probably include finddata.py in the quickstart
> templates, so you don't need TurboGears installed to run the setup.py of
> your application.

Hmmm...  I think this is needed only for packagers.  You need TG to run, you
need TG to develop.  If you are someone that is packaging applications / TG
to be used by other people you don't need it installed.

Maybe this is interesting, but I don't see it being used all that much.  
Specially because people package TG, but not apps.

--
Jorge Godoy      <jgo...@gmail.com>


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Christopher Arndt  
View profile
 More options Mar 26, 7:31 am
From: Christopher Arndt <chris.ar...@web.de>
Date: Wed, 26 Mar 2008 12:31:40 +0100
Local: Wed, Mar 26 2008 7:31 am
Subject: Re: setuptools strangeness: bdist_egg works only in svn checkout
Jorge Godoy schrieb:

> Em Wednesday 26 March 2008 07:57:01 Christopher Arndt escreveu:
>> Also, we should probably include finddata.py in the quickstart
>> templates, so you don't need TurboGears installed to run the setup.py of
>> your application.

> Hmmm...  I think this is needed only for packagers.  You need TG to run, you
> need TG to develop.  If you are someone that is packaging applications / TG
> to be used by other people you don't need it installed.

> Maybe this is interesting, but I don't see it being used all that much.  
> Specially because people package TG, but not apps.

It could be interesting for people wanting to deploy TG apps by checking
out the source on the target host and then running "python setup.py
install" or something similar. This would allow to do this without
having TG installed on the target host. It would then be downloaded and
installed by the app's installation.

Granted, this is usually handled better by using eggs, but it would
provide another option.

Chris


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Christopher Arndt  
View profile
 More options Mar 26, 7:34 am
From: Christopher Arndt <chris.ar...@web.de>
Date: Wed, 26 Mar 2008 12:34:29 +0100
Local: Wed, Mar 26 2008 7:34 am
Subject: Re: setuptools strangeness: bdist_egg works only in svn checkout
Felix Schwarz schrieb:

> I just noticed a behavior of setuptools which seems very alien to me: If I
> checkout the 1.0 branch and issue an "python setup.py bdist_egg", the
> resulting egg file is good and contains all files.

> If I put the source into another directory (e.g. by using "svn export"),
> bdist_egg produces an incomplete egg file. The issue can be reproduced by
> using the egg_info command, too which is faster than building the egg. You
> will see that SOURCES.txt is only ~10kB afterwards (the good egg has a
> SOURCES.txt which is ~20kB big).

> Obviously, setuptools gets some information from the svn directories. But how
> can I build a complete egg using just the source without svn metadata?

Looking at the standard quickstart setup.py file and the
findata.find_package_data implementation, I currently don't see why this
should be happening. Do you use the "include_package_data" option in
your setup.py file? Can you paste it somewhere?

Chris


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Felix Schwarz  
View profile
 More options Mar 26, 8:13 am
From: Felix Schwarz <felix.schw...@web.de>
Date: Wed, 26 Mar 2008 05:13:57 -0700 (PDT)
Local: Wed, Mar 26 2008 8:13 am
Subject: Re: setuptools strangeness: bdist_egg works only in svn checkout

On 26 Mrz., 12:34, Christopher Arndt <chris.ar...@web.de> wrote:

> Looking at the standard quickstart setup.py file and the
> findata.find_package_data implementation, I currently don't see why this
> should be happening. Do you use the "include_package_data" option in
> your setup.py file? Can you paste it somewhere?

Sorry, I was not explicit enough: It's not about my own application
but TurboGears itself. Therefore the quickstarted setup.py does not
come into play here.

fs


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Christopher Arndt  
View profile
 More options Mar 26, 10:25 am
From: Christopher Arndt <chris.ar...@web.de>
Date: Wed, 26 Mar 2008 15:25:13 +0100
Local: Wed, Mar 26 2008 10:25 am
Subject: Re: setuptools strangeness: bdist_egg works only in svn checkout
Felix Schwarz schrieb:

> On 26 Mrz., 12:34, Christopher Arndt <chris.ar...@web.de> wrote:
>> Looking at the standard quickstart setup.py file and the
>> findata.find_package_data implementation, I currently don't see why this
>> should be happening. Do you use the "include_package_data" option in
>> your setup.py file? Can you paste it somewhere?

> Sorry, I was not explicit enough: It's not about my own application
> but TurboGears itself. Therefore the quickstarted setup.py does not
> come into play here.

Ah, sorry, it was me who didn't your mail properly. The setup.py of
TurboGears indeed uses "include_package_date=True", which causes this
behaviour:

     http://trac.turbogears.org/browser/branches/1.0/setup.py#L117

For an explanation, see the setuptools docs:

http://peak.telecommunity.com/DevCenter/setuptools#including-data-files

Can you file a ticket? Shoudl probably be for the "Deployment" or
"Installation" component.

Chris


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Felix Schwarz  
View profile
 More options Mar 26, 5:10 pm
From: Felix Schwarz <felix.schw...@web.de>
Date: Wed, 26 Mar 2008 14:10:00 -0700 (PDT)
Subject: Re: setuptools strangeness: bdist_egg works only in svn checkout

On Mar 26, 3:25 pm, Christopher Arndt <chris.ar...@web.de> wrote:

> Can you file a ticket? Shoudl probably be for the "Deployment" or
> "Installation" component.

http://trac.turbogears.org/ticket/1768

I filed this for 1.1 although I really would like to see this fixed
for 1.0 too :-)

fs


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Florent Aide  
View profile
 More options Mar 26, 6:03 pm
From: "Florent Aide" <florent.a...@gmail.com>
Date: Wed, 26 Mar 2008 23:03:48 +0100
Local: Wed, Mar 26 2008 6:03 pm
Subject: Re: [TurboGears] Re: setuptools strangeness: bdist_egg works only in svn checkout

On Wed, Mar 26, 2008 at 10:10 PM, Felix Schwarz <felix.schw...@web.de> wrote:
>  I filed this for 1.1 although I really would like to see this fixed
>  for 1.0 too :-)

You'll have to bye me one or two beers next time I visit you in Berlin :-)

    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
Felix Schwarz  
View profile
 More options Mar 27, 6:51 am
From: Felix Schwarz <felix.schw...@web.de>
Date: Thu, 27 Mar 2008 03:51:30 -0700 (PDT)
Local: Thurs, Mar 27 2008 6:51 am
Subject: Re: setuptools strangeness: bdist_egg works only in svn checkout

On 26 Mrz., 23:03, "Florent Aide" <florent.a...@gmail.com> wrote:

> On Wed, Mar 26, 2008 at 10:10 PM, Felix Schwarz <felix.schw...@web.de> wrote:
> >  I filed this for 1.1 although I really would like to see this fixed
> >  for 1.0 too :-)

> You'll have to bye me one or two beers next time I visit you in Berlin :-)

No problem, just give me (or Diez) a call :-)

fs


    Reply to author    Forward  
You must Sign in before you can post messages.
To post a message you must first join this group.
Please update your nickname on the subscription settings page before posting.
You do not have the permission required to post.
End of messages
« Back to Discussions « Newer topic     Older topic »

Create a group - Google Groups - Google Home - Terms of Service - Privacy Policy
©2008 Google