hobbeswalsh/flask-sillywalk — pull request #9 by mplewis (2013-12-24 09:49:16+00:00)
Title: Update flask-sillywalk to work with Swagger 1.3

Hey! I've been playing with `flask-sillywalk`. I really, REALLY like it. Great simple elegant code.

I've been having some trouble with various features of Swagger due to a deprecated API version so I've updated your code (1.0 —> 1.3) to be more compliant with the current Swagger version.

Notable changes:
---

* **Allow the user to provide their API's version:** I'd like to be able to specify "my API is version 4.2" as Swagger spec provides. This shouldn't break any existing code as it uses a `kwarg` with a default to provide the API version during `SwaggerApiRegistry` initialization. (Readme has been updated to match!)

* **Change `ErrorResponses` to `ResponseMessages`:** It looks like the current version of Swagger has problems with response codes when we call them `ErrorResponses`. Swagger UI shows an HTTP Status Code but no Reason. When we call them `ResponseMessages`, everything works and Reason shows up again. (Readme has been updated to match!)

* **Add an "open with" declaration to the `.py` file:** make the first line of the file `#!/usr/bin/python`. Easy as pie!

I've tested this and it seems to work 100% fine in my application and with the new Readme code. I may have missed something so do check my work!

I think this update will be useful to other Flaskers. Let me know what you think! I'm always open to suggestions.

Thanks for your hard work on `sillywalk`!