Questions tagged [egg]
A python egg is a file used for distributing python projects as bundles; it is usually compressed with the zip algorithm. Egg files normally include some metadata; the file extension is ".egg". The concept is very similar to a Java .jar file.
355
questions
697
votes
4
answers
375k
views
What is a Python egg?
I'm trying to understand how Python packages work. Presumably eggs are some sort of packaging mechanism, but what would be a quick overview of what role they play and may be some information on why ...
162
votes
8
answers
199k
views
Most Pythonic way to provide global configuration variables in config.py? [closed]
In my endless quest in over-complicating simple stuff, I am researching the most 'Pythonic' way to provide global configuration variables inside the typical 'config.py' found in Python egg packages.
...
146
votes
6
answers
47k
views
Is there a python equivalent of Ruby's 'rvm'?
Q: Do we have anything functionally equivalent in Python to the Ruby version manager 'rvm'?
(RVM lets you easily switch completely between different versions of the ruby interpreter and different ...
108
votes
3
answers
210k
views
Build a wheel/egg and all dependencies for a python project
In order to stage python project within our corporation I need to make an installable distribution.
This should include:
An egg or whl for my project
An egg or whl for every dependency of the ...
99
votes
3
answers
143k
views
How to create Python egg file
I have questions about egg files in Python.
I have much Python code organized by package and I'm trying to create egg files.
I'm following instructions, but they are very common.
According to that, ...
88
votes
1
answer
74k
views
Python packages and egg-info directories
Can someone explain how egg-info directories are tied to their respective modules? For example, I have the following:
/usr/local/lib/python2.5/site-packages/quodlibet/
/usr/local/lib/python2.5/site-...
64
votes
7
answers
22k
views
How do I manage third-party Python libraries with Google App Engine? (virtualenv? pip?)
What's the best strategy for managing third-party Python libraries with Google App Engine?
Say I want to use Flask, a webapp framework. A blog entry says to do this, which doesn't seem right:
$ cd /...
59
votes
2
answers
26k
views
What is the difference between an 'sdist' .tar.gz distribution and an python egg?
I am a bit confused. There seem to be two different kind of Python packages, source distributions (setup.py sdist) and egg distributions (setup.py bdist_egg).
Both seem to be just archives with the ...
48
votes
9
answers
216k
views
How to get setuptools and easy_install?
I downloaded the ez_setup code from here: http://peak.telecommunity.com/dist/ez_setup.py
and ran it, but i don't think setuptools was properly installed. When i try to open an egg using easy_install i ...
36
votes
4
answers
49k
views
How to run Python egg files directly without installing them?
Is it possible to run Python egg files directly as you can run jar files with Java?
For example, with Java you might dos something like:
$ java -jar jar-file
35
votes
6
answers
20k
views
AssertionError: Egg-link .. does not match installed location of ReviewBoard (at /...)
AssertionError: Egg-link /home/daniel/other-rb/reviewboard does not match installed location of ReviewBoard (at /home/daniel/reviewboard)
I believe this was caused by me installing a package at an ...
29
votes
1
answer
12k
views
"pipenv requires an #egg fragment for version controlled dependencies" warning when installing the BlueJeans meeting API client
Adapting the instructions from https://github.com/bluejeans/api-rest-meetings/tree/master/libs/python#pip-install, in a pipenv shell I'm trying to run
pipenv install git+https://github.com/bluejeans/...
28
votes
6
answers
11k
views
What are the advantages of packaging your python library/application as an .egg file?
I've read some about .egg files and I've noticed them in my lib directory but what are the advantages/disadvantages of using then as a developer?
28
votes
2
answers
9k
views
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 ...
28
votes
2
answers
43k
views
How do I uninstall a Python module (“egg”) that I installed with easy_install?
I’ve installed a couple of Python modules using easy_install. How do I uninstall them?
I couldn’t see an uninstall option listed in easy_install --help.
26
votes
1
answer
9k
views
How to determine the name of an egg for a Python package on Github?
I know I can install with
$ pip install -e git+https://git.repo/some_pkg#egg=SomePackage
but -- when I'm trying to use somebody else's package -- how do I determine what the name of the egg is?
25
votes
6
answers
47k
views
How to access files inside a Python egg file?
This might be a weird requirement but it's what I've run into. I Googled but yield nothing.
I'm coding an application who's using a lot of constant attributes / values recorded in an XML file (they'...
22
votes
1
answer
4k
views
egg_info directory in VC?
Do you keep the foo.egg_info directory in version control?
Here an example where it would be nice to have it in VC:
pip install -e foo
Someone else adds a new EntryPoint (pkg_resource)
You update ...
21
votes
4
answers
17k
views
Where can I download binary eggs with psycopg2 for Windows?
I'm looking for binary eggs with psycopg2's binaries for Windows but can't find any.
On http://initd.org/psycopg/download/ there's only source package and link to Windows port of Psycopg which ...
21
votes
2
answers
10k
views
Can I convert an egg to wheel?
I have an already built/downloaded Python egg and I would like to convert it to the wheel format documented in PEP 427.
How can I do this?
21
votes
3
answers
9k
views
How do I turn a python program into an .egg file?
How do I turn a python program into an .egg file?
20
votes
6
answers
4k
views
How can I make setuptools ignore subversion inventory?
When packaging a Python package with a setup.py that uses the setuptools:
from setuptools import setup
...
the source distribution created by:
python setup.py sdist
not only includes, as usual, ...
19
votes
2
answers
9k
views
Why does easy_install extract some python eggs and not others?
Looking in my /usr/local/lib/python.../dist-package directory, I have .egg directories and .egg files.
Why does the installer choose to extra packages to the .egg directory, yet leave other files ...
19
votes
2
answers
19k
views
Python setup.py include .json files in the egg
I want to package .json files as well in the python egg file.
For example: boto package has endpoints.json file. But when I run python setup.py bdist_egg it does not include the json file in the egg. ...
19
votes
2
answers
6k
views
Easy_install cache downloaded files
Is there a way to configure easy_install to avoid having to download the files again when an installation fails?
18
votes
4
answers
26k
views
How do I install an .egg file without easy_install in Windows?
I have Python 2.6 and I want to install easy _ install module. The problem is that the only available installation package of easy _ install for Python 2.6 is an .egg file! What should I do?
18
votes
1
answer
18k
views
Create a python executable using setuptools
I have a small python application that I would like to make into a downloadable / installable executable for UNIX-like systems. I am under the impression that setuptools would be the best way to make ...
16
votes
2
answers
23k
views
Why does pip fail when installing local egg repository?
I am working on Windows 7.I have created a python egg using distutils. Now I try to install this egg in a virtual environment using pip 1.0.2 using the following command:
Then I create a virtual ...
16
votes
2
answers
29k
views
How to include a python .egg library that is in a subdirectory (relative location)?
How do you import python .egg files that are stored in a relative location to the .py code?
For example,
My Application/
My Application/library1.egg
My Application/libs/library2.egg
My Application/...
15
votes
1
answer
5k
views
Difference between prune and recursive-exclude in setuptools?
I am using setuptools to package a custom module for deployment, which should not include certain files in the data/ directory that were used for development. I have succesfully excluded the necessary ...
15
votes
5
answers
16k
views
pip: Why sometimes installed as egg, sometimes installed as files
Where can you force pip to install as "flat" and not as "egg".
For me it seems random. Sometimes it gets installed as egg, sometime as flat.
pip help install shows only an option --egg which forces ...
14
votes
3
answers
360
views
Do I have any obligations if I upload an egg to the CheeseShop?
Suppose I'd like to upload some eggs on the Cheese Shop. Do I have any obligation? Am I required to provide a license? Am I required to provide tests? Will I have any obligations to the users of this ...
13
votes
2
answers
11k
views
python: simple example for a python egg with a one-file source file?
I'm not quite sure how to build a really simple one-file source module. Is there a sample module out there one the web somewhere which can be built as a python .egg?
From the setuptools page it looks ...
12
votes
3
answers
11k
views
What are simple instructions for creating a Python package structure and egg?
I just completed my first (minor) Python project, and my boss wants me to package it nicely so that it can be distributed and called from other programs easily. He suggested I look into eggs. I've ...
12
votes
2
answers
9k
views
How does Python keep track of modules installed with eggs?
If I have a module, foo, in Lib/site-packages, I can just import foo and it will work. However, when I install stuff from eggs, I get something like blah-4.0.1-py2.7-win32.egg as a folder, with the ...
12
votes
2
answers
10k
views
error: invalid command 'bdist_egg'
I am running:
Ubuntu 13.04
Python 2.7.4
I am trying this very simple tutorial on making a python egg, but am having difficulties when I actually try to run the command to make the egg.
<me&...
12
votes
2
answers
19k
views
Bundle python script and dependencies into a single file
I have a few script that had their own copy of a some functions, so I extracted these functions to a module and had the scripts import the function. These script are to be copied over to a bunch of ...
12
votes
1
answer
3k
views
include only *.pyc files in python wheel
How can I include only *.pyc files in a python wheel?
When creating eggs, it used to be possible to run
python setup.py bdist_egg --exclude-source-files
Given that eggs have been replaced by wheels, ...
12
votes
1
answer
2k
views
Difference between a Python 'egg' and 'wheel'
I was installing pandas on my machine and came across this error:
Running setup.py (path:/tmp/pip-build-WzvvgM/pandas/setup.py) egg_info for package pandas
Cleaning up... Command python setup.py ...
12
votes
1
answer
3k
views
Databricks (Spark): .egg dependencies not installed automatically?
I have a locally created .egg package that depends on boto==2.38.0. I used setuptools to create the build distribution. Everything works in my own local environment, as it fetches boto correctly from ...
11
votes
2
answers
5k
views
Problem accessing config files within a Python egg
I have a Python project that has the following structure:
package1
class.py
class2.py
...
package2
otherClass.py
otherClass2.py
...
config
dev_settings.ini
prod_settings.ini
I wrote ...
11
votes
1
answer
4k
views
`pip freeze` breaks with package installation
I am installing a package using dependency_links. It seems to install the package alright but breaks pip freeze functionality (which probably means there is a deeper install issue.) I want to be ...
11
votes
1
answer
30k
views
Installing egg through pip
I can successfully install egg for morfeusz2 through
python -m easy_install http://sgjp.pl/morfeusz/download/20181014/ubuntu-xenial/morfeusz2-0.4.0-py3.7-win-amd64.egg
However, all other ...
11
votes
1
answer
7k
views
zip_safe = False is not working in setup.py file
I want to install my project as a folder instead of .egg file. So I have used zip_safe= False inside setup function in setup.py file
But when I am running this my project is getting installed as .egg ...
9
votes
2
answers
4k
views
How to prevent setuptools install package as an .egg
For example, installing IPython on Linux (where setuptools is not installed) I've got IPython installed in site-packages\IPython.
Installing IPython on Windows (where IPython requires setuptools), ...
8
votes
3
answers
10k
views
Importing Python libraries and gracefully handling if they are not availalble
I would like to import bunch of libraries and catch the exception.
If I have only 1 try catch block I get 1 exception (the first one). Is there a pattern to iterate over all of the libs and have a ...
8
votes
1
answer
57k
views
Unable to install pip: Permission denied error
I am trying to install pip but currently unable to.
I navigate to the pip folder and
python setup.py install
Everything seems to go fine until the very end:
Extracting pip-0.8.2-py2.6.egg to /...
8
votes
1
answer
2k
views
Python: If there are multiple egg versions of the same package installed, how do I import specifically the version I need?
Say, for example that FooPackage-1.1 and FooPackage-1.2 are both installed in dist-packages as eggs. How do I import the one I need?
8
votes
4
answers
2k
views
Python Code Organization Question : Eggs + Packages + Buildout + Unit Tests + SVN
I have several python projects that share common modules. Until now, I've been ... ahem ... keeping multiple copies of the common code and synchronizing by hand. But I'd clearly prefer to do something ...
8
votes
2
answers
7k
views
What is the point of Python egg files?
When I run python setup.py install django, it generates an egg file.
What is the usefulness of Python egg files?