We populate a custom working set and compute its dependency graph, arranging for one distribution to appear more than once in the graph:
>>> anton_1 = make_dist("anton-1.egg", depends="""berta <3
... charlie >=1.1, !=1.7""")
>>> berta_2 = make_dist("berta-2.egg", depends="charlie <2")
>>> charlie_1_4 = make_dist("charlie-1.4.egg")
>>> ws = make_working_set(anton_1, berta_2, charlie_1_4)
>>> from tl.eggdeps.graph import Graph
>>> graph = Graph(working_set=ws)
>>> graph.from_working_set()
>>> sprint(graph)
{'anton': {'berta': {None: set([])}, 'charlie': {None: set([])}},
'berta': {'charlie': {None: set([])}},
'charlie': {}}
>>> from tl.eggdeps.requirements import print_list
>>> print_list(graph, Options())
['anton', 'berta', 'charlie']
>>> print_list(graph, Options(version_numbers=True))
['anton==1', 'berta==2', 'charlie==1.4']
>>> print_list(graph, Options(version_specs=True))
['anton>=1', 'berta>=2,<3', 'charlie>=1.4,!=1.7,<2']