distribute

correct way to find scripts directory from setup.py in Python distutils?

梦想与她 提交于 2019-12-23 08:33:34
问题 I am distributing a package that has this structure: mymodule: mymodule/__init__.py mymodule/code.py scripts/script1.py scripts/script2.py The mymodule subdir of mymodule contains code, and the scripts subdir contains scripts that should be executable by the user. When describing a package installation in setup.py , I use: scripts=['myscripts/script1.py'] To specify where scripts should go. During installation they typically go in some platform/user specific bin directory. The code that I

iOS Enterprise Developer Program: how would Apple tell random customers from employees?

情到浓时终转凉″ 提交于 2019-12-23 03:15:54
问题 A Mobile Operator needs to distribute an app which is using private APIs onto non-jailbroken devices. From what I've read everywhere so far, this is not possible. Just out of curiosity: Enterprise Developer Program is reserved for apps that are distributed within the company only and is used by employees or contractors, but how would Apple find out if the user is an employee or just some random iPhone user? Of course, if the number of customers grows big enough, Apple will notice that some

Why doesn't setuptools 1.3.1 appear when I pip freeze?

妖精的绣舞 提交于 2019-12-21 03:35:15
问题 I am running virtualenvwrapper and friends on Ubuntu 12.04 (virtualenvwrapper 1.7.1.2, virtualenv 1.7.1.2, pip 1.0, Distribute 0.6.24, Python 2.7). To be able to pip install matplotlib I need a newer version of Distribute/setuptools, so I do the following: $ mkvirtualenv new_venv $ pip install matplotlib # fails $ easy_install -U distribute # installs Distribute 0.7.3 in the venv, # which then installs setuptools 1.3.1 $ pip install matplotlib # works However, when I run pip freeze I get:

How do setuptools, distribute, and pip relate to one another?

可紊 提交于 2019-12-20 08:28:16
问题 I've been teaching myself Python through the book "Learn Python The Hard Way" (2nd Edition). In exercise 46 it told me to read up on Pip, Distribute, and a few other packages. The documentation for pip was clear enough. It allows me to install/uninstall, and upgrade packages. Reading the documentation for distribute, it basically seems to do the same thing: Easily download, build, install, upgrade, and uninstall Python packages What's the difference between pip and distribute, and how do they

install_requires based on python version

为君一笑 提交于 2019-12-18 10:33:10
问题 I have a module that works both on python 2 and python 3. In Python<3.2 I would like to install a specific package as a dependency. For Python>=3.2. Something like: install_requires=[ "threadpool >= 1.2.7 if python_version < 3.2.0", ], How can one make that? 回答1: setuptools has support for this using environment markers. install_requires=[ 'enum34;python_version<"3.4"', 'pywin32 >= 1.0;platform_system=="Windows"' ] Use of this is detailed in the official documentation. Based on the change log

Installing distribute in Python 3.3 Ubuntu

跟風遠走 提交于 2019-12-18 09:45:15
问题 I am running Ubuntu 12.04 and I have a distribution of Python 3.3.1 installed. I want to install some packages, so I first sought to install distribute-0.6.38. During the "install" phase, I am encountering the following runtime error ($HOME is the location of my Python3.3 installation): File "$HOME/Python-3.3.1/Lib/zipfile.py", line 583, in _check_compression "Compression requires the (missing) zlib module" RuntimeError: Compression requires the (missing) zlib module I tracked back through

Packaging resources with setuptools/distribute

人走茶凉 提交于 2019-12-17 22:52:34
问题 I'm developing an Python egg that has several .txt dependencies (they're templates used to generate files by the egg itself), and I'm struggling to get those dependencies copied to site-packages during setup.py install . According to the distribute documentation... Filesystem of my package: setup.py package |--- __init__.py |--- main.py |--- binary (calls main.py with pkg_resources.load_entry_point) |--- templates |--file1.txt |--file2.txt In setup.py: setup( [...] eager_resources = [

Heroku push rejected due to pip/distribute bug. What's the workaround?

那年仲夏 提交于 2019-12-14 00:33:46
问题 My local git/virtualenv is using pip version 1.3.1. When I try to push my Python 3.3.2 app to Heroku, I get Downloading/unpacking distribute==0.6.34 (from -r requirements.txt (line 5)) Running setup.py egg_info for package distribute Traceback (most recent call last): File "<string>", line 3, in <module> File "./setuptools/__init__.py", line 2, in <module> from setuptools.extension import Extension, Library File "./setuptools/extension.py", line 5, in <module> from setuptools.dist import _get

Add a dll/so to a python built distribution

时光总嘲笑我的痴心妄想 提交于 2019-12-13 12:04:49
问题 I've compiled the python wrapper of nanomsg and I want to create a python installer for the package. The package can be created by running python setup.py bdist --format=wininst However I would like nanomsg.dll/nanomsg.so to be included in the installer/package but I haven't found any documentation regarding this issue. 回答1: As stated in the documentation here one needs to add the following code to his setup.py script: setup( name='nanomsg', version=__version__, packages=[str('nanomsg'), str(

should I re-install python again for zlib module? [duplicate]

若如初见. 提交于 2019-12-11 19:40:04
问题 This question already has answers here : Installing distribute in Python 3.3 Ubuntu (2 answers) Closed 6 years ago . When installing distribute-0.6.49 with python3.3.2 in Ubuntu system, error encountered ....blablabla followed by... "Compression requires the (missing) zlib module") RuntimeError: Compression requires the (missing) zlib module I have checked previous solutions that I need to install zlib package, but Should I re install my python again before that? can't I install zlib over it?