Project description

Do you have a list of integers? Do you want to know what ranges of consecutive
values the list covers? Do you need to solve a gaps and islands problem outside of
SQL? Maybe you have a list of dates and need to find the longest streak of
consecutive days on which something happened. No? Why not? Well, either way,
the derange module is here for you, ready to solve all these problems and a
couple more.

Full documentation can be viewed after installation with python3 -m pydoc
derange.

Installation

derange is written in pure Python 3 with no dependencies. Just use pip for Python 3 (You have pip, right?) to install:

python3 -m pip install derange

Examples

Condense commit years obtained from git log or the like into range
objects: