EASYDEV documentation

contributions:Please join https://github.com/cokelaer/easydev
source:Please use https://github.com/cokelaer/easydev
issues:Please use https://github.com/cokelaer/easydev/issues
Python version supported:
 2.6, 2.7, 3.3, 3.4, 3.5, 3.6


The package easydev provides miscellaneous functions that are often used in other Python packages. easydev should help developers in speeding up their own developments.

Some functions are very simple such as the swapdict(), which inverts the keys/values in a dictionary (assuming unique keys):

>>> from easydev import swapdict
>>> d = {'a': 1, 'b': 2}
>>> inv = swapdict(d)
>>> inv
{1: 'a', 2: 'b'}

Other functions such as the progress bar (progressbar) are more complex.

Another example is the AttrDict() function: it makes the keys of a dictionary accessible as attributes. Meaning that you can get or set the values quickly as follows:

>>> from easydev import AttrDict
>>> d = AttrDict(**{'a': 1, 'b': 2})
>>> d.a
>>> d.a = 10
>>> d.a

There are many such functions in easydev and the best is to have a look at the User Guide section for more examples and the References guide for an exhaustive list of tools available.

Note also that easydev was starting a few years ago and that some functionalities did not exist back then. Some functionalities available in easydev may now exist in standard modules of Python.