This PR expands the regex used to extract context variable references to accept the dict.get() method used in YAQL expressions:
<% ctx().get("dict_key") %>
Note that specifying default values are also accepted:
<% ctx().get("dict_key", "default_value") %>
This feature was added to Orquesta in the lead up to the ST2 v3.1 release, but support for it was not added to this project.
I also add a lot more tests for the context variable extraction, since that regex is getting more and more gnarly.
Furthermore, I also pulled in some changes from st2 for dist_utils.py and made a few tweaks to the Makefile. The issues in dist_utils.py were causing import issues in setup.py, which was causing PYMODULE_NAME in the Makefile to be blank, which was causing the coverage module flag to nose to be empty, which made coverage run results over all imported Python modules...which made my coverage results look huge and the coverage percent to inaccurately be ~0%. Whee, cascading failures are fun!
This PR expands the regex used to extract context variable references to accept the
dict.get()
method used in YAQL expressions:Note that specifying default values are also accepted:
This feature was added to Orquesta in the lead up to the ST2 v3.1 release, but support for it was not added to this project.
I also add a lot more tests for the context variable extraction, since that regex is getting more and more gnarly.
Furthermore, I also pulled in some changes from
st2
fordist_utils.py
and made a few tweaks to theMakefile
. The issues indist_utils.py
were causing import issues insetup.py
, which was causingPYMODULE_NAME
in theMakefile
to be blank, which was causing the coverage module flag to nose to be empty, which made coverage run results over all imported Python modules...which made my coverage results look huge and the coverage percent to inaccurately be ~0%. Whee, cascading failures are fun!