- simplify python code (use json=, use strip)
- do not rename input as http_api (quite confusing, better to keep input everywhere in all tutorials
- reorder statement to always have input.user as first item in the rule
Signed-off-by: Sebastien de Menten <sdementen@gmail.com>
These changes modify topdown evaluation to use a binding list that
namespaces variables. This allows topdown to propagate partially ground
ref operands into child query evaluation.
These changes also prepare topdown evaluation to support a partial
evaluation mode.
With these changes, evaluation is no longer performed in two steps
(i.e., first pass of evaluating individual terms, second pass of
evaluating built-in expressions.) Instead, evaluation assumes queries
have been rewritten to eagerly evaluate refs and comprehension. This
way, ref and comprehension bindings do not have to be maintained
separately: they are handled by the normal variable binding list.
This commit contains some breaking changes to the topdown APIs,
namely...
1. Truth explanation has been removed. This feature was not used and the
tracing changes broke it. We can revisit in future if necessary.
2. Data indexing has been removed. Data indexing can be re-added in
future if necessary however it should be handled outside of topdown to
avoid potential memory leaks.
3. Built-in functions produce at-most-one output now. Functions that
used to produce multiple outputs (e.g., io.jwt.decode) can produce a
composite value if they need to.
Fixes#131
Before we were using the "latest" tag in the tutorial. This caused an
issue because we thought the JWT token support added to the toy server
had been built and published under the latest tag however it had not.
Since the toy server functionality is somewhat coupled to the tutorial,
hardcoding the version number here is acceptable.
These changes contain a redesign of the OPA website. The main changes
are (1) new frontpage w/ refreshed messaging and assets and (2) docs
ported to gitbook.