setuptools

How can I get the version defined in setup.py (setuptools) in my package?

How could I get the version defined in setup.py from my package? (for --version, or other purposes) thanks! ...

Can a Python package depend on a specific version control revision of another Python package?

Some useful Python packages are broken on pypi, and the only acceptable version is a particular revision in a revision control system. Can that be expressed in setup.py e.g requires = 'svn://example.org/useful.package/trunk@1234' ? ...

How can I make this long_description and README differ by a couple of sentences?

For a package of mine, I have a README.rst file that is read into the setup.py's long description like so: readme = open('README.rst', 'r') README_TEXT = readme.read() readme.close() setup( ... long_description = README_TEXT, .... ) This way that I can have the README file show up on my github page every time I commit...

Use distribute/setuptools to create symlink (or run script)?

As part of my project's setup process, I need to symlink one of the packages to a specified directory so an init.d script can find it. Is there any way to add this as a post-processing command to setup()? I would even settle for creating another file that creates the link and pass it to setup() as part of some kwarg list of "run these" (...

Problem installing OpenERP server with buildout !

I'm trying to deploy OpenERP with a buildout and my own piece of code. In fact I would like to build a complete deployement structure allowing me to use OpenERP with custom modules and patch. First of all, before adding any personnal configuration, I was trying to create a buildout which will have the responsability to configure everyth...

PIP install a Python Package without a setup.py file?

I'm trying to figure out how I can install a python package that doesn't have a setup.py file with pip. (package in question is http://code.google.com/p/django-google-analytics/) Normally I would just checkout the code from the repo and symlink into my site-packages, but I'm trying to get my whole environment frozen into a pip requireme...

Python setuptools import error (Using NetBeans)

Hi, I tried to find a question that would answer to this question but wasn't succesful, so I made a new question. I'm trying to compile my old Python Tic Tac Toe game in NetBeans, but I get the error message ImportError: No module named setuptools In my actual code I haven't imported a module named setuptools. As much as I understan...

How can I detect errors programatically when building an egg with setuptools?

If I have a script that builds eggs, basically by running python setup.py bdist_egg --exclude-source-files for a number of setup.py files that use setuptools to define how eggs are built, is there an easy way to determine if there were any errors in building the egg? A situation I had recently, was that there was a syntax error in a ...

python egg development environment setup

hi, I inherited a python project, which has been packaged as egg. Upon check out through SVN, I am seeing package content as: __init__.py scripts/ ptools/ setup.py ... Here, ptools/ hold the source of various modules. scripts/ is bunch of end-user tools that make use of modules provided by the "ptools". The package has been installed...

Does setup.py's extras_require keyword support comma-separated extras?

Setuptools lets you list requirements for optional features # mypackage 'extras_require' : { 'PDF' : ['reportlab'], 'DOCX' : ['docxlib'] } and another package can specify 'requires' : [ 'mypackage[PDF]' ]. If another package wants to require more than one extra from the first package, can it ask for 'requires' : [ 'mypackage[PDF, DOC...

How to configure for multiple gettext domains with babel, pylons, setuptools

While trying to internationalize my pylons web and mobile application, 'myapp', Im finding that I would like to keep separate gettext pot files for separate domains. There will be common msgid values for both web and mobile users and there will also be unique msgid values that are only translated for web or mobile users. Im expecting l...

Easiest way to automatically download required modules in Python?

I would like to release a python module I wrote which depends on several packages. What's the easiest way to make it so these packages are programmatically downloaded just in case they are not available on the system that's being run? Most of these modules should be available by easy_install or pip or something like that. I simply want ...

"UserWarning: Unbuilt egg for setuptools" - What does this actually mean?

Hiya. When I install things into a virtualenv using pip I often see the message "UserWarning: Unbuilt egg for setuptools". I always safely ignore it and go about my business and it doesn't seem to cause me any problems. But I've suddenly been smacked in the face with curiosity, and wondered if someone could explain what it means, exac...

ant scripts for configuring a new machine with relevant software

A new developer machine needs a variety of software (e.g. java, eclipse, ANT, maven, SVN client), are there any scripts or tools which will set the environment / path variables after retreiving the software from binary distributions. ...

Having my Python package install shortcuts in Start menu

I'm making a Python package that gets installed with a setup.py file using setuptools. The package includes a GUI, and when it's installed on a Windows machine, I want the installation to make a folder in "Programs" in the start menu, and make a shortcut there to a pyw script that will start the GUI. (The pyw think works on all platform...

Having py2exe include my data files (like include_package_data)

I have a Python app which includes non-Python data files in some of its subpackages. I've been using the include_package_data option in my setup.py to include all these files automatically when making distributions. It works well. Now I'm starting to use py2exe. I expected it to see that I have include_package_data=True and to include a...

appscript on OSX 10.6.3 / Python 2.6.1

I am having some trouble getting appscript installed on OS/X 10.6.3 / Python 2.6.1. When I issue sudo easy_install appscript I get "unable to execute gcc-4.2: No such file or directory". Even when I do export CC=/Developer/usr/bin/gcc-4.2 (a valid gcc-4.2 executable), easy_install barks. What could be the issue? Disclaimer: OS/X new...

Python Finding all packages inside a package, even when in an egg

Given a Python package, how can I automatically find all its sub-packages? I used to have a function that would just browse the file system, looking for folders that have an __init__.py* file in them, but now I need a method that would work even if the whole package is in an egg. ...

Python: Why do some packages get installed as eggs and some as "egg folders"?

I maintain a few Python packages. I have a very similar setup.py file for each of them. However, when doing setup.py install, one of my packages gets installed as an egg, while the others get installed as "egg folders", i.e. folders with an extension of "egg". I couldn't figure out what is the difference between them that causes this di...

Installing Python egg dependencies without apt-get

I've got a Python module which is distributed on PyPI, and therefore installable using easy_install. It depends on lxml, which in turn depends on libxslt1-dev. I'm unable to install libxslt1-dev with easy_install, so it doesn't work to put it in install_requires. Is there any way I can get setuptools to install it instead of resorting to...