Disadvantage of Python eggs?

2024/10/11 3:26:08

Are there any disadvantages about using eggs through easy-install compared to the "traditional" packages/modules/libs?

Answer

One (potential) disadvantage is that eggs are zipped by default unless zip_safe=False is set in their setup() function in setup.py. If an egg is zipped, you can't get at the files in it (without unzipping it, obviously). If the module itself uses non-source files (such as templates) it will probably specify zip_safe=False, but another consequence is that you cannot effectively step into zipped modules using pdb, the Python debugger. That is, you can, but you won't be able to see the source or navigate properly.

https://en.xdnf.cn/q/69819.html

Related Q&A

Does Google App Engine Flex support Pipfile?

For App Engine Standard the explicitly state that they do not support Pipfiles and immediately block you from pushing your project if it contains a Pipfile. In searching the documentation, I dont see a…

Keras sees my GPU but doesnt use it when training a neural network

My GPU is not used by Keras/TensorFlow.To try to make my GPU working with tensorflow, I installed tensorflow-gpu via pip (I am using Anaconda on Windows)I have nvidia 1080tiprint(tf.test.is_gpu_availab…

Identify if there are two of the same character adjacent to eachother

Ive been asked to create a program that identifies if a password is valid or not. The one part I am struggling with is identifying whether there are two of the same character adjacent to each other. He…

Extract lined table from scanned document opencv python

I want to extract the information from a scanned table and store it a csv. Right now my table extraction algorithm does the following steps.Apply skew correction Apply a gaussian filter for denoising. …

Nested Python C Extensions/Modules?

How do I compile a C-Python module such that it is local to another? E.g. if I have a module named "bar" and another module named "mymodule", how do I compile "bar" so th…

ImportError: No module named sysconfig--cant get pip working

Im really struggling with pip on a RedHat 6.9 system. Every time I tried to use pip, I got ImportError: No module named sysconfigI tried Googling for solutions. I dont have apt-get and cant seem to get…

Convert Dataframe to a Dictionary with List Values

Suppose I have a Dataframe df :Label1 Label2 Label3 key1 col1value1 col2value1 key2 col1value2 col2value2 key3 col1value3 col2value3dict1 = df.set_index(Label1).to_dic…

Efficiently count all the combinations of numbers having a sum close to 0

I have following pandas dataframe df column1 column2 list_numbers sublist_column x y [10,-6,1,-4] a b [1,3,7,-2] p q [6,2,-3,-3.…

What is the equivalent to iloc for dask dataframe?

I have a situation where I need to index a dask dataframe by location. I see that there is not an .iloc method available. Is there an alternative? Or am I required to use label-based indexing?For …

How to deal with limitations of inspect.getsource - or how to get ONLY the source of a function?

I have been playing with the inspect module from Pythons standard library. The following examples work just fine (assuming that inspect has been imported):def foo(x, y):return x - y print(inspect.getso…