boto/botocore — pull request #113 by toastdriven (2013-08-21 23:40:20+00:00)
Title: Multiple versions

This branch adds multiple version loading support to botocore. It functions but is not complete, but I need feedback.

Things that don't work:
1. Loading all service files at once (i.e. ``loader.get_data('aws')``). They'll all be loaded, but they'll be just version names (``2012-10-01``, not ``ec2``). I'm not sure what to do here. @jamesls felt strongly about leaving ``botocore.base`` alone & just doing path mangling above that at the loader level. Works most of the time, but falls down here & I'm not sure what to do to correct it.
2. Loading full paths into a structure (i.e. ``loader.get_data('aws/ec2/operations/DescribeInstances/input/members')``). After talking it through with @jamesls the other day, I think it'd reduce complexity do drop this & just do ``loader.get_data('aws/ec2')['operations']['DescribeInstances']['input']['members']`` (or use ``jmespath`` if the brackets offend). This capability is barely used (3 places between both ``botocore`` & ``aws-cli`` by my count). If not, trying to decide what the latest version of a file is when a big mixed path is present becomes a much more invasive process.

It passes most tests (except ones that rely on the above). I'm not super-happy with it, but given the constraints & what I think @jamesls said he wanted, it's the best I've got thus far.

Feedback would be very much appreciated - @garnaat / @jamesls.

Once we've got the two above decided, I'd be happy to finish the code, add better docs & update ``aws-cli`` to match.