Flask
While there was much to love about Kenneth Reitz's 'Responder' framework, it was ultimately pulling in too many dependencies, for reasons that Nerium doesn't really need. I decided to stick with Flask for the foreseeable future, and this release rewrites `app.py` using Flask.
There is also a significant change to the public web API. This was unrelated to the Flask move, and in fact implemented on Responder first before porting over:
Report discovery
🎉 The release adds "discovery" endpoints:
- list reports available on the server
- get a description of each report by name, including columns returned, parameters expected, and other metadata if provided
See README for more details. Here, note that it was impossible to add these without changing the URL paths to distinguish between discovery endpoints and report results endpoints. Base paths are now:
- `/v1/reports/<name>` for discovery endpoints
- `/v1/results/<name>` for reporting results (formerly the whole app)
Query metadata formatting
Instead of using the `frontmatter` library and making query files a mashup of SQL and YAML, as of this release YAML metadata should be placed in a multiline comment, with a special `:meta` label introducing the comment. Again, usage is covered in the README
Remove plugin architecture for other query types
The library portion of Nerium had a fair amount of logic—some of it arguably verging on indirection and cruft—devoted to the idea that we might some day support non-SQL query languages, either by adding more `nerium.resultset` modules, or allowing third parties to provide `nerium-*` plugins. This was probably hurting performance, was certainly hurting maintainability, and the use case for it was speculative at best. This release drops all that, in favor of a single `db` module, using SQLAlchemy. Output formats can still be customized, with Marshmallow schemas.