cylc/cylc — pull request #283 by hjoliver (2013-02-05 12:23:58+00:00)
Title: 134 multiple inheritance

Not ready for merge yet, but can be tested.

See ```examples/namespaces/multi-inherit/```, read the description inside the suite definition, and test by running the suite, graphing it, and using ```cylc get-config``` to retrieve task environment sections.

Still to do:

* 4 battery tests fail - the suites don't validate due to "undefined parent namespace" errors, should be easy to fix but I haven't looked into it yet.

* document this in the user guide

* grouped family mode in the tree view doesn't work properly. Unlike the graph, the treeview needs to be able to display a family and its members at once, so I'll think we'll have to pretend single inheritance using the first parent declared in each namespace.

* is the current graph collapse/expand behavior what we want? A node collapses into the *first* of its parents, but the full MI hierarchy determines all the family members that get sucked into the parent node (not just those that declare it as first parent).

* rename all inheritance-related data structures in ```config.py``` more sensibly

* more efficient computation of inherited namespaces - the initial MI implementation reverses one of the suite parsing efficiency gains of a few months back, which was to do each inheritance operation only once (e.g. if ```root -> a -> x``` and ```root -> a -> y```, don't compute ```root -> a``` twice). This is not quite as straightforward under MI as the order of inheritance in the linearized MRO can now be different for different tasks - so we now need to avoid re-computing inheritance for a particular MRO list that has already be done.