Compare commits
No commits in common. "dfd31c4fb4aab9bd176c1752926b791540460f84" and "688aa8d053529482776d7de03488faafbb7441a4" have entirely different histories.
dfd31c4fb4
...
688aa8d053
880 changed files with 4543 additions and 1227 deletions
13
CHANGELOG.md
13
CHANGELOG.md
|
|
@ -1,16 +1,3 @@
|
||||||
## 1.2.0a4 (2024-12-11)
|
|
||||||
|
|
||||||
### Feat
|
|
||||||
|
|
||||||
- move test to a new project rougail-tests
|
|
||||||
- output could have annotator
|
|
||||||
|
|
||||||
### Fix
|
|
||||||
|
|
||||||
- remove link
|
|
||||||
- reorganise user_datas
|
|
||||||
- only change prefix if path is relative
|
|
||||||
|
|
||||||
## 1.2.0a3 (2024-11-28)
|
## 1.2.0a3 (2024-11-28)
|
||||||
|
|
||||||
### Fix
|
### Fix
|
||||||
|
|
|
||||||
|
|
@ -4,7 +4,7 @@ requires = ["flit_core >=3.8.0,<4"]
|
||||||
|
|
||||||
[project]
|
[project]
|
||||||
name = "rougail"
|
name = "rougail"
|
||||||
version = "1.2.0a4"
|
version = "1.2.0a3"
|
||||||
authors = [{name = "Emmanuel Garette", email = "gnunux@gnunux.info"}]
|
authors = [{name = "Emmanuel Garette", email = "gnunux@gnunux.info"}]
|
||||||
readme = "README.md"
|
readme = "README.md"
|
||||||
description = "A consistency handling system that was initially designed in the configuration management"
|
description = "A consistency handling system that was initially designed in the configuration management"
|
||||||
|
|
|
||||||
|
|
@ -71,11 +71,6 @@ class SpaceAnnotator: # pylint: disable=R0903
|
||||||
if extra_annotator in ANNOTATORS:
|
if extra_annotator in ANNOTATORS:
|
||||||
continue
|
continue
|
||||||
get_annotators(ANNOTATORS, extra_annotator)
|
get_annotators(ANNOTATORS, extra_annotator)
|
||||||
if objectspace.output:
|
|
||||||
try:
|
|
||||||
get_annotators(ANNOTATORS, f"rougail.output_{objectspace.output}", "annotator")
|
|
||||||
except ModuleNotFoundError:
|
|
||||||
pass
|
|
||||||
for user_data in objectspace.user_datas:
|
for user_data in objectspace.user_datas:
|
||||||
try:
|
try:
|
||||||
get_annotators(ANNOTATORS, f"rougail.user_data_{user_data}", "annotator")
|
get_annotators(ANNOTATORS, f"rougail.user_data_{user_data}", "annotator")
|
||||||
|
|
@ -93,8 +88,6 @@ class SpaceAnnotator: # pylint: disable=R0903
|
||||||
annotators.extend(ANNOTATORS[f"rougail.{plugin}.annotator"])
|
annotators.extend(ANNOTATORS[f"rougail.{plugin}.annotator"])
|
||||||
for user_data in objectspace.user_datas:
|
for user_data in objectspace.user_datas:
|
||||||
annotators.extend(ANNOTATORS[f"rougail.user_data_{user_data}.annotator"])
|
annotators.extend(ANNOTATORS[f"rougail.user_data_{user_data}.annotator"])
|
||||||
if objectspace.output:
|
|
||||||
annotators.extend(ANNOTATORS[f"rougail.output_{objectspace.output}.annotator"])
|
|
||||||
annotators = sorted(annotators, key=get_level)
|
annotators = sorted(annotators, key=get_level)
|
||||||
functions = {}
|
functions = {}
|
||||||
functions_files = objectspace.functions_files
|
functions_files = objectspace.functions_files
|
||||||
|
|
|
||||||
|
|
@ -125,8 +125,6 @@ class Annotator(Walk):
|
||||||
if family.type == "dynamic" and isinstance(
|
if family.type == "dynamic" and isinstance(
|
||||||
family.dynamic, VariableCalculation
|
family.dynamic, VariableCalculation
|
||||||
):
|
):
|
||||||
path = family.dynamic.variable
|
|
||||||
if family.version != "1.0" and self.objectspace.paths.regexp_relative.search(path):
|
|
||||||
path = self.objectspace.paths.get_full_path(
|
path = self.objectspace.paths.get_full_path(
|
||||||
family.dynamic.variable,
|
family.dynamic.variable,
|
||||||
family.path,
|
family.path,
|
||||||
|
|
|
||||||
|
|
@ -92,7 +92,7 @@ class Annotator(Walk): # pylint: disable=R0903
|
||||||
elif variable.multi:
|
elif variable.multi:
|
||||||
msg = _(
|
msg = _(
|
||||||
'the variable "{0}" is multi but has a non list default value'
|
'the variable "{0}" is multi but has a non list default value'
|
||||||
).format(variable.path)
|
).format(variable.name)
|
||||||
raise DictConsistencyError(msg, 12, variable.xmlfiles)
|
raise DictConsistencyError(msg, 12, variable.xmlfiles)
|
||||||
elif variable.path in self.objectspace.followers:
|
elif variable.path in self.objectspace.followers:
|
||||||
self.objectspace.default_multi[variable.path] = variable.default
|
self.objectspace.default_multi[variable.path] = variable.default
|
||||||
|
|
|
||||||
|
|
@ -189,7 +189,6 @@ class FakeRougailConvert(RougailConvert):
|
||||||
self.force_optional = False
|
self.force_optional = False
|
||||||
self.plugins = ["structural_commandline"]
|
self.plugins = ["structural_commandline"]
|
||||||
self.user_datas = []
|
self.user_datas = []
|
||||||
self.output = None
|
|
||||||
self.add_extra_options = self.add_extra_options
|
self.add_extra_options = self.add_extra_options
|
||||||
|
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -395,7 +395,6 @@ class ParserVariable:
|
||||||
"structural_commandline.add_extra_options"
|
"structural_commandline.add_extra_options"
|
||||||
]
|
]
|
||||||
self.user_datas = rougailconfig["step.user_data"]
|
self.user_datas = rougailconfig["step.user_data"]
|
||||||
self.output = rougailconfig["step.output"]
|
|
||||||
self.plugins = rougailconfig["plugins"]
|
self.plugins = rougailconfig["plugins"]
|
||||||
|
|
||||||
def _init(self):
|
def _init(self):
|
||||||
|
|
|
||||||
|
|
@ -81,10 +81,6 @@ class NotFoundError(Exception):
|
||||||
pass
|
pass
|
||||||
|
|
||||||
|
|
||||||
class ExtentionError(Exception):
|
|
||||||
pass
|
|
||||||
|
|
||||||
|
|
||||||
## ---- specific exceptions ----
|
## ---- specific exceptions ----
|
||||||
|
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -21,7 +21,7 @@ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
|
||||||
from typing import List
|
from typing import List
|
||||||
from re import findall
|
from re import findall
|
||||||
|
|
||||||
from tiramisu import undefined, Calculation
|
from tiramisu import undefined
|
||||||
from tiramisu.error import PropertiesOptionError, LeadershipError, ConfigError
|
from tiramisu.error import PropertiesOptionError, LeadershipError, ConfigError
|
||||||
|
|
||||||
from .object_model import CONVERT_OPTION
|
from .object_model import CONVERT_OPTION
|
||||||
|
|
@ -32,148 +32,44 @@ class UserDatas:
|
||||||
self.config = config
|
self.config = config
|
||||||
|
|
||||||
def user_datas(self, user_datas: List[dict]):
|
def user_datas(self, user_datas: List[dict]):
|
||||||
self.values = {}
|
values = {}
|
||||||
self.errors = []
|
errors = []
|
||||||
self.warnings = []
|
warnings = []
|
||||||
self._populate_values(user_datas)
|
|
||||||
self._auto_configure_dynamics()
|
|
||||||
self._populate_config()
|
|
||||||
self._populate_error_warnings()
|
|
||||||
return {
|
|
||||||
"errors": self.errors,
|
|
||||||
"warnings": self.warnings,
|
|
||||||
}
|
|
||||||
|
|
||||||
def _populate_values(self, user_datas):
|
|
||||||
for datas in user_datas:
|
for datas in user_datas:
|
||||||
options = datas.get("options", {})
|
options = datas.get("options", {})
|
||||||
for name, data in datas.get("values", {}).items():
|
for name, data in datas.get("values", {}).items():
|
||||||
self.values[name] = {
|
values[name] = {
|
||||||
"values": data,
|
"values": data,
|
||||||
"options": options.copy(),
|
"options": options.copy(),
|
||||||
}
|
}
|
||||||
self.errors.extend(datas.get("errors", []))
|
errors.extend(datas.get("errors", []))
|
||||||
self.warnings.extend(datas.get("warnings", []))
|
warnings.extend(datas.get("warnings", []))
|
||||||
|
self._auto_configure_dynamics(values)
|
||||||
def _get_variable(self, config):
|
while values:
|
||||||
for subconfig in config:
|
|
||||||
if subconfig.isoptiondescription():
|
|
||||||
yield from self._get_variable(subconfig)
|
|
||||||
else:
|
|
||||||
yield subconfig
|
|
||||||
|
|
||||||
def _auto_configure_dynamics(self):
|
|
||||||
cache = {}
|
|
||||||
added = []
|
|
||||||
for path, data in list(self.values.items()):
|
|
||||||
value = data["values"]
|
|
||||||
try:
|
|
||||||
option = self.config.option(path)
|
|
||||||
option.name()
|
|
||||||
except (ConfigError, PropertiesOptionError):
|
|
||||||
pass
|
|
||||||
except AttributeError:
|
|
||||||
self._not_found_is_dynamic(self.config, path, cache, added)
|
|
||||||
|
|
||||||
def _not_found_is_dynamic(self, config, path, cache, added):
|
|
||||||
"""if path is not found, check if parent is a dynamic family
|
|
||||||
"""
|
|
||||||
current_path = ""
|
|
||||||
identifiers = []
|
|
||||||
# get parent
|
|
||||||
for name in path.split(".")[:-1]:
|
|
||||||
if current_path:
|
|
||||||
current_path += "."
|
|
||||||
current_path += name
|
|
||||||
if current_path in cache:
|
|
||||||
config, identifier = cache[current_path]
|
|
||||||
identifiers.append(identifier)
|
|
||||||
continue
|
|
||||||
tconfig = config.option(name)
|
|
||||||
try:
|
|
||||||
tconfig.group_type()
|
|
||||||
# object exists, so current config is the temporary config
|
|
||||||
config = tconfig
|
|
||||||
if config.isdynamic(only_self=True):
|
|
||||||
identifiers.append(config.identifiers()[-1])
|
|
||||||
except AttributeError:
|
|
||||||
# try to found the good dynamic family
|
|
||||||
for tconfig in config.list(uncalculated=True):
|
|
||||||
if not tconfig.isdynamic(only_self=True):
|
|
||||||
# it's not a dynamic variable
|
|
||||||
continue
|
|
||||||
identifier = self._get_identifier(
|
|
||||||
tconfig.name(), name
|
|
||||||
)
|
|
||||||
if identifier is None:
|
|
||||||
# it's a dynamic variable but doesn't match the current name
|
|
||||||
continue
|
|
||||||
dynamic_variable = tconfig.information.get(
|
|
||||||
"dynamic_variable",
|
|
||||||
None,
|
|
||||||
)
|
|
||||||
if not dynamic_variable:
|
|
||||||
# it's the good dynamic variable but it's not linked to a variable
|
|
||||||
# so cannot change the variable
|
|
||||||
continue
|
|
||||||
option_type = self.config.option(
|
|
||||||
dynamic_variable
|
|
||||||
).information.get("type")
|
|
||||||
dyn_options_values = self.config.option(dynamic_variable).get().impl_getdefault()
|
|
||||||
if "{{ identifier }}" in dynamic_variable:
|
|
||||||
for s in identifiers:
|
|
||||||
dynamic_variable = dynamic_variable.replace(
|
|
||||||
"{{ identifier }}", str(s), 1
|
|
||||||
)
|
|
||||||
if dynamic_variable not in self.values and not dyn_options_values:
|
|
||||||
self.values[dynamic_variable] = {"values": []}
|
|
||||||
added.append(dynamic_variable)
|
|
||||||
elif dynamic_variable not in added:
|
|
||||||
continue
|
|
||||||
config = tconfig
|
|
||||||
identifiers.append(identifier)
|
|
||||||
typ = CONVERT_OPTION.get(option_type, {}).get(
|
|
||||||
"func"
|
|
||||||
)
|
|
||||||
if typ:
|
|
||||||
identifier = typ(identifier)
|
|
||||||
if (
|
|
||||||
identifier
|
|
||||||
not in self.values[dynamic_variable]["values"]
|
|
||||||
):
|
|
||||||
self.values[dynamic_variable]["values"].append(
|
|
||||||
identifier
|
|
||||||
)
|
|
||||||
cache[current_path] = config, identifier
|
|
||||||
break
|
|
||||||
|
|
||||||
def _populate_config(self):
|
|
||||||
while self.values:
|
|
||||||
value_is_set = False
|
value_is_set = False
|
||||||
for option in self._get_variable(self.config):
|
for option in self._get_variable(self.config):
|
||||||
path = option.path()
|
path = option.path()
|
||||||
if path not in self.values:
|
if path not in values:
|
||||||
continue
|
continue
|
||||||
options = self.values[path].get("options", {})
|
options = values[path].get("options", {})
|
||||||
value = self.values[path]["values"]
|
value = values[path]["values"]
|
||||||
needs_convert = options.get("needs_convert", False)
|
|
||||||
|
|
||||||
# converted value
|
# converted value
|
||||||
if option.ismulti():
|
if option.ismulti():
|
||||||
if options.get("multi_separator") and not isinstance(value, list):
|
if options.get("multi_separator") and not isinstance(value, list):
|
||||||
value = value.split(options["multi_separator"])
|
value = value.split(options["multi_separator"])
|
||||||
self.values[path]["values"] = value
|
values[path]["values"] = value
|
||||||
if option.issubmulti():
|
if option.issubmulti():
|
||||||
value = [[val] for val in value]
|
value = [[val] for val in value]
|
||||||
if needs_convert:
|
if options.get("needs_convert"):
|
||||||
if option.issubmulti():
|
if option.issubmulti():
|
||||||
for idx, val in enumerate(value):
|
for idx, val in enumerate(value):
|
||||||
value[idx] = [convert_value(option, v) for v in val]
|
value[idx] = [convert_value(option, v) for v in val]
|
||||||
else:
|
else:
|
||||||
value = [convert_value(option, val) for val in value]
|
value = [convert_value(option, val) for val in value]
|
||||||
self.values[path]["values"] = value
|
values[path]["values"] = value
|
||||||
self.values[path]["options"]["needs_convert"] = False
|
values[path]["options"]["needs_convert"] = False
|
||||||
elif needs_convert:
|
elif options.get("needs_convert"):
|
||||||
value = convert_value(option, value)
|
value = convert_value(option, value)
|
||||||
index = option.index()
|
index = option.index()
|
||||||
if index is not None:
|
if index is not None:
|
||||||
|
|
@ -186,29 +82,18 @@ class UserDatas:
|
||||||
# value is correctly set, remove variable to the set
|
# value is correctly set, remove variable to the set
|
||||||
if index is not None:
|
if index is not None:
|
||||||
# if it's a follower waiting for all followers are sets
|
# if it's a follower waiting for all followers are sets
|
||||||
self.values[path]["values"][index] = undefined
|
values[path]["values"][index] = undefined
|
||||||
if set(self.values[path]["values"]) == {undefined}:
|
if set(values[path]["values"]) == {undefined}:
|
||||||
self.values.pop(path)
|
values.pop(path)
|
||||||
else:
|
else:
|
||||||
self.values.pop(path)
|
values.pop(path)
|
||||||
except Exception:
|
except Exception:
|
||||||
if path != option.path():
|
if path != option.path():
|
||||||
self.values[option.path()] = self.values.pop(path)
|
values[option.path()] = values.pop(path)
|
||||||
if not value_is_set:
|
if not value_is_set:
|
||||||
break
|
break
|
||||||
|
|
||||||
def _get_identifier(self, true_name, name) -> str:
|
|
||||||
if true_name == "{{ identifier }}":
|
|
||||||
return name
|
|
||||||
regexp = true_name.replace("{{ identifier }}", "(.*)")
|
|
||||||
finded = findall(regexp, name)
|
|
||||||
if len(finded) != 1 or not finded[0]:
|
|
||||||
return None
|
|
||||||
return finded[0]
|
|
||||||
|
|
||||||
def _populate_error_warnings(self):
|
|
||||||
# we don't find variable, apply value just to get error or warning messages
|
# we don't find variable, apply value just to get error or warning messages
|
||||||
for path, data in self.values.items():
|
for path, data in values.items():
|
||||||
try:
|
try:
|
||||||
option = self.config.option(path)
|
option = self.config.option(path)
|
||||||
value = data["values"]
|
value = data["values"]
|
||||||
|
|
@ -220,23 +105,148 @@ class UserDatas:
|
||||||
else:
|
else:
|
||||||
option.value.set(value)
|
option.value.set(value)
|
||||||
except AttributeError as err:
|
except AttributeError as err:
|
||||||
self.errors.append(str(err))
|
errors.append(str(err))
|
||||||
except (ValueError, LeadershipError) as err:
|
except (ValueError, LeadershipError) as err:
|
||||||
self.errors.append(str(err))
|
errors.append(str(err))
|
||||||
except PropertiesOptionError as err:
|
except PropertiesOptionError as err:
|
||||||
self.warnings.append(str(err))
|
warnings.append(str(err))
|
||||||
|
return {
|
||||||
|
"errors": errors,
|
||||||
|
"warnings": warnings,
|
||||||
|
}
|
||||||
|
|
||||||
|
def _get_variable(self, config):
|
||||||
|
for subconfig in config:
|
||||||
|
if subconfig.isoptiondescription():
|
||||||
|
yield from self._get_variable(subconfig)
|
||||||
|
else:
|
||||||
|
yield subconfig
|
||||||
|
|
||||||
|
def _auto_configure_dynamics(
|
||||||
|
self,
|
||||||
|
values,
|
||||||
|
):
|
||||||
|
cache = {}
|
||||||
|
added = []
|
||||||
|
for path, data in list(values.items()):
|
||||||
|
value = data["values"]
|
||||||
|
try:
|
||||||
|
option = self.config.option(path)
|
||||||
|
option.name()
|
||||||
|
except (ConfigError, PropertiesOptionError):
|
||||||
|
pass
|
||||||
|
except AttributeError:
|
||||||
|
config = self.config
|
||||||
|
current_path = ""
|
||||||
|
for name in path.split(".")[:-1]:
|
||||||
|
if current_path:
|
||||||
|
current_path += "."
|
||||||
|
current_path += name
|
||||||
|
if current_path in cache:
|
||||||
|
config, identifier = cache[current_path]
|
||||||
|
else:
|
||||||
|
tconfig = config.option(name)
|
||||||
|
try:
|
||||||
|
tconfig.group_type()
|
||||||
|
config = tconfig
|
||||||
|
except AttributeError:
|
||||||
|
for tconfig in config.list(uncalculated=True):
|
||||||
|
if tconfig.isdynamic(only_self=True):
|
||||||
|
identifier = self._get_identifier(
|
||||||
|
tconfig.name(), name
|
||||||
|
)
|
||||||
|
if identifier is None:
|
||||||
|
continue
|
||||||
|
dynamic_variable = tconfig.information.get(
|
||||||
|
"dynamic_variable",
|
||||||
|
None,
|
||||||
|
)
|
||||||
|
if not dynamic_variable:
|
||||||
|
continue
|
||||||
|
option_type = self.config.option(
|
||||||
|
dynamic_variable
|
||||||
|
).information.get("type")
|
||||||
|
identifiers = tconfig.identifiers()
|
||||||
|
if identifiers:
|
||||||
|
for s in identifiers:
|
||||||
|
dynamic_variable = dynamic_variable.replace(
|
||||||
|
"{{ identifier }}", str(s), 1
|
||||||
|
)
|
||||||
|
if dynamic_variable not in values and not self.config.option(dynamic_variable).get().impl_getdefault():
|
||||||
|
values[dynamic_variable] = {"values": []}
|
||||||
|
added.append(dynamic_variable)
|
||||||
|
elif dynamic_variable not in added:
|
||||||
|
continue
|
||||||
|
config = tconfig
|
||||||
|
typ = CONVERT_OPTION.get(option_type, {}).get(
|
||||||
|
"func"
|
||||||
|
)
|
||||||
|
if typ:
|
||||||
|
identifier = typ(identifier)
|
||||||
|
if (
|
||||||
|
identifier
|
||||||
|
not in values[dynamic_variable]["values"]
|
||||||
|
):
|
||||||
|
values[dynamic_variable]["values"].append(
|
||||||
|
identifier
|
||||||
|
)
|
||||||
|
cache[current_path] = config, identifier
|
||||||
|
break
|
||||||
|
else:
|
||||||
|
if option.isdynamic():
|
||||||
|
parent_option = self.config.option(path.rsplit(".", 1)[0])
|
||||||
|
identifier = self._get_identifier(
|
||||||
|
parent_option.name(uncalculated=True),
|
||||||
|
parent_option.name(),
|
||||||
|
)
|
||||||
|
dynamic_variable = None
|
||||||
|
while True:
|
||||||
|
dynamic_variable = parent_option.information.get(
|
||||||
|
"dynamic_variable",
|
||||||
|
None,
|
||||||
|
)
|
||||||
|
if dynamic_variable:
|
||||||
|
break
|
||||||
|
parent_option = self.config.option(
|
||||||
|
parent_option.path().rsplit(".", 1)[0]
|
||||||
|
)
|
||||||
|
if "." not in parent_option.path():
|
||||||
|
parent_option = None
|
||||||
|
break
|
||||||
|
if not parent_option:
|
||||||
|
continue
|
||||||
|
identifiers = parent_option.identifiers()
|
||||||
|
for identifier in identifiers:
|
||||||
|
dynamic_variable = dynamic_variable.replace(
|
||||||
|
"{{ identifier }}", str(identifier), 1
|
||||||
|
)
|
||||||
|
if dynamic_variable not in values and not self.config.option(dynamic_variable).get().impl_getdefault():
|
||||||
|
values[dynamic_variable] = {"values": []}
|
||||||
|
added.append(dynamic_variable)
|
||||||
|
elif dynamic_variable not in added:
|
||||||
|
continue
|
||||||
|
option_type = option.information.get("type")
|
||||||
|
typ = CONVERT_OPTION.get(option_type, {}).get("func")
|
||||||
|
if typ:
|
||||||
|
identifier = typ(identifier)
|
||||||
|
if identifier not in values[dynamic_variable]["values"]:
|
||||||
|
values[dynamic_variable]["values"].append(identifier)
|
||||||
|
cache[option.path()] = option, identifier
|
||||||
|
|
||||||
|
def _get_identifier(self, true_name, name) -> str:
|
||||||
|
if true_name == "{{ identifier }}":
|
||||||
|
return name
|
||||||
|
regexp = true_name.replace("{{ identifier }}", "(.*)")
|
||||||
|
finded = findall(regexp, name)
|
||||||
|
if len(finded) != 1 or not finded[0]:
|
||||||
|
return None
|
||||||
|
return finded[0]
|
||||||
|
|
||||||
|
|
||||||
def convert_value(option, value):
|
def convert_value(option, value):
|
||||||
if value == "":
|
if value == "":
|
||||||
return None
|
return None
|
||||||
option_type = option.information.get("type")
|
option_type = option.information.get("type")
|
||||||
if option_type == 'choice':
|
|
||||||
choices = option.value.list()
|
|
||||||
if value not in choices and isinstance(value, str):
|
|
||||||
# FIXME add other tests (boolean, float, ...)
|
|
||||||
if value.isnumeric() and int(value) in choices:
|
|
||||||
value = int(value)
|
|
||||||
func = CONVERT_OPTION.get(option_type, {}).get("func")
|
func = CONVERT_OPTION.get(option_type, {}).get("func")
|
||||||
if func:
|
if func:
|
||||||
return func(value)
|
return func(value)
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@ from tiramisu import *
|
||||||
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
||||||
from re import compile as re_compile
|
from re import compile as re_compile
|
||||||
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
||||||
load_functions('../rougail-tests/funcs/test.py')
|
load_functions('tests/dictionaries/../eosfunc/test.py')
|
||||||
try:
|
try:
|
||||||
groups.namespace
|
groups.namespace
|
||||||
except:
|
except:
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@ from tiramisu import *
|
||||||
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
||||||
from re import compile as re_compile
|
from re import compile as re_compile
|
||||||
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
||||||
load_functions('../rougail-tests/funcs/test.py')
|
load_functions('tests/dictionaries/../eosfunc/test.py')
|
||||||
try:
|
try:
|
||||||
groups.namespace
|
groups.namespace
|
||||||
except:
|
except:
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@ from tiramisu import *
|
||||||
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
||||||
from re import compile as re_compile
|
from re import compile as re_compile
|
||||||
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
||||||
load_functions('../rougail-tests/funcs/test.py')
|
load_functions('tests/dictionaries/../eosfunc/test.py')
|
||||||
ALLOWED_LEADER_PROPERTIES.add("basic")
|
ALLOWED_LEADER_PROPERTIES.add("basic")
|
||||||
ALLOWED_LEADER_PROPERTIES.add("standard")
|
ALLOWED_LEADER_PROPERTIES.add("standard")
|
||||||
ALLOWED_LEADER_PROPERTIES.add("advanced")
|
ALLOWED_LEADER_PROPERTIES.add("advanced")
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,3 @@
|
||||||
|
---
|
||||||
|
_version: '1.1'
|
||||||
|
version: # a variable
|
||||||
|
|
@ -2,7 +2,7 @@ from tiramisu import *
|
||||||
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
||||||
from re import compile as re_compile
|
from re import compile as re_compile
|
||||||
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
||||||
load_functions('../rougail-tests/funcs/test.py')
|
load_functions('tests/dictionaries/../eosfunc/test.py')
|
||||||
try:
|
try:
|
||||||
groups.namespace
|
groups.namespace
|
||||||
except:
|
except:
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@ from tiramisu import *
|
||||||
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
||||||
from re import compile as re_compile
|
from re import compile as re_compile
|
||||||
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
||||||
load_functions('../rougail-tests/funcs/test.py')
|
load_functions('tests/dictionaries/../eosfunc/test.py')
|
||||||
try:
|
try:
|
||||||
groups.namespace
|
groups.namespace
|
||||||
except:
|
except:
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@ from tiramisu import *
|
||||||
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
||||||
from re import compile as re_compile
|
from re import compile as re_compile
|
||||||
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
||||||
load_functions('../rougail-tests/funcs/test.py')
|
load_functions('tests/dictionaries/../eosfunc/test.py')
|
||||||
ALLOWED_LEADER_PROPERTIES.add("basic")
|
ALLOWED_LEADER_PROPERTIES.add("basic")
|
||||||
ALLOWED_LEADER_PROPERTIES.add("standard")
|
ALLOWED_LEADER_PROPERTIES.add("standard")
|
||||||
ALLOWED_LEADER_PROPERTIES.add("advanced")
|
ALLOWED_LEADER_PROPERTIES.add("advanced")
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,3 @@
|
||||||
|
---
|
||||||
|
version: '1.0'
|
||||||
|
empty:
|
||||||
|
|
@ -2,7 +2,7 @@ from tiramisu import *
|
||||||
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
||||||
from re import compile as re_compile
|
from re import compile as re_compile
|
||||||
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
||||||
load_functions('../rougail-tests/funcs/test.py')
|
load_functions('tests/dictionaries/../eosfunc/test.py')
|
||||||
try:
|
try:
|
||||||
groups.namespace
|
groups.namespace
|
||||||
except:
|
except:
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@ from tiramisu import *
|
||||||
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
||||||
from re import compile as re_compile
|
from re import compile as re_compile
|
||||||
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
||||||
load_functions('../rougail-tests/funcs/test.py')
|
load_functions('tests/dictionaries/../eosfunc/test.py')
|
||||||
try:
|
try:
|
||||||
groups.namespace
|
groups.namespace
|
||||||
except:
|
except:
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@ from tiramisu import *
|
||||||
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
||||||
from re import compile as re_compile
|
from re import compile as re_compile
|
||||||
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
||||||
load_functions('../rougail-tests/funcs/test.py')
|
load_functions('tests/dictionaries/../eosfunc/test.py')
|
||||||
ALLOWED_LEADER_PROPERTIES.add("basic")
|
ALLOWED_LEADER_PROPERTIES.add("basic")
|
||||||
ALLOWED_LEADER_PROPERTIES.add("standard")
|
ALLOWED_LEADER_PROPERTIES.add("standard")
|
||||||
ALLOWED_LEADER_PROPERTIES.add("advanced")
|
ALLOWED_LEADER_PROPERTIES.add("advanced")
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,10 @@
|
||||||
|
---
|
||||||
|
version: 1.1
|
||||||
|
var1: "no" # a first variable
|
||||||
|
var2:
|
||||||
|
description: a second variable
|
||||||
|
multi: true
|
||||||
|
default:
|
||||||
|
jinja: |
|
||||||
|
{{ _.var1 }}
|
||||||
|
description: the value of var1
|
||||||
|
|
@ -2,7 +2,7 @@ from tiramisu import *
|
||||||
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
||||||
from re import compile as re_compile
|
from re import compile as re_compile
|
||||||
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
||||||
load_functions('../rougail-tests/funcs/test.py')
|
load_functions('tests/dictionaries/../eosfunc/test.py')
|
||||||
try:
|
try:
|
||||||
groups.namespace
|
groups.namespace
|
||||||
except:
|
except:
|
||||||
|
|
@ -12,6 +12,6 @@ ALLOWED_LEADER_PROPERTIES.add("standard")
|
||||||
ALLOWED_LEADER_PROPERTIES.add("advanced")
|
ALLOWED_LEADER_PROPERTIES.add("advanced")
|
||||||
dict_env['default_rougail.var2'] = "{{ _.var1 }}\n"
|
dict_env['default_rougail.var2'] = "{{ _.var1 }}\n"
|
||||||
option_2 = StrOption(name="var1", doc="a first variable", default="no", properties=frozenset({"mandatory", "standard"}), informations={'type': 'string'})
|
option_2 = StrOption(name="var1", doc="a first variable", default="no", properties=frozenset({"mandatory", "standard"}), informations={'type': 'string'})
|
||||||
option_3 = StrOption(name="var2", doc="a second variable", multi=True, default=Calculation(func['jinja_to_function'], Params((), kwargs={'__internal_jinja': ParamValue("default_rougail.var2"), '__internal_type': ParamValue("string"), '__internal_multi': ParamValue(True), '__internal_files': ParamValue(['../rougail-tests/structures/00_2default_calculated/rougail/00-base.yml']), '__internal_attribute': ParamValue("default"), '__internal_variable': ParamValue("rougail.var2"), '_.var1': ParamOption(option_2, notraisepropertyerror=True)})), properties=frozenset({"mandatory", "standard"}), informations={'type': 'string'})
|
option_3 = StrOption(name="var2", doc="a second variable", multi=True, default=Calculation(func['jinja_to_function'], Params((), kwargs={'__internal_jinja': ParamValue("default_rougail.var2"), '__internal_type': ParamValue("string"), '__internal_multi': ParamValue(True), '__internal_files': ParamValue(['tests/dictionaries/00_2default_calculated/dictionaries/rougail/00-base.yml']), '__internal_attribute': ParamValue("default"), '__internal_variable': ParamValue("rougail.var2"), '_.var1': ParamOption(option_2, notraisepropertyerror=True)})), properties=frozenset({"mandatory", "standard"}), informations={'type': 'string'})
|
||||||
optiondescription_1 = OptionDescription(name="rougail", doc="Rougail", group_type=groups.namespace, children=[option_2, option_3], properties=frozenset({"standard"}))
|
optiondescription_1 = OptionDescription(name="rougail", doc="Rougail", group_type=groups.namespace, children=[option_2, option_3], properties=frozenset({"standard"}))
|
||||||
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_1])
|
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_1])
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@ from tiramisu import *
|
||||||
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
||||||
from re import compile as re_compile
|
from re import compile as re_compile
|
||||||
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
||||||
load_functions('../rougail-tests/funcs/test.py')
|
load_functions('tests/dictionaries/../eosfunc/test.py')
|
||||||
try:
|
try:
|
||||||
groups.namespace
|
groups.namespace
|
||||||
except:
|
except:
|
||||||
|
|
@ -13,11 +13,11 @@ ALLOWED_LEADER_PROPERTIES.add("advanced")
|
||||||
dict_env['default_1.rougail.var2'] = "{{ _.var1 }}\n"
|
dict_env['default_1.rougail.var2'] = "{{ _.var1 }}\n"
|
||||||
dict_env['default_2.rougail.var2'] = "{{ _.var1 }}\n"
|
dict_env['default_2.rougail.var2'] = "{{ _.var1 }}\n"
|
||||||
option_3 = StrOption(name="var1", doc="a first variable", default="no", properties=frozenset({"mandatory", "standard"}), informations={'type': 'string'})
|
option_3 = StrOption(name="var1", doc="a first variable", default="no", properties=frozenset({"mandatory", "standard"}), informations={'type': 'string'})
|
||||||
option_4 = StrOption(name="var2", doc="a second variable", multi=True, default=Calculation(func['jinja_to_function'], Params((), kwargs={'__internal_jinja': ParamValue("default_1.rougail.var2"), '__internal_type': ParamValue("string"), '__internal_multi': ParamValue(True), '__internal_files': ParamValue(['../rougail-tests/structures/00_2default_calculated/rougail/00-base.yml']), '__internal_attribute': ParamValue("default"), '__internal_variable': ParamValue("1.rougail.var2"), '_.var1': ParamOption(option_3, notraisepropertyerror=True)})), properties=frozenset({"mandatory", "standard"}), informations={'type': 'string'})
|
option_4 = StrOption(name="var2", doc="a second variable", multi=True, default=Calculation(func['jinja_to_function'], Params((), kwargs={'__internal_jinja': ParamValue("default_1.rougail.var2"), '__internal_type': ParamValue("string"), '__internal_multi': ParamValue(True), '__internal_files': ParamValue(['tests/dictionaries/00_2default_calculated/dictionaries/rougail/00-base.yml']), '__internal_attribute': ParamValue("default"), '__internal_variable': ParamValue("1.rougail.var2"), '_.var1': ParamOption(option_3, notraisepropertyerror=True)})), properties=frozenset({"mandatory", "standard"}), informations={'type': 'string'})
|
||||||
optiondescription_2 = OptionDescription(name="rougail", doc="Rougail", group_type=groups.namespace, children=[option_3, option_4], properties=frozenset({"standard"}))
|
optiondescription_2 = OptionDescription(name="rougail", doc="Rougail", group_type=groups.namespace, children=[option_3, option_4], properties=frozenset({"standard"}))
|
||||||
optiondescription_1 = OptionDescription(name="1", doc="1", children=[optiondescription_2], properties=frozenset({"standard"}))
|
optiondescription_1 = OptionDescription(name="1", doc="1", children=[optiondescription_2], properties=frozenset({"standard"}))
|
||||||
option_7 = StrOption(name="var1", doc="a first variable", default="no", properties=frozenset({"mandatory", "standard"}), informations={'type': 'string'})
|
option_7 = StrOption(name="var1", doc="a first variable", default="no", properties=frozenset({"mandatory", "standard"}), informations={'type': 'string'})
|
||||||
option_8 = StrOption(name="var2", doc="a second variable", multi=True, default=Calculation(func['jinja_to_function'], Params((), kwargs={'__internal_jinja': ParamValue("default_2.rougail.var2"), '__internal_type': ParamValue("string"), '__internal_multi': ParamValue(True), '__internal_files': ParamValue(['../rougail-tests/structures/00_2default_calculated/rougail/00-base.yml']), '__internal_attribute': ParamValue("default"), '__internal_variable': ParamValue("2.rougail.var2"), '_.var1': ParamOption(option_7, notraisepropertyerror=True)})), properties=frozenset({"mandatory", "standard"}), informations={'type': 'string'})
|
option_8 = StrOption(name="var2", doc="a second variable", multi=True, default=Calculation(func['jinja_to_function'], Params((), kwargs={'__internal_jinja': ParamValue("default_2.rougail.var2"), '__internal_type': ParamValue("string"), '__internal_multi': ParamValue(True), '__internal_files': ParamValue(['tests/dictionaries/00_2default_calculated/dictionaries/rougail/00-base.yml']), '__internal_attribute': ParamValue("default"), '__internal_variable': ParamValue("2.rougail.var2"), '_.var1': ParamOption(option_7, notraisepropertyerror=True)})), properties=frozenset({"mandatory", "standard"}), informations={'type': 'string'})
|
||||||
optiondescription_6 = OptionDescription(name="rougail", doc="Rougail", group_type=groups.namespace, children=[option_7, option_8], properties=frozenset({"standard"}))
|
optiondescription_6 = OptionDescription(name="rougail", doc="Rougail", group_type=groups.namespace, children=[option_7, option_8], properties=frozenset({"standard"}))
|
||||||
optiondescription_5 = OptionDescription(name="2", doc="2", children=[optiondescription_6], properties=frozenset({"standard"}))
|
optiondescription_5 = OptionDescription(name="2", doc="2", children=[optiondescription_6], properties=frozenset({"standard"}))
|
||||||
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_1, optiondescription_5])
|
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_1, optiondescription_5])
|
||||||
|
|
|
||||||
|
|
@ -2,11 +2,11 @@ from tiramisu import *
|
||||||
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
||||||
from re import compile as re_compile
|
from re import compile as re_compile
|
||||||
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
||||||
load_functions('../rougail-tests/funcs/test.py')
|
load_functions('tests/dictionaries/../eosfunc/test.py')
|
||||||
ALLOWED_LEADER_PROPERTIES.add("basic")
|
ALLOWED_LEADER_PROPERTIES.add("basic")
|
||||||
ALLOWED_LEADER_PROPERTIES.add("standard")
|
ALLOWED_LEADER_PROPERTIES.add("standard")
|
||||||
ALLOWED_LEADER_PROPERTIES.add("advanced")
|
ALLOWED_LEADER_PROPERTIES.add("advanced")
|
||||||
dict_env['default_var2'] = "{{ _.var1 }}\n"
|
dict_env['default_var2'] = "{{ _.var1 }}\n"
|
||||||
option_1 = StrOption(name="var1", doc="a first variable", default="no", properties=frozenset({"mandatory", "standard"}), informations={'type': 'string'})
|
option_1 = StrOption(name="var1", doc="a first variable", default="no", properties=frozenset({"mandatory", "standard"}), informations={'type': 'string'})
|
||||||
option_2 = StrOption(name="var2", doc="a second variable", multi=True, default=Calculation(func['jinja_to_function'], Params((), kwargs={'__internal_jinja': ParamValue("default_var2"), '__internal_type': ParamValue("string"), '__internal_multi': ParamValue(True), '__internal_files': ParamValue(['../rougail-tests/structures/00_2default_calculated/rougail/00-base.yml']), '__internal_attribute': ParamValue("default"), '__internal_variable': ParamValue("var2"), '_.var1': ParamOption(option_1, notraisepropertyerror=True)})), properties=frozenset({"mandatory", "standard"}), informations={'type': 'string'})
|
option_2 = StrOption(name="var2", doc="a second variable", multi=True, default=Calculation(func['jinja_to_function'], Params((), kwargs={'__internal_jinja': ParamValue("default_var2"), '__internal_type': ParamValue("string"), '__internal_multi': ParamValue(True), '__internal_files': ParamValue(['tests/dictionaries/00_2default_calculated/dictionaries/rougail/00-base.yml']), '__internal_attribute': ParamValue("default"), '__internal_variable': ParamValue("var2"), '_.var1': ParamOption(option_1, notraisepropertyerror=True)})), properties=frozenset({"mandatory", "standard"}), informations={'type': 'string'})
|
||||||
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[option_1, option_2])
|
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[option_1, option_2])
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,15 @@
|
||||||
|
---
|
||||||
|
version: 1.1
|
||||||
|
var1: # a first variable
|
||||||
|
- 'no'
|
||||||
|
- 'yes'
|
||||||
|
- maybe
|
||||||
|
var2:
|
||||||
|
description: a second variable
|
||||||
|
multi: true
|
||||||
|
default:
|
||||||
|
jinja: |
|
||||||
|
{% for val in _.var1 %}
|
||||||
|
{{ val }}
|
||||||
|
{% endfor %}
|
||||||
|
description: the value of _.var1
|
||||||
|
|
@ -2,7 +2,7 @@ from tiramisu import *
|
||||||
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
||||||
from re import compile as re_compile
|
from re import compile as re_compile
|
||||||
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
||||||
load_functions('../rougail-tests/funcs/test.py')
|
load_functions('tests/dictionaries/../eosfunc/test.py')
|
||||||
try:
|
try:
|
||||||
groups.namespace
|
groups.namespace
|
||||||
except:
|
except:
|
||||||
|
|
@ -12,6 +12,6 @@ ALLOWED_LEADER_PROPERTIES.add("standard")
|
||||||
ALLOWED_LEADER_PROPERTIES.add("advanced")
|
ALLOWED_LEADER_PROPERTIES.add("advanced")
|
||||||
dict_env['default_rougail.var2'] = "{% for val in _.var1 %}\n{{ val }}\n{% endfor %}\n"
|
dict_env['default_rougail.var2'] = "{% for val in _.var1 %}\n{{ val }}\n{% endfor %}\n"
|
||||||
option_2 = StrOption(name="var1", doc="a first variable", multi=True, default=["no", "yes", "maybe"], default_multi="no", properties=frozenset({"mandatory", "standard"}), informations={'type': 'string'})
|
option_2 = StrOption(name="var1", doc="a first variable", multi=True, default=["no", "yes", "maybe"], default_multi="no", properties=frozenset({"mandatory", "standard"}), informations={'type': 'string'})
|
||||||
option_3 = StrOption(name="var2", doc="a second variable", multi=True, default=Calculation(func['jinja_to_function'], Params((), kwargs={'__internal_jinja': ParamValue("default_rougail.var2"), '__internal_type': ParamValue("string"), '__internal_multi': ParamValue(True), '__internal_files': ParamValue(['../rougail-tests/structures/00_2default_calculated_multi/rougail/00-base.yml']), '__internal_attribute': ParamValue("default"), '__internal_variable': ParamValue("rougail.var2"), '_.var1': ParamOption(option_2, notraisepropertyerror=True)})), properties=frozenset({"mandatory", "standard"}), informations={'type': 'string'})
|
option_3 = StrOption(name="var2", doc="a second variable", multi=True, default=Calculation(func['jinja_to_function'], Params((), kwargs={'__internal_jinja': ParamValue("default_rougail.var2"), '__internal_type': ParamValue("string"), '__internal_multi': ParamValue(True), '__internal_files': ParamValue(['tests/dictionaries/00_2default_calculated_multi/dictionaries/rougail/00-base.yml']), '__internal_attribute': ParamValue("default"), '__internal_variable': ParamValue("rougail.var2"), '_.var1': ParamOption(option_2, notraisepropertyerror=True)})), properties=frozenset({"mandatory", "standard"}), informations={'type': 'string'})
|
||||||
optiondescription_1 = OptionDescription(name="rougail", doc="Rougail", group_type=groups.namespace, children=[option_2, option_3], properties=frozenset({"standard"}))
|
optiondescription_1 = OptionDescription(name="rougail", doc="Rougail", group_type=groups.namespace, children=[option_2, option_3], properties=frozenset({"standard"}))
|
||||||
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_1])
|
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_1])
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@ from tiramisu import *
|
||||||
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
||||||
from re import compile as re_compile
|
from re import compile as re_compile
|
||||||
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
||||||
load_functions('../rougail-tests/funcs/test.py')
|
load_functions('tests/dictionaries/../eosfunc/test.py')
|
||||||
try:
|
try:
|
||||||
groups.namespace
|
groups.namespace
|
||||||
except:
|
except:
|
||||||
|
|
@ -13,11 +13,11 @@ ALLOWED_LEADER_PROPERTIES.add("advanced")
|
||||||
dict_env['default_1.rougail.var2'] = "{% for val in _.var1 %}\n{{ val }}\n{% endfor %}\n"
|
dict_env['default_1.rougail.var2'] = "{% for val in _.var1 %}\n{{ val }}\n{% endfor %}\n"
|
||||||
dict_env['default_2.rougail.var2'] = "{% for val in _.var1 %}\n{{ val }}\n{% endfor %}\n"
|
dict_env['default_2.rougail.var2'] = "{% for val in _.var1 %}\n{{ val }}\n{% endfor %}\n"
|
||||||
option_3 = StrOption(name="var1", doc="a first variable", multi=True, default=["no", "yes", "maybe"], default_multi="no", properties=frozenset({"mandatory", "standard"}), informations={'type': 'string'})
|
option_3 = StrOption(name="var1", doc="a first variable", multi=True, default=["no", "yes", "maybe"], default_multi="no", properties=frozenset({"mandatory", "standard"}), informations={'type': 'string'})
|
||||||
option_4 = StrOption(name="var2", doc="a second variable", multi=True, default=Calculation(func['jinja_to_function'], Params((), kwargs={'__internal_jinja': ParamValue("default_1.rougail.var2"), '__internal_type': ParamValue("string"), '__internal_multi': ParamValue(True), '__internal_files': ParamValue(['../rougail-tests/structures/00_2default_calculated_multi/rougail/00-base.yml']), '__internal_attribute': ParamValue("default"), '__internal_variable': ParamValue("1.rougail.var2"), '_.var1': ParamOption(option_3, notraisepropertyerror=True)})), properties=frozenset({"mandatory", "standard"}), informations={'type': 'string'})
|
option_4 = StrOption(name="var2", doc="a second variable", multi=True, default=Calculation(func['jinja_to_function'], Params((), kwargs={'__internal_jinja': ParamValue("default_1.rougail.var2"), '__internal_type': ParamValue("string"), '__internal_multi': ParamValue(True), '__internal_files': ParamValue(['tests/dictionaries/00_2default_calculated_multi/dictionaries/rougail/00-base.yml']), '__internal_attribute': ParamValue("default"), '__internal_variable': ParamValue("1.rougail.var2"), '_.var1': ParamOption(option_3, notraisepropertyerror=True)})), properties=frozenset({"mandatory", "standard"}), informations={'type': 'string'})
|
||||||
optiondescription_2 = OptionDescription(name="rougail", doc="Rougail", group_type=groups.namespace, children=[option_3, option_4], properties=frozenset({"standard"}))
|
optiondescription_2 = OptionDescription(name="rougail", doc="Rougail", group_type=groups.namespace, children=[option_3, option_4], properties=frozenset({"standard"}))
|
||||||
optiondescription_1 = OptionDescription(name="1", doc="1", children=[optiondescription_2], properties=frozenset({"standard"}))
|
optiondescription_1 = OptionDescription(name="1", doc="1", children=[optiondescription_2], properties=frozenset({"standard"}))
|
||||||
option_7 = StrOption(name="var1", doc="a first variable", multi=True, default=["no", "yes", "maybe"], default_multi="no", properties=frozenset({"mandatory", "standard"}), informations={'type': 'string'})
|
option_7 = StrOption(name="var1", doc="a first variable", multi=True, default=["no", "yes", "maybe"], default_multi="no", properties=frozenset({"mandatory", "standard"}), informations={'type': 'string'})
|
||||||
option_8 = StrOption(name="var2", doc="a second variable", multi=True, default=Calculation(func['jinja_to_function'], Params((), kwargs={'__internal_jinja': ParamValue("default_2.rougail.var2"), '__internal_type': ParamValue("string"), '__internal_multi': ParamValue(True), '__internal_files': ParamValue(['../rougail-tests/structures/00_2default_calculated_multi/rougail/00-base.yml']), '__internal_attribute': ParamValue("default"), '__internal_variable': ParamValue("2.rougail.var2"), '_.var1': ParamOption(option_7, notraisepropertyerror=True)})), properties=frozenset({"mandatory", "standard"}), informations={'type': 'string'})
|
option_8 = StrOption(name="var2", doc="a second variable", multi=True, default=Calculation(func['jinja_to_function'], Params((), kwargs={'__internal_jinja': ParamValue("default_2.rougail.var2"), '__internal_type': ParamValue("string"), '__internal_multi': ParamValue(True), '__internal_files': ParamValue(['tests/dictionaries/00_2default_calculated_multi/dictionaries/rougail/00-base.yml']), '__internal_attribute': ParamValue("default"), '__internal_variable': ParamValue("2.rougail.var2"), '_.var1': ParamOption(option_7, notraisepropertyerror=True)})), properties=frozenset({"mandatory", "standard"}), informations={'type': 'string'})
|
||||||
optiondescription_6 = OptionDescription(name="rougail", doc="Rougail", group_type=groups.namespace, children=[option_7, option_8], properties=frozenset({"standard"}))
|
optiondescription_6 = OptionDescription(name="rougail", doc="Rougail", group_type=groups.namespace, children=[option_7, option_8], properties=frozenset({"standard"}))
|
||||||
optiondescription_5 = OptionDescription(name="2", doc="2", children=[optiondescription_6], properties=frozenset({"standard"}))
|
optiondescription_5 = OptionDescription(name="2", doc="2", children=[optiondescription_6], properties=frozenset({"standard"}))
|
||||||
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_1, optiondescription_5])
|
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_1, optiondescription_5])
|
||||||
|
|
|
||||||
|
|
@ -2,11 +2,11 @@ from tiramisu import *
|
||||||
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
||||||
from re import compile as re_compile
|
from re import compile as re_compile
|
||||||
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
||||||
load_functions('../rougail-tests/funcs/test.py')
|
load_functions('tests/dictionaries/../eosfunc/test.py')
|
||||||
ALLOWED_LEADER_PROPERTIES.add("basic")
|
ALLOWED_LEADER_PROPERTIES.add("basic")
|
||||||
ALLOWED_LEADER_PROPERTIES.add("standard")
|
ALLOWED_LEADER_PROPERTIES.add("standard")
|
||||||
ALLOWED_LEADER_PROPERTIES.add("advanced")
|
ALLOWED_LEADER_PROPERTIES.add("advanced")
|
||||||
dict_env['default_var2'] = "{% for val in _.var1 %}\n{{ val }}\n{% endfor %}\n"
|
dict_env['default_var2'] = "{% for val in _.var1 %}\n{{ val }}\n{% endfor %}\n"
|
||||||
option_1 = StrOption(name="var1", doc="a first variable", multi=True, default=["no", "yes", "maybe"], default_multi="no", properties=frozenset({"mandatory", "standard"}), informations={'type': 'string'})
|
option_1 = StrOption(name="var1", doc="a first variable", multi=True, default=["no", "yes", "maybe"], default_multi="no", properties=frozenset({"mandatory", "standard"}), informations={'type': 'string'})
|
||||||
option_2 = StrOption(name="var2", doc="a second variable", multi=True, default=Calculation(func['jinja_to_function'], Params((), kwargs={'__internal_jinja': ParamValue("default_var2"), '__internal_type': ParamValue("string"), '__internal_multi': ParamValue(True), '__internal_files': ParamValue(['../rougail-tests/structures/00_2default_calculated_multi/rougail/00-base.yml']), '__internal_attribute': ParamValue("default"), '__internal_variable': ParamValue("var2"), '_.var1': ParamOption(option_1, notraisepropertyerror=True)})), properties=frozenset({"mandatory", "standard"}), informations={'type': 'string'})
|
option_2 = StrOption(name="var2", doc="a second variable", multi=True, default=Calculation(func['jinja_to_function'], Params((), kwargs={'__internal_jinja': ParamValue("default_var2"), '__internal_type': ParamValue("string"), '__internal_multi': ParamValue(True), '__internal_files': ParamValue(['tests/dictionaries/00_2default_calculated_multi/dictionaries/rougail/00-base.yml']), '__internal_attribute': ParamValue("default"), '__internal_variable': ParamValue("var2"), '_.var1': ParamOption(option_1, notraisepropertyerror=True)})), properties=frozenset({"mandatory", "standard"}), informations={'type': 'string'})
|
||||||
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[option_1, option_2])
|
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[option_1, option_2])
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,15 @@
|
||||||
|
---
|
||||||
|
version: 1.1
|
||||||
|
|
||||||
|
var1:
|
||||||
|
description: a first variable
|
||||||
|
multi: true
|
||||||
|
type: domainname
|
||||||
|
params:
|
||||||
|
allow_ip: true
|
||||||
|
|
||||||
|
var2:
|
||||||
|
description: a second variable
|
||||||
|
default:
|
||||||
|
type: variable
|
||||||
|
variable: _.var1
|
||||||
|
|
@ -2,7 +2,7 @@ from tiramisu import *
|
||||||
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
||||||
from re import compile as re_compile
|
from re import compile as re_compile
|
||||||
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
||||||
load_functions('../rougail-tests/funcs/test.py')
|
load_functions('tests/dictionaries/../eosfunc/test.py')
|
||||||
try:
|
try:
|
||||||
groups.namespace
|
groups.namespace
|
||||||
except:
|
except:
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@ from tiramisu import *
|
||||||
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
||||||
from re import compile as re_compile
|
from re import compile as re_compile
|
||||||
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
||||||
load_functions('../rougail-tests/funcs/test.py')
|
load_functions('tests/dictionaries/../eosfunc/test.py')
|
||||||
try:
|
try:
|
||||||
groups.namespace
|
groups.namespace
|
||||||
except:
|
except:
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@ from tiramisu import *
|
||||||
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
||||||
from re import compile as re_compile
|
from re import compile as re_compile
|
||||||
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
||||||
load_functions('../rougail-tests/funcs/test.py')
|
load_functions('tests/dictionaries/../eosfunc/test.py')
|
||||||
ALLOWED_LEADER_PROPERTIES.add("basic")
|
ALLOWED_LEADER_PROPERTIES.add("basic")
|
||||||
ALLOWED_LEADER_PROPERTIES.add("standard")
|
ALLOWED_LEADER_PROPERTIES.add("standard")
|
||||||
ALLOWED_LEADER_PROPERTIES.add("advanced")
|
ALLOWED_LEADER_PROPERTIES.add("advanced")
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,4 @@
|
||||||
|
---
|
||||||
|
version: '1.0'
|
||||||
|
var1:
|
||||||
|
description: a variable
|
||||||
|
|
@ -0,0 +1,4 @@
|
||||||
|
---
|
||||||
|
version: "1.0"
|
||||||
|
var2:
|
||||||
|
description: a variable
|
||||||
|
|
@ -2,7 +2,7 @@ from tiramisu import *
|
||||||
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
||||||
from re import compile as re_compile
|
from re import compile as re_compile
|
||||||
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
||||||
load_functions('../rougail-tests/funcs/test.py')
|
load_functions('tests/dictionaries/../eosfunc/test.py')
|
||||||
try:
|
try:
|
||||||
groups.namespace
|
groups.namespace
|
||||||
except:
|
except:
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@ from tiramisu import *
|
||||||
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
||||||
from re import compile as re_compile
|
from re import compile as re_compile
|
||||||
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
||||||
load_functions('../rougail-tests/funcs/test.py')
|
load_functions('tests/dictionaries/../eosfunc/test.py')
|
||||||
try:
|
try:
|
||||||
groups.namespace
|
groups.namespace
|
||||||
except:
|
except:
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@ from tiramisu import *
|
||||||
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
||||||
from re import compile as re_compile
|
from re import compile as re_compile
|
||||||
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
||||||
load_functions('../rougail-tests/funcs/test.py')
|
load_functions('tests/dictionaries/../eosfunc/test.py')
|
||||||
ALLOWED_LEADER_PROPERTIES.add("basic")
|
ALLOWED_LEADER_PROPERTIES.add("basic")
|
||||||
ALLOWED_LEADER_PROPERTIES.add("standard")
|
ALLOWED_LEADER_PROPERTIES.add("standard")
|
||||||
ALLOWED_LEADER_PROPERTIES.add("advanced")
|
ALLOWED_LEADER_PROPERTIES.add("advanced")
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,5 @@
|
||||||
|
---
|
||||||
|
version: '1.0'
|
||||||
|
without_type:
|
||||||
|
description: a variable
|
||||||
|
default: non
|
||||||
|
|
@ -2,7 +2,7 @@ from tiramisu import *
|
||||||
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
||||||
from re import compile as re_compile
|
from re import compile as re_compile
|
||||||
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
||||||
load_functions('../rougail-tests/funcs/test.py')
|
load_functions('tests/dictionaries/../eosfunc/test.py')
|
||||||
try:
|
try:
|
||||||
groups.namespace
|
groups.namespace
|
||||||
except:
|
except:
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@ from tiramisu import *
|
||||||
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
||||||
from re import compile as re_compile
|
from re import compile as re_compile
|
||||||
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
||||||
load_functions('../rougail-tests/funcs/test.py')
|
load_functions('tests/dictionaries/../eosfunc/test.py')
|
||||||
try:
|
try:
|
||||||
groups.namespace
|
groups.namespace
|
||||||
except:
|
except:
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@ from tiramisu import *
|
||||||
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
||||||
from re import compile as re_compile
|
from re import compile as re_compile
|
||||||
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
||||||
load_functions('../rougail-tests/funcs/test.py')
|
load_functions('tests/dictionaries/../eosfunc/test.py')
|
||||||
ALLOWED_LEADER_PROPERTIES.add("basic")
|
ALLOWED_LEADER_PROPERTIES.add("basic")
|
||||||
ALLOWED_LEADER_PROPERTIES.add("standard")
|
ALLOWED_LEADER_PROPERTIES.add("standard")
|
||||||
ALLOWED_LEADER_PROPERTIES.add("advanced")
|
ALLOWED_LEADER_PROPERTIES.add("advanced")
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,18 @@
|
||||||
|
---
|
||||||
|
version: '1.1'
|
||||||
|
var1: true # the first variable
|
||||||
|
var2:
|
||||||
|
description: the second variable
|
||||||
|
default: true
|
||||||
|
var3:
|
||||||
|
description: the third variable
|
||||||
|
type: boolean
|
||||||
|
default: true
|
||||||
|
var4: false # the forth variable
|
||||||
|
var5:
|
||||||
|
description: the fifth variable
|
||||||
|
default: false
|
||||||
|
var6:
|
||||||
|
description: the sixth variable
|
||||||
|
type: boolean
|
||||||
|
default: false
|
||||||
|
|
@ -2,7 +2,7 @@ from tiramisu import *
|
||||||
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
||||||
from re import compile as re_compile
|
from re import compile as re_compile
|
||||||
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
||||||
load_functions('../rougail-tests/funcs/test.py')
|
load_functions('tests/dictionaries/../eosfunc/test.py')
|
||||||
try:
|
try:
|
||||||
groups.namespace
|
groups.namespace
|
||||||
except:
|
except:
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@ from tiramisu import *
|
||||||
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
||||||
from re import compile as re_compile
|
from re import compile as re_compile
|
||||||
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
||||||
load_functions('../rougail-tests/funcs/test.py')
|
load_functions('tests/dictionaries/../eosfunc/test.py')
|
||||||
try:
|
try:
|
||||||
groups.namespace
|
groups.namespace
|
||||||
except:
|
except:
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@ from tiramisu import *
|
||||||
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
||||||
from re import compile as re_compile
|
from re import compile as re_compile
|
||||||
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
||||||
load_functions('../rougail-tests/funcs/test.py')
|
load_functions('tests/dictionaries/../eosfunc/test.py')
|
||||||
ALLOWED_LEADER_PROPERTIES.add("basic")
|
ALLOWED_LEADER_PROPERTIES.add("basic")
|
||||||
ALLOWED_LEADER_PROPERTIES.add("standard")
|
ALLOWED_LEADER_PROPERTIES.add("standard")
|
||||||
ALLOWED_LEADER_PROPERTIES.add("advanced")
|
ALLOWED_LEADER_PROPERTIES.add("advanced")
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,6 @@
|
||||||
|
---
|
||||||
|
version: '1.1'
|
||||||
|
variable:
|
||||||
|
description: a variable
|
||||||
|
type: boolean
|
||||||
|
mandatory: false
|
||||||
|
|
@ -2,7 +2,7 @@ from tiramisu import *
|
||||||
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
||||||
from re import compile as re_compile
|
from re import compile as re_compile
|
||||||
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
||||||
load_functions('../rougail-tests/funcs/test.py')
|
load_functions('tests/dictionaries/../eosfunc/test.py')
|
||||||
try:
|
try:
|
||||||
groups.namespace
|
groups.namespace
|
||||||
except:
|
except:
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@ from tiramisu import *
|
||||||
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
||||||
from re import compile as re_compile
|
from re import compile as re_compile
|
||||||
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
||||||
load_functions('../rougail-tests/funcs/test.py')
|
load_functions('tests/dictionaries/../eosfunc/test.py')
|
||||||
try:
|
try:
|
||||||
groups.namespace
|
groups.namespace
|
||||||
except:
|
except:
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@ from tiramisu import *
|
||||||
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
||||||
from re import compile as re_compile
|
from re import compile as re_compile
|
||||||
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
||||||
load_functions('../rougail-tests/funcs/test.py')
|
load_functions('tests/dictionaries/../eosfunc/test.py')
|
||||||
ALLOWED_LEADER_PROPERTIES.add("basic")
|
ALLOWED_LEADER_PROPERTIES.add("basic")
|
||||||
ALLOWED_LEADER_PROPERTIES.add("standard")
|
ALLOWED_LEADER_PROPERTIES.add("standard")
|
||||||
ALLOWED_LEADER_PROPERTIES.add("advanced")
|
ALLOWED_LEADER_PROPERTIES.add("advanced")
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,42 @@
|
||||||
|
---
|
||||||
|
version: '1.1'
|
||||||
|
var1:
|
||||||
|
description: the first variable
|
||||||
|
choices:
|
||||||
|
- a
|
||||||
|
- b
|
||||||
|
- c
|
||||||
|
var2:
|
||||||
|
description: the second variable
|
||||||
|
choices:
|
||||||
|
- a
|
||||||
|
- b
|
||||||
|
- c
|
||||||
|
var3:
|
||||||
|
description: the third variable
|
||||||
|
choices:
|
||||||
|
- a
|
||||||
|
- b
|
||||||
|
- c
|
||||||
|
mandatory: false
|
||||||
|
var4:
|
||||||
|
description: the forth variable
|
||||||
|
choices:
|
||||||
|
- null
|
||||||
|
- b
|
||||||
|
- c
|
||||||
|
mandatory: false
|
||||||
|
var5:
|
||||||
|
description: the fifth variable
|
||||||
|
choices:
|
||||||
|
- a
|
||||||
|
- b
|
||||||
|
- c
|
||||||
|
default: a
|
||||||
|
var6:
|
||||||
|
description: the sixth variable
|
||||||
|
choices:
|
||||||
|
- 1
|
||||||
|
- 2
|
||||||
|
- 3
|
||||||
|
default: 1
|
||||||
|
|
@ -2,7 +2,7 @@ from tiramisu import *
|
||||||
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
||||||
from re import compile as re_compile
|
from re import compile as re_compile
|
||||||
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
||||||
load_functions('../rougail-tests/funcs/test.py')
|
load_functions('tests/dictionaries/../eosfunc/test.py')
|
||||||
try:
|
try:
|
||||||
groups.namespace
|
groups.namespace
|
||||||
except:
|
except:
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@ from tiramisu import *
|
||||||
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
||||||
from re import compile as re_compile
|
from re import compile as re_compile
|
||||||
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
||||||
load_functions('../rougail-tests/funcs/test.py')
|
load_functions('tests/dictionaries/../eosfunc/test.py')
|
||||||
try:
|
try:
|
||||||
groups.namespace
|
groups.namespace
|
||||||
except:
|
except:
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@ from tiramisu import *
|
||||||
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
||||||
from re import compile as re_compile
|
from re import compile as re_compile
|
||||||
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
||||||
load_functions('../rougail-tests/funcs/test.py')
|
load_functions('tests/dictionaries/../eosfunc/test.py')
|
||||||
ALLOWED_LEADER_PROPERTIES.add("basic")
|
ALLOWED_LEADER_PROPERTIES.add("basic")
|
||||||
ALLOWED_LEADER_PROPERTIES.add("standard")
|
ALLOWED_LEADER_PROPERTIES.add("standard")
|
||||||
ALLOWED_LEADER_PROPERTIES.add("advanced")
|
ALLOWED_LEADER_PROPERTIES.add("advanced")
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,12 @@
|
||||||
|
---
|
||||||
|
version: 1.1
|
||||||
|
var:
|
||||||
|
description: a variable
|
||||||
|
default: 9
|
||||||
|
choices:
|
||||||
|
jinja: |
|
||||||
|
{% for n in trange(0, 10) %}
|
||||||
|
{{ n }}
|
||||||
|
{% endfor %}
|
||||||
|
return_type: 'number'
|
||||||
|
description: choices is 0 to 9
|
||||||
|
|
@ -2,7 +2,7 @@ from tiramisu import *
|
||||||
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
||||||
from re import compile as re_compile
|
from re import compile as re_compile
|
||||||
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
||||||
load_functions('../rougail-tests/funcs/test.py')
|
load_functions('tests/dictionaries/../eosfunc/test.py')
|
||||||
try:
|
try:
|
||||||
groups.namespace
|
groups.namespace
|
||||||
except:
|
except:
|
||||||
|
|
@ -11,6 +11,6 @@ ALLOWED_LEADER_PROPERTIES.add("basic")
|
||||||
ALLOWED_LEADER_PROPERTIES.add("standard")
|
ALLOWED_LEADER_PROPERTIES.add("standard")
|
||||||
ALLOWED_LEADER_PROPERTIES.add("advanced")
|
ALLOWED_LEADER_PROPERTIES.add("advanced")
|
||||||
dict_env['choices_rougail.var'] = "{% for n in trange(0, 10) %}\n{{ n }}\n{% endfor %}\n"
|
dict_env['choices_rougail.var'] = "{% for n in trange(0, 10) %}\n{{ n }}\n{% endfor %}\n"
|
||||||
option_2 = ChoiceOption(name="var", doc="a variable", values=Calculation(func['jinja_to_function'], Params((), kwargs={'__internal_jinja': ParamValue("choices_rougail.var"), '__internal_type': ParamValue("number"), '__internal_multi': ParamValue(True), '__internal_files': ParamValue(['../rougail-tests/structures/00_6choice_calculation/rougail/00-base.yml']), '__internal_attribute': ParamValue("choices"), '__internal_variable': ParamValue("rougail.var")})), default=9, properties=frozenset({"mandatory", "standard"}), informations={'type': 'choice'})
|
option_2 = ChoiceOption(name="var", doc="a variable", values=Calculation(func['jinja_to_function'], Params((), kwargs={'__internal_jinja': ParamValue("choices_rougail.var"), '__internal_type': ParamValue("number"), '__internal_multi': ParamValue(True), '__internal_files': ParamValue(['tests/dictionaries/00_6choice_calculation/dictionaries/rougail/00-base.yml']), '__internal_attribute': ParamValue("choices"), '__internal_variable': ParamValue("rougail.var")})), default=9, properties=frozenset({"mandatory", "standard"}), informations={'type': 'choice'})
|
||||||
optiondescription_1 = OptionDescription(name="rougail", doc="Rougail", group_type=groups.namespace, children=[option_2], properties=frozenset({"standard"}))
|
optiondescription_1 = OptionDescription(name="rougail", doc="Rougail", group_type=groups.namespace, children=[option_2], properties=frozenset({"standard"}))
|
||||||
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_1])
|
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_1])
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@ from tiramisu import *
|
||||||
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
||||||
from re import compile as re_compile
|
from re import compile as re_compile
|
||||||
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
||||||
load_functions('../rougail-tests/funcs/test.py')
|
load_functions('tests/dictionaries/../eosfunc/test.py')
|
||||||
try:
|
try:
|
||||||
groups.namespace
|
groups.namespace
|
||||||
except:
|
except:
|
||||||
|
|
@ -12,10 +12,10 @@ ALLOWED_LEADER_PROPERTIES.add("standard")
|
||||||
ALLOWED_LEADER_PROPERTIES.add("advanced")
|
ALLOWED_LEADER_PROPERTIES.add("advanced")
|
||||||
dict_env['choices_1.rougail.var'] = "{% for n in trange(0, 10) %}\n{{ n }}\n{% endfor %}\n"
|
dict_env['choices_1.rougail.var'] = "{% for n in trange(0, 10) %}\n{{ n }}\n{% endfor %}\n"
|
||||||
dict_env['choices_2.rougail.var'] = "{% for n in trange(0, 10) %}\n{{ n }}\n{% endfor %}\n"
|
dict_env['choices_2.rougail.var'] = "{% for n in trange(0, 10) %}\n{{ n }}\n{% endfor %}\n"
|
||||||
option_3 = ChoiceOption(name="var", doc="a variable", values=Calculation(func['jinja_to_function'], Params((), kwargs={'__internal_jinja': ParamValue("choices_1.rougail.var"), '__internal_type': ParamValue("number"), '__internal_multi': ParamValue(True), '__internal_files': ParamValue(['../rougail-tests/structures/00_6choice_calculation/rougail/00-base.yml']), '__internal_attribute': ParamValue("choices"), '__internal_variable': ParamValue("1.rougail.var")})), default=9, properties=frozenset({"mandatory", "standard"}), informations={'type': 'choice'})
|
option_3 = ChoiceOption(name="var", doc="a variable", values=Calculation(func['jinja_to_function'], Params((), kwargs={'__internal_jinja': ParamValue("choices_1.rougail.var"), '__internal_type': ParamValue("number"), '__internal_multi': ParamValue(True), '__internal_files': ParamValue(['tests/dictionaries/00_6choice_calculation/dictionaries/rougail/00-base.yml']), '__internal_attribute': ParamValue("choices"), '__internal_variable': ParamValue("1.rougail.var")})), default=9, properties=frozenset({"mandatory", "standard"}), informations={'type': 'choice'})
|
||||||
optiondescription_2 = OptionDescription(name="rougail", doc="Rougail", group_type=groups.namespace, children=[option_3], properties=frozenset({"standard"}))
|
optiondescription_2 = OptionDescription(name="rougail", doc="Rougail", group_type=groups.namespace, children=[option_3], properties=frozenset({"standard"}))
|
||||||
optiondescription_1 = OptionDescription(name="1", doc="1", children=[optiondescription_2], properties=frozenset({"standard"}))
|
optiondescription_1 = OptionDescription(name="1", doc="1", children=[optiondescription_2], properties=frozenset({"standard"}))
|
||||||
option_6 = ChoiceOption(name="var", doc="a variable", values=Calculation(func['jinja_to_function'], Params((), kwargs={'__internal_jinja': ParamValue("choices_2.rougail.var"), '__internal_type': ParamValue("number"), '__internal_multi': ParamValue(True), '__internal_files': ParamValue(['../rougail-tests/structures/00_6choice_calculation/rougail/00-base.yml']), '__internal_attribute': ParamValue("choices"), '__internal_variable': ParamValue("2.rougail.var")})), default=9, properties=frozenset({"mandatory", "standard"}), informations={'type': 'choice'})
|
option_6 = ChoiceOption(name="var", doc="a variable", values=Calculation(func['jinja_to_function'], Params((), kwargs={'__internal_jinja': ParamValue("choices_2.rougail.var"), '__internal_type': ParamValue("number"), '__internal_multi': ParamValue(True), '__internal_files': ParamValue(['tests/dictionaries/00_6choice_calculation/dictionaries/rougail/00-base.yml']), '__internal_attribute': ParamValue("choices"), '__internal_variable': ParamValue("2.rougail.var")})), default=9, properties=frozenset({"mandatory", "standard"}), informations={'type': 'choice'})
|
||||||
optiondescription_5 = OptionDescription(name="rougail", doc="Rougail", group_type=groups.namespace, children=[option_6], properties=frozenset({"standard"}))
|
optiondescription_5 = OptionDescription(name="rougail", doc="Rougail", group_type=groups.namespace, children=[option_6], properties=frozenset({"standard"}))
|
||||||
optiondescription_4 = OptionDescription(name="2", doc="2", children=[optiondescription_5], properties=frozenset({"standard"}))
|
optiondescription_4 = OptionDescription(name="2", doc="2", children=[optiondescription_5], properties=frozenset({"standard"}))
|
||||||
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_1, optiondescription_4])
|
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_1, optiondescription_4])
|
||||||
|
|
|
||||||
|
|
@ -2,10 +2,10 @@ from tiramisu import *
|
||||||
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
||||||
from re import compile as re_compile
|
from re import compile as re_compile
|
||||||
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
||||||
load_functions('../rougail-tests/funcs/test.py')
|
load_functions('tests/dictionaries/../eosfunc/test.py')
|
||||||
ALLOWED_LEADER_PROPERTIES.add("basic")
|
ALLOWED_LEADER_PROPERTIES.add("basic")
|
||||||
ALLOWED_LEADER_PROPERTIES.add("standard")
|
ALLOWED_LEADER_PROPERTIES.add("standard")
|
||||||
ALLOWED_LEADER_PROPERTIES.add("advanced")
|
ALLOWED_LEADER_PROPERTIES.add("advanced")
|
||||||
dict_env['choices_var'] = "{% for n in trange(0, 10) %}\n{{ n }}\n{% endfor %}\n"
|
dict_env['choices_var'] = "{% for n in trange(0, 10) %}\n{{ n }}\n{% endfor %}\n"
|
||||||
option_1 = ChoiceOption(name="var", doc="a variable", values=Calculation(func['jinja_to_function'], Params((), kwargs={'__internal_jinja': ParamValue("choices_var"), '__internal_type': ParamValue("number"), '__internal_multi': ParamValue(True), '__internal_files': ParamValue(['../rougail-tests/structures/00_6choice_calculation/rougail/00-base.yml']), '__internal_attribute': ParamValue("choices"), '__internal_variable': ParamValue("var")})), default=9, properties=frozenset({"mandatory", "standard"}), informations={'type': 'choice'})
|
option_1 = ChoiceOption(name="var", doc="a variable", values=Calculation(func['jinja_to_function'], Params((), kwargs={'__internal_jinja': ParamValue("choices_var"), '__internal_type': ParamValue("number"), '__internal_multi': ParamValue(True), '__internal_files': ParamValue(['tests/dictionaries/00_6choice_calculation/dictionaries/rougail/00-base.yml']), '__internal_attribute': ParamValue("choices"), '__internal_variable': ParamValue("var")})), default=9, properties=frozenset({"mandatory", "standard"}), informations={'type': 'choice'})
|
||||||
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[option_1])
|
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[option_1])
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,11 @@
|
||||||
|
---
|
||||||
|
version: '1.1'
|
||||||
|
var1: # a second variable
|
||||||
|
- a
|
||||||
|
- b
|
||||||
|
- c
|
||||||
|
var2:
|
||||||
|
description: a first variable
|
||||||
|
default: a
|
||||||
|
choices:
|
||||||
|
variable: _.var1
|
||||||
|
|
@ -2,7 +2,7 @@ from tiramisu import *
|
||||||
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
||||||
from re import compile as re_compile
|
from re import compile as re_compile
|
||||||
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
||||||
load_functions('../rougail-tests/funcs/test.py')
|
load_functions('tests/dictionaries/../eosfunc/test.py')
|
||||||
try:
|
try:
|
||||||
groups.namespace
|
groups.namespace
|
||||||
except:
|
except:
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@ from tiramisu import *
|
||||||
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
||||||
from re import compile as re_compile
|
from re import compile as re_compile
|
||||||
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
||||||
load_functions('../rougail-tests/funcs/test.py')
|
load_functions('tests/dictionaries/../eosfunc/test.py')
|
||||||
try:
|
try:
|
||||||
groups.namespace
|
groups.namespace
|
||||||
except:
|
except:
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@ from tiramisu import *
|
||||||
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
||||||
from re import compile as re_compile
|
from re import compile as re_compile
|
||||||
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
||||||
load_functions('../rougail-tests/funcs/test.py')
|
load_functions('tests/dictionaries/../eosfunc/test.py')
|
||||||
ALLOWED_LEADER_PROPERTIES.add("basic")
|
ALLOWED_LEADER_PROPERTIES.add("basic")
|
||||||
ALLOWED_LEADER_PROPERTIES.add("standard")
|
ALLOWED_LEADER_PROPERTIES.add("standard")
|
||||||
ALLOWED_LEADER_PROPERTIES.add("advanced")
|
ALLOWED_LEADER_PROPERTIES.add("advanced")
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,9 @@
|
||||||
|
---
|
||||||
|
version: '1.1'
|
||||||
|
custom1:
|
||||||
|
description: the first variable
|
||||||
|
type: custom
|
||||||
|
custom2:
|
||||||
|
description: the seconf variable
|
||||||
|
type: custom
|
||||||
|
default: value
|
||||||
|
|
@ -2,7 +2,7 @@ from tiramisu import *
|
||||||
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
||||||
from re import compile as re_compile
|
from re import compile as re_compile
|
||||||
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
||||||
load_functions('../rougail-tests/funcs/test.py')
|
load_functions('tests/dictionaries/../eosfunc/test.py')
|
||||||
try:
|
try:
|
||||||
groups.namespace
|
groups.namespace
|
||||||
except:
|
except:
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@ from tiramisu import *
|
||||||
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
||||||
from re import compile as re_compile
|
from re import compile as re_compile
|
||||||
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
||||||
load_functions('../rougail-tests/funcs/test.py')
|
load_functions('tests/dictionaries/../eosfunc/test.py')
|
||||||
try:
|
try:
|
||||||
groups.namespace
|
groups.namespace
|
||||||
except:
|
except:
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@ from tiramisu import *
|
||||||
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
||||||
from re import compile as re_compile
|
from re import compile as re_compile
|
||||||
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
||||||
load_functions('../rougail-tests/funcs/test.py')
|
load_functions('tests/dictionaries/../eosfunc/test.py')
|
||||||
ALLOWED_LEADER_PROPERTIES.add("basic")
|
ALLOWED_LEADER_PROPERTIES.add("basic")
|
||||||
ALLOWED_LEADER_PROPERTIES.add("standard")
|
ALLOWED_LEADER_PROPERTIES.add("standard")
|
||||||
ALLOWED_LEADER_PROPERTIES.add("advanced")
|
ALLOWED_LEADER_PROPERTIES.add("advanced")
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,6 @@
|
||||||
|
---
|
||||||
|
version: '1.1'
|
||||||
|
variable:
|
||||||
|
description: a domain name variable
|
||||||
|
type: domainname
|
||||||
|
default: my.domain.name
|
||||||
|
|
@ -2,7 +2,7 @@ from tiramisu import *
|
||||||
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
||||||
from re import compile as re_compile
|
from re import compile as re_compile
|
||||||
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
||||||
load_functions('../rougail-tests/funcs/test.py')
|
load_functions('tests/dictionaries/../eosfunc/test.py')
|
||||||
try:
|
try:
|
||||||
groups.namespace
|
groups.namespace
|
||||||
except:
|
except:
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@ from tiramisu import *
|
||||||
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
||||||
from re import compile as re_compile
|
from re import compile as re_compile
|
||||||
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
||||||
load_functions('../rougail-tests/funcs/test.py')
|
load_functions('tests/dictionaries/../eosfunc/test.py')
|
||||||
try:
|
try:
|
||||||
groups.namespace
|
groups.namespace
|
||||||
except:
|
except:
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@ from tiramisu import *
|
||||||
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
||||||
from re import compile as re_compile
|
from re import compile as re_compile
|
||||||
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
||||||
load_functions('../rougail-tests/funcs/test.py')
|
load_functions('tests/dictionaries/../eosfunc/test.py')
|
||||||
ALLOWED_LEADER_PROPERTIES.add("basic")
|
ALLOWED_LEADER_PROPERTIES.add("basic")
|
||||||
ALLOWED_LEADER_PROPERTIES.add("standard")
|
ALLOWED_LEADER_PROPERTIES.add("standard")
|
||||||
ALLOWED_LEADER_PROPERTIES.add("advanced")
|
ALLOWED_LEADER_PROPERTIES.add("advanced")
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,8 @@
|
||||||
|
---
|
||||||
|
version: '1.1'
|
||||||
|
variable:
|
||||||
|
description: a domain name variable
|
||||||
|
type: domainname
|
||||||
|
default: my.domain.name
|
||||||
|
params:
|
||||||
|
allow_ip: true
|
||||||
|
|
@ -2,7 +2,7 @@ from tiramisu import *
|
||||||
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
||||||
from re import compile as re_compile
|
from re import compile as re_compile
|
||||||
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
||||||
load_functions('../rougail-tests/funcs/test.py')
|
load_functions('tests/dictionaries/../eosfunc/test.py')
|
||||||
try:
|
try:
|
||||||
groups.namespace
|
groups.namespace
|
||||||
except:
|
except:
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@ from tiramisu import *
|
||||||
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
||||||
from re import compile as re_compile
|
from re import compile as re_compile
|
||||||
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
||||||
load_functions('../rougail-tests/funcs/test.py')
|
load_functions('tests/dictionaries/../eosfunc/test.py')
|
||||||
try:
|
try:
|
||||||
groups.namespace
|
groups.namespace
|
||||||
except:
|
except:
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@ from tiramisu import *
|
||||||
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
||||||
from re import compile as re_compile
|
from re import compile as re_compile
|
||||||
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
||||||
load_functions('../rougail-tests/funcs/test.py')
|
load_functions('tests/dictionaries/../eosfunc/test.py')
|
||||||
ALLOWED_LEADER_PROPERTIES.add("basic")
|
ALLOWED_LEADER_PROPERTIES.add("basic")
|
||||||
ALLOWED_LEADER_PROPERTIES.add("standard")
|
ALLOWED_LEADER_PROPERTIES.add("standard")
|
||||||
ALLOWED_LEADER_PROPERTIES.add("advanced")
|
ALLOWED_LEADER_PROPERTIES.add("advanced")
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,18 @@
|
||||||
|
---
|
||||||
|
version: '1.1'
|
||||||
|
var1: 0.0 # the first variable
|
||||||
|
var2:
|
||||||
|
description: the second variable
|
||||||
|
default: 0.0
|
||||||
|
var3:
|
||||||
|
description: the third variable
|
||||||
|
type: float
|
||||||
|
default: 0.0
|
||||||
|
var4: 10.1 # the forth variable
|
||||||
|
var5:
|
||||||
|
description: the fifth variable
|
||||||
|
default: 10.1
|
||||||
|
var6:
|
||||||
|
description: the sixth variable
|
||||||
|
type: float
|
||||||
|
default: 10.1
|
||||||
|
|
@ -2,7 +2,7 @@ from tiramisu import *
|
||||||
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
||||||
from re import compile as re_compile
|
from re import compile as re_compile
|
||||||
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
||||||
load_functions('../rougail-tests/funcs/test.py')
|
load_functions('tests/dictionaries/../eosfunc/test.py')
|
||||||
try:
|
try:
|
||||||
groups.namespace
|
groups.namespace
|
||||||
except:
|
except:
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@ from tiramisu import *
|
||||||
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
||||||
from re import compile as re_compile
|
from re import compile as re_compile
|
||||||
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
||||||
load_functions('../rougail-tests/funcs/test.py')
|
load_functions('tests/dictionaries/../eosfunc/test.py')
|
||||||
try:
|
try:
|
||||||
groups.namespace
|
groups.namespace
|
||||||
except:
|
except:
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@ from tiramisu import *
|
||||||
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
||||||
from re import compile as re_compile
|
from re import compile as re_compile
|
||||||
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
||||||
load_functions('../rougail-tests/funcs/test.py')
|
load_functions('tests/dictionaries/../eosfunc/test.py')
|
||||||
ALLOWED_LEADER_PROPERTIES.add("basic")
|
ALLOWED_LEADER_PROPERTIES.add("basic")
|
||||||
ALLOWED_LEADER_PROPERTIES.add("standard")
|
ALLOWED_LEADER_PROPERTIES.add("standard")
|
||||||
ALLOWED_LEADER_PROPERTIES.add("advanced")
|
ALLOWED_LEADER_PROPERTIES.add("advanced")
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,18 @@
|
||||||
|
---
|
||||||
|
version: '1.1'
|
||||||
|
var1: 0 # the first variable
|
||||||
|
var2:
|
||||||
|
description: the second variable
|
||||||
|
default: 0
|
||||||
|
var3:
|
||||||
|
description: the third variable
|
||||||
|
type: number
|
||||||
|
default: 0
|
||||||
|
var4: 10 # this forth variable
|
||||||
|
var5:
|
||||||
|
description: the fifth variable
|
||||||
|
default: 10
|
||||||
|
var6:
|
||||||
|
description: the sixth variable
|
||||||
|
type: number
|
||||||
|
default: 10
|
||||||
|
|
@ -2,7 +2,7 @@ from tiramisu import *
|
||||||
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
||||||
from re import compile as re_compile
|
from re import compile as re_compile
|
||||||
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
||||||
load_functions('../rougail-tests/funcs/test.py')
|
load_functions('tests/dictionaries/../eosfunc/test.py')
|
||||||
try:
|
try:
|
||||||
groups.namespace
|
groups.namespace
|
||||||
except:
|
except:
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@ from tiramisu import *
|
||||||
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
||||||
from re import compile as re_compile
|
from re import compile as re_compile
|
||||||
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
||||||
load_functions('../rougail-tests/funcs/test.py')
|
load_functions('tests/dictionaries/../eosfunc/test.py')
|
||||||
try:
|
try:
|
||||||
groups.namespace
|
groups.namespace
|
||||||
except:
|
except:
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@ from tiramisu import *
|
||||||
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
||||||
from re import compile as re_compile
|
from re import compile as re_compile
|
||||||
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
||||||
load_functions('../rougail-tests/funcs/test.py')
|
load_functions('tests/dictionaries/../eosfunc/test.py')
|
||||||
ALLOWED_LEADER_PROPERTIES.add("basic")
|
ALLOWED_LEADER_PROPERTIES.add("basic")
|
||||||
ALLOWED_LEADER_PROPERTIES.add("standard")
|
ALLOWED_LEADER_PROPERTIES.add("standard")
|
||||||
ALLOWED_LEADER_PROPERTIES.add("advanced")
|
ALLOWED_LEADER_PROPERTIES.add("advanced")
|
||||||
|
|
|
||||||
13
tests/dictionaries/00_6port/dictionaries/rougail/00-base.yml
Normal file
13
tests/dictionaries/00_6port/dictionaries/rougail/00-base.yml
Normal file
|
|
@ -0,0 +1,13 @@
|
||||||
|
---
|
||||||
|
version: '1.1'
|
||||||
|
variable1:
|
||||||
|
description: a port variable
|
||||||
|
type: port
|
||||||
|
variable2:
|
||||||
|
description: a port variable with default value
|
||||||
|
type: port
|
||||||
|
default: '8080'
|
||||||
|
variable3:
|
||||||
|
description: a port variable with integer default value
|
||||||
|
type: port
|
||||||
|
default: 8080
|
||||||
|
|
@ -2,7 +2,7 @@ from tiramisu import *
|
||||||
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
||||||
from re import compile as re_compile
|
from re import compile as re_compile
|
||||||
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
||||||
load_functions('../rougail-tests/funcs/test.py')
|
load_functions('tests/dictionaries/../eosfunc/test.py')
|
||||||
try:
|
try:
|
||||||
groups.namespace
|
groups.namespace
|
||||||
except:
|
except:
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@ from tiramisu import *
|
||||||
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
||||||
from re import compile as re_compile
|
from re import compile as re_compile
|
||||||
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
||||||
load_functions('../rougail-tests/funcs/test.py')
|
load_functions('tests/dictionaries/../eosfunc/test.py')
|
||||||
try:
|
try:
|
||||||
groups.namespace
|
groups.namespace
|
||||||
except:
|
except:
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@ from tiramisu import *
|
||||||
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
||||||
from re import compile as re_compile
|
from re import compile as re_compile
|
||||||
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
||||||
load_functions('../rougail-tests/funcs/test.py')
|
load_functions('tests/dictionaries/../eosfunc/test.py')
|
||||||
ALLOWED_LEADER_PROPERTIES.add("basic")
|
ALLOWED_LEADER_PROPERTIES.add("basic")
|
||||||
ALLOWED_LEADER_PROPERTIES.add("standard")
|
ALLOWED_LEADER_PROPERTIES.add("standard")
|
||||||
ALLOWED_LEADER_PROPERTIES.add("advanced")
|
ALLOWED_LEADER_PROPERTIES.add("advanced")
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,9 @@
|
||||||
|
---
|
||||||
|
version: '1.1'
|
||||||
|
var:
|
||||||
|
description: a first variable
|
||||||
|
regexp: "^#(?:[0-9a-f]{3}){1,2}$"
|
||||||
|
default: "#a1a1a1"
|
||||||
|
test:
|
||||||
|
- "#b1b1b1"
|
||||||
|
- "#b2b2b2"
|
||||||
|
|
@ -2,7 +2,7 @@ from tiramisu import *
|
||||||
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
||||||
from re import compile as re_compile
|
from re import compile as re_compile
|
||||||
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
||||||
load_functions('../rougail-tests/funcs/test.py')
|
load_functions('tests/dictionaries/../eosfunc/test.py')
|
||||||
try:
|
try:
|
||||||
groups.namespace
|
groups.namespace
|
||||||
except:
|
except:
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@ from tiramisu import *
|
||||||
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
||||||
from re import compile as re_compile
|
from re import compile as re_compile
|
||||||
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
||||||
load_functions('../rougail-tests/funcs/test.py')
|
load_functions('tests/dictionaries/../eosfunc/test.py')
|
||||||
try:
|
try:
|
||||||
groups.namespace
|
groups.namespace
|
||||||
except:
|
except:
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@ from tiramisu import *
|
||||||
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
||||||
from re import compile as re_compile
|
from re import compile as re_compile
|
||||||
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
||||||
load_functions('../rougail-tests/funcs/test.py')
|
load_functions('tests/dictionaries/../eosfunc/test.py')
|
||||||
ALLOWED_LEADER_PROPERTIES.add("basic")
|
ALLOWED_LEADER_PROPERTIES.add("basic")
|
||||||
ALLOWED_LEADER_PROPERTIES.add("standard")
|
ALLOWED_LEADER_PROPERTIES.add("standard")
|
||||||
ALLOWED_LEADER_PROPERTIES.add("advanced")
|
ALLOWED_LEADER_PROPERTIES.add("advanced")
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,17 @@
|
||||||
|
---
|
||||||
|
version: '1.1'
|
||||||
|
var1: # the first variable
|
||||||
|
var2:
|
||||||
|
description: the second variable
|
||||||
|
default:
|
||||||
|
var3:
|
||||||
|
description: the third variable
|
||||||
|
type: string
|
||||||
|
var4: value # the forth variable
|
||||||
|
var5:
|
||||||
|
description: the fifth variable
|
||||||
|
default: value
|
||||||
|
var6:
|
||||||
|
description: the sixth variable
|
||||||
|
type: string
|
||||||
|
default: value
|
||||||
|
|
@ -2,7 +2,7 @@ from tiramisu import *
|
||||||
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
||||||
from re import compile as re_compile
|
from re import compile as re_compile
|
||||||
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
||||||
load_functions('../rougail-tests/funcs/test.py')
|
load_functions('tests/dictionaries/../eosfunc/test.py')
|
||||||
try:
|
try:
|
||||||
groups.namespace
|
groups.namespace
|
||||||
except:
|
except:
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@ from tiramisu import *
|
||||||
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
||||||
from re import compile as re_compile
|
from re import compile as re_compile
|
||||||
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
||||||
load_functions('../rougail-tests/funcs/test.py')
|
load_functions('tests/dictionaries/../eosfunc/test.py')
|
||||||
try:
|
try:
|
||||||
groups.namespace
|
groups.namespace
|
||||||
except:
|
except:
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@ from tiramisu import *
|
||||||
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
||||||
from re import compile as re_compile
|
from re import compile as re_compile
|
||||||
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
||||||
load_functions('../rougail-tests/funcs/test.py')
|
load_functions('tests/dictionaries/../eosfunc/test.py')
|
||||||
ALLOWED_LEADER_PROPERTIES.add("basic")
|
ALLOWED_LEADER_PROPERTIES.add("basic")
|
||||||
ALLOWED_LEADER_PROPERTIES.add("standard")
|
ALLOWED_LEADER_PROPERTIES.add("standard")
|
||||||
ALLOWED_LEADER_PROPERTIES.add("advanced")
|
ALLOWED_LEADER_PROPERTIES.add("advanced")
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,10 @@
|
||||||
|
---
|
||||||
|
version: '1.0'
|
||||||
|
var:
|
||||||
|
type: choice
|
||||||
|
description: A choice
|
||||||
|
default: quote'
|
||||||
|
choices:
|
||||||
|
- quote'
|
||||||
|
- quote"
|
||||||
|
- quote"'
|
||||||
|
|
@ -2,7 +2,7 @@ from tiramisu import *
|
||||||
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
||||||
from re import compile as re_compile
|
from re import compile as re_compile
|
||||||
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
||||||
load_functions('../rougail-tests/funcs/test.py')
|
load_functions('tests/dictionaries/../eosfunc/test.py')
|
||||||
try:
|
try:
|
||||||
groups.namespace
|
groups.namespace
|
||||||
except:
|
except:
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@ from tiramisu import *
|
||||||
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
||||||
from re import compile as re_compile
|
from re import compile as re_compile
|
||||||
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
||||||
load_functions('../rougail-tests/funcs/test.py')
|
load_functions('tests/dictionaries/../eosfunc/test.py')
|
||||||
try:
|
try:
|
||||||
groups.namespace
|
groups.namespace
|
||||||
except:
|
except:
|
||||||
|
|
|
||||||
|
|
@ -2,7 +2,7 @@ from tiramisu import *
|
||||||
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
||||||
from re import compile as re_compile
|
from re import compile as re_compile
|
||||||
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
||||||
load_functions('../rougail-tests/funcs/test.py')
|
load_functions('tests/dictionaries/../eosfunc/test.py')
|
||||||
ALLOWED_LEADER_PROPERTIES.add("basic")
|
ALLOWED_LEADER_PROPERTIES.add("basic")
|
||||||
ALLOWED_LEADER_PROPERTIES.add("standard")
|
ALLOWED_LEADER_PROPERTIES.add("standard")
|
||||||
ALLOWED_LEADER_PROPERTIES.add("advanced")
|
ALLOWED_LEADER_PROPERTIES.add("advanced")
|
||||||
|
|
|
||||||
|
|
@ -0,0 +1,8 @@
|
||||||
|
---
|
||||||
|
version: '1.0'
|
||||||
|
var1:
|
||||||
|
description: the first variable
|
||||||
|
help: message with '
|
||||||
|
var2:
|
||||||
|
description: the second variable
|
||||||
|
help: message with "
|
||||||
|
|
@ -2,7 +2,7 @@ from tiramisu import *
|
||||||
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
from tiramisu.setting import ALLOWED_LEADER_PROPERTIES
|
||||||
from re import compile as re_compile
|
from re import compile as re_compile
|
||||||
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription
|
||||||
load_functions('../rougail-tests/funcs/test.py')
|
load_functions('tests/dictionaries/../eosfunc/test.py')
|
||||||
try:
|
try:
|
||||||
groups.namespace
|
groups.namespace
|
||||||
except:
|
except:
|
||||||
|
|
|
||||||
Some files were not shown because too many files have changed in this diff Show more
Loading…
Reference in a new issue