htmlapi-client-python
htmlapi-client-python copied to clipboard
Sample Python code for driving an HTML-based hypermedia API
If allow_multi is True, and there are multiple links for a particular relation then the code will fall through to the final return statement: https://github.com/Comcast/htmlapi-client-python/blob/master/htmlapi_client.py#L278 This returns "out" which is...
in an effort to be a good (if nit-picky) citizen note that I did _not_ alter the inline return statements because that seemed like potentially an intentional decision
If this takes on any kind of broader life, we'll definitely need tests. Probably this will need to include a mocking framework to intercept the urllib2 or httplib calls.
This allows for a continuous presentation of HTML "next states" while allowing the client to distinguish a 2XX from a 409/412, for example.
Right now, the client only supports `` and doesn't handle `` or ``. Handling of `` may also only be handling `text` or `hidden` correctly and is probably not doing...