[Distutils] sdist command doesn't include data files

Arve Knudsen arve.knudsen at gmail.com
Mon Jan 15 20:20:45 CET 2007

Hi Philip

On 1/15/07, Phillip J. Eby <pje at telecommunity.com> wrote:
> At 02:16 PM 1/15/2007 +0100, Arve Knudsen wrote:
> >Hi
> >I'm experiencing a problem when using setuptools (0.6c5) to generate a
> >source tarball, using the 'sdist' command. What happens is that data
> files
> >(PNGs) are omitted even though I include them in package_data (keyword to
> >setup), and they are correctly included when installing. Is it the
> >intended behaviour of 'sdist' to ignore package_data, or is this a bug?
> They should be included in the sdist.  Are you using CVS or Subversion,
> and
> if so, are the .png files under revision control?  That information will
> help me narrow down what the problem is.

After having sent this mail, I did some more digging on Google and from what
I understand sdist doesn't actually support the 'package_data' keyword,
right? This should really be better pointed out in the documentation,
as some of my colleagues also struggled with this before.

So I tried 'include_package_data' instead, after having extended setuptools
with support for the Mercurial VCS. This made sdist include also each and
every version-controlled Python file however. Is this the intended
behaviour? So in the end I resorted to MANIFEST.in, although I'd prefer to
keep this within setup.py.

If there's any interest I can provide the source for my Mercurial extension
(simple as it may be).

Arve Knudsen
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://mail.python.org/pipermail/distutils-sig/attachments/20070115/bfea92a7/attachment.htm 

More information about the Distutils-SIG mailing list