Compare commits

..

No commits in common. "f6143e843c645aaf843ea56d3112a1803c918989" and "ea8bc3f02ecaeddd29fb1d81379386d05e54ae68" have entirely different histories.

641 changed files with 5086 additions and 18263 deletions

View file

@ -100,7 +100,7 @@ Dans ce cas, tous les services et les éléments qu'il compose avec un attribut
La désactivation du service va créé un lien symbolique vers /dev/null. La désactivation du service va créé un lien symbolique vers /dev/null.
Si vous ne voulez juste pas créer le fichier de service et ne pas faire de lien symbolique, il faut utiliser l'attribut undisable : Si vous ne voulez juste pas créé le fichier de service et ne pas faire de lien symbolique, il faut utiliser l'attribut undisable :
``` ```
<service name="test" disabled="True" undisable="True"/> <service name="test" disabled="True" undisable="True"/>

View file

@ -26,7 +26,7 @@ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
""" """
from .variable import CONVERT_OPTION from .variable import CONVERT_OPTION
import importlib.resources import importlib.resources
from os.path import dirname, join, isfile from os.path import dirname, join
from ..utils import load_modules from ..utils import load_modules
@ -83,8 +83,7 @@ class SpaceAnnotator: # pylint: disable=R0903
annotators = sorted(annotators, key=get_level) annotators = sorted(annotators, key=get_level)
functions = [] functions = []
for eosfunc_file in eosfunc_files: for eosfunc_file in eosfunc_files:
if isfile(eosfunc_file): functions.extend(dir(load_modules(eosfunc_file)))
functions.extend(dir(load_modules(eosfunc_file)))
for annotator in annotators: for annotator in annotators:
annotator(objectspace, annotator(objectspace,
functions, functions,

View file

@ -44,31 +44,30 @@ class Annotator(TargetAnnotator, ParamAnnotator):
functions, functions,
*args, *args,
): ):
if not hasattr(objectspace.space, 'constraints') or \
not hasattr(objectspace.space.constraints, 'check'):
return
self.objectspace = objectspace self.objectspace = objectspace
self.let_none = True
self.only_variable = True self.only_variable = True
self.target_is_uniq = False
self.allow_function = True
self.functions = copy(functions) self.functions = copy(functions)
self.functions.extend(INTERNAL_FUNCTIONS) self.functions.extend(INTERNAL_FUNCTIONS)
self.functions.extend(self.objectspace.rougailconfig['internal_functions']) self.functions.extend(self.objectspace.rougailconfig['internal_functions'])
for path_prefix, constraints in self.get_constraints(): self.target_is_uniq = False
if not hasattr(constraints, 'check'): self.allow_function = True
continue self.convert_target(self.objectspace.space.constraints.check)
self.convert_target(constraints.check, path_prefix) self.convert_param(self.objectspace.space.constraints.check)
self.convert_param(constraints.check, path_prefix) self.check_check()
self.check_check(constraints) self.check_change_warning()
self.check_change_warning(constraints) self.convert_valid_entier()
self.convert_valid_entier(constraints) self.convert_check()
self.convert_check(constraints) del objectspace.space.constraints.check
del constraints.check
def check_check(self, def check_check(self): # pylint: disable=R0912
constraints,
): # pylint: disable=R0912
"""valid and manage <check> """valid and manage <check>
""" """
remove_indexes = [] remove_indexes = []
for check_idx, check in enumerate(constraints.check): for check_idx, check in enumerate(self.objectspace.space.constraints.check):
if not check.name in self.functions: if not check.name in self.functions:
msg = _(f'cannot find check function "{check.name}"') msg = _(f'cannot find check function "{check.name}"')
raise DictConsistencyError(msg, 1, check.xmlfiles) raise DictConsistencyError(msg, 1, check.xmlfiles)
@ -76,24 +75,20 @@ class Annotator(TargetAnnotator, ParamAnnotator):
remove_indexes.append(check_idx) remove_indexes.append(check_idx)
remove_indexes.sort(reverse=True) remove_indexes.sort(reverse=True)
for idx in remove_indexes: for idx in remove_indexes:
del constraints.check[idx] del self.objectspace.space.constraints.check[idx]
def check_change_warning(self, def check_change_warning(self):
constraints,
):
"""convert level to "warnings_only" """convert level to "warnings_only"
""" """
for check in constraints.check: for check in self.objectspace.space.constraints.check:
check.warnings_only = check.level == 'warning' check.warnings_only = check.level == 'warning'
check.level = None check.level = None
def convert_valid_entier(self, def convert_valid_entier(self) -> None:
constraints,
) -> None:
"""valid and manage <check> """valid and manage <check>
""" """
remove_indexes = [] remove_indexes = []
for check_idx, check in enumerate(constraints.check): for check_idx, check in enumerate(self.objectspace.space.constraints.check):
if not check.name == 'valid_entier': if not check.name == 'valid_entier':
continue continue
remove_indexes.append(check_idx) remove_indexes.append(check_idx)
@ -116,14 +111,12 @@ class Annotator(TargetAnnotator, ParamAnnotator):
raise DictConsistencyError(msg, 19, check.xmlfiles) raise DictConsistencyError(msg, 19, check.xmlfiles)
remove_indexes.sort(reverse=True) remove_indexes.sort(reverse=True)
for idx in remove_indexes: for idx in remove_indexes:
del constraints.check[idx] del self.objectspace.space.constraints.check[idx]
def convert_check(self, def convert_check(self) -> None:
constraints,
) -> None:
"""valid and manage <check> """valid and manage <check>
""" """
for check in constraints.check: for check in self.objectspace.space.constraints.check:
for target in check.target: for target in check.target:
if not hasattr(target.name, 'validators'): if not hasattr(target.name, 'validators'):
target.name.validators = [] target.name.validators = []

View file

@ -44,24 +44,24 @@ class Annotator(TargetAnnotator, ParamAnnotator, Walk):
*args, *args,
): ):
self.objectspace = objectspace self.objectspace = objectspace
self.target_is_uniq = False
self.only_variable = False
self.allow_function = False
self.force_service_value = {} self.force_service_value = {}
if hasattr(objectspace.space, 'variables'): if hasattr(objectspace.space, 'variables'):
self.convert_auto_freeze() self.convert_auto_freeze()
for path_prefix, constraints in self.get_constraints(): if not hasattr(objectspace.space, 'constraints') or \
if not hasattr(constraints, 'condition'): not hasattr(self.objectspace.space.constraints, 'condition'):
continue return
self.convert_target(constraints.condition, path_prefix) self.target_is_uniq = False
self.check_condition_optional(constraints, path_prefix) self.only_variable = False
self.convert_condition_source(constraints, path_prefix) self.allow_function = False
self.convert_param(constraints.condition, path_prefix) self.convert_target(self.objectspace.space.constraints.condition)
self.check_source_target(constraints) self.check_condition_optional()
self.convert_xxxlist(constraints, path_prefix) self.convert_condition_source()
self.check_choice_option_condition(constraints, path_prefix) self.convert_param(self.objectspace.space.constraints.condition)
self.remove_condition_with_empty_target(constraints) self.check_source_target()
self.convert_condition(constraints, path_prefix) self.convert_xxxlist()
self.check_choice_option_condition()
self.remove_condition_with_empty_target()
self.convert_condition()
def valid_type_validation(self, def valid_type_validation(self,
obj, obj,
@ -83,38 +83,27 @@ class Annotator(TargetAnnotator, ParamAnnotator, Walk):
variable.force_store_value = True variable.force_store_value = True
if variable.auto_save: if variable.auto_save:
continue continue
auto_freeze_variable = self.objectspace.rougailconfig['auto_freeze_variable']
if not self.objectspace.paths.path_is_defined(auto_freeze_variable,
self.objectspace.rougailconfig['variable_namespace'],
variable.path_prefix,
):
msg = _(f'the variable "{variable.name}" is auto_freeze but there is no variable "{auto_freeze_variable}"')
raise DictConsistencyError(msg, 81, variable.xmlfiles)
new_condition = self.objectspace.condition(variable.xmlfiles) new_condition = self.objectspace.condition(variable.xmlfiles)
new_condition.name = 'auto_frozen_if_in' new_condition.name = 'auto_frozen_if_in'
new_condition.namespace = variable.namespace new_condition.namespace = variable.namespace
new_condition.source = auto_freeze_variable new_condition.source = self.objectspace.rougailconfig['auto_freeze_variable']
new_param = self.objectspace.param(variable.xmlfiles) new_param = self.objectspace.param(variable.xmlfiles)
new_param.text = True new_param.text = True
new_condition.param = [new_param] new_condition.param = [new_param]
new_target = self.objectspace.target(variable.xmlfiles) new_target = self.objectspace.target(variable.xmlfiles)
new_target.type = 'variable' new_target.type = 'variable'
path = variable.path new_target.name = variable.path
if variable.path_prefix:
path = path.split('.', 1)[-1]
new_target.name = path
new_condition.target = [new_target] new_condition.target = [new_target]
path_prefix, constraints = next(self.get_constraints(create=True, if not hasattr(self.objectspace.space, 'constraints'):
path_prefix=variable.path_prefix, self.objectspace.space.constraints = self.objectspace.constraints(variable.xmlfiles)
)) if not hasattr(self.objectspace.space.constraints, 'condition'):
if not hasattr(constraints, 'condition'): self.objectspace.space.constraints.condition = []
constraints.condition = [] self.objectspace.space.constraints.condition.append(new_condition)
constraints.condition.append(new_condition)
def check_source_target(self, constraints): def check_source_target(self):
"""verify that source != target in condition """verify that source != target in condition
""" """
for condition in constraints.condition: for condition in self.objectspace.space.constraints.condition:
for target in condition.target: for target in condition.target:
if target.type == 'variable' and \ if target.type == 'variable' and \
condition.source.path == target.name.path: condition.source.path == target.name.path:
@ -122,34 +111,25 @@ class Annotator(TargetAnnotator, ParamAnnotator, Walk):
f'{condition.source.path}') f'{condition.source.path}')
raise DictConsistencyError(msg, 11, condition.xmlfiles) raise DictConsistencyError(msg, 11, condition.xmlfiles)
def check_condition_optional(self, def check_condition_optional(self):
constraints,
path_prefix,
):
"""a condition with a optional **and** the source variable doesn't exist """a condition with a optional **and** the source variable doesn't exist
""" """
remove_conditions = [] remove_conditions = []
for idx, condition in enumerate(constraints.condition): for idx, condition in enumerate(self.objectspace.space.constraints.condition):
if condition.optional is False or \ if condition.optional is False or \
self.objectspace.paths.path_is_defined(condition.source, self.objectspace.paths.path_is_defined(condition.source):
condition.namespace,
path_prefix,
):
continue continue
remove_conditions.append(idx) remove_conditions.append(idx)
if (hasattr(condition, 'apply_on_fallback') and condition.apply_on_fallback) or \ if (hasattr(condition, 'apply_on_fallback') and condition.apply_on_fallback) or \
(not hasattr(condition, 'apply_on_fallback') and \ (not hasattr(condition, 'apply_on_fallback') and \
condition.name.endswith('_if_in')): condition.name.endswith('_if_in')):
self.force_actions_to_variable(condition, self.force_actions_to_variable(condition)
path_prefix,
)
remove_conditions.sort(reverse=True) remove_conditions.sort(reverse=True)
for idx in remove_conditions: for idx in remove_conditions:
constraints.condition.pop(idx) self.objectspace.space.constraints.condition.pop(idx)
def force_actions_to_variable(self, def force_actions_to_variable(self,
condition: 'self.objectspace.condition', condition: 'self.objectspace.condition',
path_prefix,
) -> None: ) -> None:
"""force property to a variable """force property to a variable
for example disabled_if_not_in => variable.disabled = True for example disabled_if_not_in => variable.disabled = True
@ -160,9 +140,7 @@ class Annotator(TargetAnnotator, ParamAnnotator, Walk):
if target.type.endswith('list'): if target.type.endswith('list'):
self.force_service_value[target.name] = main_action != 'disabled' self.force_service_value[target.name] = main_action != 'disabled'
continue continue
leader_or_var, variables = self._get_family_variables_from_target(target, leader_or_var, variables = self._get_family_variables_from_target(target)
path_prefix,
)
setattr(leader_or_var, main_action, True) setattr(leader_or_var, main_action, True)
for action in actions[1:]: for action in actions[1:]:
for variable in variables: for variable in variables:
@ -180,41 +158,35 @@ class Annotator(TargetAnnotator, ParamAnnotator, Walk):
def _get_family_variables_from_target(self, def _get_family_variables_from_target(self,
target, target,
path_prefix,
): ):
if target.type == 'variable': if target.type == 'variable':
if not self.objectspace.paths.is_leader(target.name): if not self.objectspace.paths.is_leader(target.name.path):
return target.name, [target.name] return target.name, [target.name]
# it's a leader, so apply property to leadership # it's a leader, so apply property to leadership
family_name = self.objectspace.paths.get_variable_family_path(target.name.path)
namespace = target.name.namespace namespace = target.name.namespace
family_name = self.objectspace.paths.get_variable_family_path(target.name.path,
namespace,
force_path_prefix=path_prefix,
)
else: else:
family_name = target.name.path family_name = target.name.path
namespace = target.namespace namespace = target.namespace
variable = self.objectspace.paths.get_family(family_name, variable = self.objectspace.paths.get_family(family_name,
namespace, namespace,
path_prefix,
) )
if hasattr(variable, 'variable'): if hasattr(variable, 'variable'):
return variable, list(variable.variable.values()) return variable, list(variable.variable.values())
return variable, [] return variable, []
def convert_xxxlist(self, constraints, path_prefix): def convert_xxxlist(self):
"""transform *list to variable or family """transform *list to variable or family
""" """
fills = {} fills = {}
for condition in constraints.condition: for condition in self.objectspace.space.constraints.condition:
remove_targets = [] remove_targets = []
for target_idx, target in enumerate(condition.target): for target_idx, target in enumerate(condition.target):
if target.type.endswith('list'): if target.type.endswith('list'):
listvars = self.objectspace.paths.list_conditions[path_prefix].get(target.type, listvars = self.objectspace.list_conditions.get(target.type,
{}).get(target.name) {}).get(target.name)
if listvars: if listvars:
self._convert_xxxlist_to_fill(constraints, self._convert_xxxlist_to_fill(condition,
condition,
target, target,
listvars, listvars,
fills, fills,
@ -228,7 +200,6 @@ class Annotator(TargetAnnotator, ParamAnnotator, Walk):
condition.target.pop(target_idx) condition.target.pop(target_idx)
def _convert_xxxlist_to_fill(self, def _convert_xxxlist_to_fill(self,
constraints,
condition: 'self.objectspace.condition', condition: 'self.objectspace.condition',
target: 'self.objectspace.target', target: 'self.objectspace.target',
listvars: list, listvars: list,
@ -236,11 +207,9 @@ class Annotator(TargetAnnotator, ParamAnnotator, Walk):
): ):
for listvar in listvars: for listvar in listvars:
if target.name in self.force_service_value: if target.name in self.force_service_value:
# do not add fill, just change default value
listvar.default = self.force_service_value[target.name] listvar.default = self.force_service_value[target.name]
continue continue
if listvar.path in fills: if listvar.path in fills:
# a fill is already set for this path
fill = fills[listvar.path] fill = fills[listvar.path]
or_needed = True or_needed = True
for param in fill.param: for param in fill.param:
@ -252,17 +221,14 @@ class Annotator(TargetAnnotator, ParamAnnotator, Walk):
else: else:
fill = self.objectspace.fill(target.xmlfiles) fill = self.objectspace.fill(target.xmlfiles)
new_target = self.objectspace.target(target.xmlfiles) new_target = self.objectspace.target(target.xmlfiles)
path = listvar.path new_target.name = listvar.path
if listvar.path_prefix:
path = path.split('.', 1)[-1]
new_target.name = path
fill.target = [new_target] fill.target = [new_target]
fill.name = 'calc_value' fill.name = 'calc_value'
fill.namespace = 'services' fill.namespace = 'services'
fill.index = 0 fill.index = 0
if not hasattr(constraints, 'fill'): if not hasattr(self.objectspace.space.constraints, 'fill'):
constraints.fill = [] self.objectspace.space.constraints.fill = []
constraints.fill.append(fill) self.objectspace.space.constraints.fill.append(fill)
fills[listvar.path] = fill fills[listvar.path] = fill
param1 = self.objectspace.param(target.xmlfiles) param1 = self.objectspace.param(target.xmlfiles)
param1.text = False param1.text = False
@ -285,10 +251,7 @@ class Annotator(TargetAnnotator, ParamAnnotator, Walk):
param3 = self.objectspace.param(target.xmlfiles) param3 = self.objectspace.param(target.xmlfiles)
param3.name = f'condition_{fill.index}' param3.name = f'condition_{fill.index}'
param3.type = 'variable' param3.type = 'variable'
path = condition.source.path param3.text = condition.source.path
if condition.source.path_prefix:
path = path.split('.', 1)[-1]
param3.text = path
param3.propertyerror = False param3.propertyerror = False
fill.param.append(param3) fill.param.append(param3)
param4 = self.objectspace.param(target.xmlfiles) param4 = self.objectspace.param(target.xmlfiles)
@ -308,17 +271,12 @@ class Annotator(TargetAnnotator, ParamAnnotator, Walk):
param6.text = 'OR' param6.text = 'OR'
fill.param.append(param6) fill.param.append(param6)
def convert_condition_source(self, constraints, path_prefix): def convert_condition_source(self):
"""remove condition for ChoiceOption that don't have param """remove condition for ChoiceOption that don't have param
""" """
for condition in constraints.condition: for condition in self.objectspace.space.constraints.condition:
try: try:
condition.source = self.objectspace.paths.get_variable(condition.source, condition.source = self.objectspace.paths.get_variable(condition.source)
condition.namespace,
allow_variable_namespace=True,
force_path_prefix=path_prefix,
add_path_prefix=True,
)
except DictConsistencyError as err: except DictConsistencyError as err:
if err.errno == 36: if err.errno == 36:
msg = _(f'the source "{condition.source}" in condition cannot be a dynamic ' msg = _(f'the source "{condition.source}" in condition cannot be a dynamic '
@ -329,58 +287,46 @@ class Annotator(TargetAnnotator, ParamAnnotator, Walk):
raise DictConsistencyError(msg, 23, condition.xmlfiles) from err raise DictConsistencyError(msg, 23, condition.xmlfiles) from err
raise err from err # pragma: no cover raise err from err # pragma: no cover
def check_choice_option_condition(self, def check_choice_option_condition(self):
constraints,
path_prefix,
):
"""remove condition of ChoiceOption that doesn't match """remove condition of ChoiceOption that doesn't match
""" """
remove_conditions = [] remove_conditions = []
for condition_idx, condition in enumerate(constraints.condition): for condition_idx, condition in enumerate(self.objectspace.space.constraints.condition):
if not self.objectspace.paths.has_valid_enums(condition.source.path, if condition.source.path in self.objectspace.valid_enums:
condition.source.path_prefix, valid_enum = self.objectspace.valid_enums[condition.source.path]['values']
): remove_param = [param_idx for param_idx, param in enumerate(condition.param) \
continue if param.type != 'variable' and param.text not in valid_enum]
valid_enum = self.objectspace.paths.get_valid_enums(condition.source.path, if not remove_param:
condition.source.path_prefix, continue
) remove_param.sort(reverse=True)
remove_param = [param_idx for param_idx, param in enumerate(condition.param) \ for idx in remove_param:
if param.type != 'variable' and param.text not in valid_enum] del condition.param[idx]
if not remove_param: if not condition.param and condition.name.endswith('_if_not_in'):
continue self.force_actions_to_variable(condition)
remove_param.sort(reverse=True) remove_conditions.append(condition_idx)
for idx in remove_param:
del condition.param[idx]
if not condition.param and condition.name.endswith('_if_not_in'):
self.force_actions_to_variable(condition,
path_prefix,
)
remove_conditions.append(condition_idx)
remove_conditions.sort(reverse=True) remove_conditions.sort(reverse=True)
for idx in remove_conditions: for idx in remove_conditions:
constraints.condition.pop(idx) self.objectspace.space.constraints.condition.pop(idx)
def remove_condition_with_empty_target(self, constraints): def remove_condition_with_empty_target(self):
"""remove condition with empty target """remove condition with empty target
""" """
# optional target are remove, condition could be empty # optional target are remove, condition could be empty
remove_conditions = [condition_idx for condition_idx, condition in \ remove_conditions = [condition_idx for condition_idx, condition in \
enumerate(constraints.condition) \ enumerate(self.objectspace.space.constraints.condition) \
if not condition.target] if not condition.target]
remove_conditions.sort(reverse=True) remove_conditions.sort(reverse=True)
for idx in remove_conditions: for idx in remove_conditions:
constraints.condition.pop(idx) self.objectspace.space.constraints.condition.pop(idx)
def convert_condition(self, constraints, path_prefix): def convert_condition(self):
"""valid and manage <condition> """valid and manage <condition>
""" """
for condition in constraints.condition: for condition in self.objectspace.space.constraints.condition:
actions = self.get_actions_from_condition(condition.name) actions = self.get_actions_from_condition(condition.name)
for param in condition.param: for param in condition.param:
for target in condition.target: for target in condition.target:
leader_or_variable, variables = self._get_family_variables_from_target(target, leader_or_variable, variables = self._get_family_variables_from_target(target)
path_prefix,
)
# if option is already disable, do not apply disable_if_in # if option is already disable, do not apply disable_if_in
# check only the first action (example of multiple actions: # check only the first action (example of multiple actions:
# 'hidden', 'frozen', 'force_default_on_freeze') # 'hidden', 'frozen', 'force_default_on_freeze')

View file

@ -61,17 +61,6 @@ class Annotator(Walk):
self.dynamic_families() self.dynamic_families()
self.convert_help() self.convert_help()
def remove_empty_families(self) -> None:
"""Remove all families without any variable
"""
removed_families = {}
for family, parent in self.get_families(with_parent=True):
if isinstance(family, self.objectspace.family) and not self._has_variable(family):
removed_families.setdefault(parent, []).append(family)
for parent, families in removed_families.items():
for family in families:
del parent.variable[family.name]
def _has_variable(self, def _has_variable(self,
family: 'self.objectspace.family', family: 'self.objectspace.family',
) -> bool: ) -> bool:
@ -84,6 +73,18 @@ class Annotator(Walk):
return True return True
return False return False
def remove_empty_families(self) -> None:
"""Remove all families without any variable
"""
#FIXME pas sous family
for families in self.objectspace.space.variables.values():
removed_families = []
for family_name, family in families.variable.items():
if isinstance(family, self.objectspace.family) and not self._has_variable(family):
removed_families.append(family_name)
for family_name in removed_families:
del families.variable[family_name]
def family_names(self) -> None: def family_names(self) -> None:
"""Set doc, path, ... to family """Set doc, path, ... to family
""" """
@ -267,13 +268,7 @@ class Annotator(Walk):
for family in self.get_families(): for family in self.get_families():
if 'dynamic' not in vars(family): if 'dynamic' not in vars(family):
continue continue
family.suffixes = self.objectspace.paths.get_variable(family.dynamic, family.suffixes = self.objectspace.paths.get_variable(family.dynamic, family.xmlfiles)
family.namespace,
xmlfiles=family.xmlfiles,
allow_variable_namespace=True,
force_path_prefix=family.path_prefix,
add_path_prefix=True,
)
del family.dynamic del family.dynamic
if not family.suffixes.multi: if not family.suffixes.multi:
msg = _(f'dynamic family "{family.name}" must be linked ' msg = _(f'dynamic family "{family.name}" must be linked '

View file

@ -44,6 +44,9 @@ class Annotator(TargetAnnotator, ParamAnnotator):
functions, functions,
*args, *args,
): ):
if not hasattr(objectspace.space, 'constraints') or \
not hasattr(objectspace.space.constraints, 'fill'):
return
self.objectspace = objectspace self.objectspace = objectspace
self.functions = copy(functions) self.functions = copy(functions)
self.functions.extend(self.objectspace.rougailconfig['internal_functions']) self.functions.extend(self.objectspace.rougailconfig['internal_functions'])
@ -52,13 +55,10 @@ class Annotator(TargetAnnotator, ParamAnnotator):
self.target_is_uniq = True self.target_is_uniq = True
self.only_variable = True self.only_variable = True
self.allow_function = False self.allow_function = False
for path_prefix, constraints in self.get_constraints(): self.convert_target(self.objectspace.space.constraints.fill)
if not hasattr(constraints, 'fill'): self.convert_param(self.objectspace.space.constraints.fill)
continue self.fill_to_value()
self.convert_target(constraints.fill, path_prefix) del self.objectspace.space.constraints.fill
self.convert_param(constraints.fill, path_prefix)
self.fill_to_value(constraints)
del constraints.fill
def calc_is_multi(self, variable: 'self.objectspace.variable') -> bool: def calc_is_multi(self, variable: 'self.objectspace.variable') -> bool:
multi = variable.multi multi = variable.multi
@ -66,12 +66,12 @@ class Annotator(TargetAnnotator, ParamAnnotator):
return multi return multi
if multi == 'submulti': if multi == 'submulti':
return True return True
return not self.objectspace.paths.is_follower(variable) return not self.objectspace.paths.is_follower(variable.path)
def fill_to_value(self, constraints) -> None: def fill_to_value(self) -> None:
"""valid and manage <fill> """valid and manage <fill>
""" """
for fill in constraints.fill: for fill in self.objectspace.space.constraints.fill:
# test if the function exists # test if the function exists
if fill.name not in self.functions: if fill.name not in self.functions:
msg = _(f'cannot find fill function "{fill.name}"') msg = _(f'cannot find fill function "{fill.name}"')

View file

@ -46,7 +46,7 @@ class ParamAnnotator:
""" """
return None return None
def convert_param(self, objects, path_prefix) -> None: def convert_param(self, objects) -> None:
""" valid and convert param """ valid and convert param
""" """
for obj in objects: for obj in objects:
@ -64,32 +64,27 @@ class ParamAnnotator:
msg = _(f'"{param.type}" parameter must not have a value') msg = _(f'"{param.type}" parameter must not have a value')
raise DictConsistencyError(msg, 40, obj.xmlfiles) raise DictConsistencyError(msg, 40, obj.xmlfiles)
elif param.type == 'variable': elif param.type == 'variable':
if not isinstance(param.text, self.objectspace.variable): try:
try: path, suffix = self.objectspace.paths.get_variable_path(param.text,
param.text, suffix = self.objectspace.paths.get_variable_with_suffix(param.text, obj.namespace,
obj.namespace, param.xmlfiles,
param.xmlfiles, )
path_prefix, param.text = self.objectspace.paths.get_variable(path)
) if variable_type and param.text.type != variable_type:
if variable_type and param.text.type != variable_type: msg = _(f'"{obj.name}" has type "{variable_type}" but param '
msg = _(f'"{obj.name}" has type "{variable_type}" but param ' f'has type "{param.text.type}"')
f'has type "{param.text.type}"') raise DictConsistencyError(msg, 26, param.xmlfiles)
raise DictConsistencyError(msg, 26, param.xmlfiles) if suffix:
if suffix: param.suffix = suffix
param.suffix = suffix family_path = self.objectspace.paths.get_variable_family_path(path)
namespace = param.text.namespace namespace = param.text.namespace
family_path = self.objectspace.paths.get_variable_family_path(param.text.path, param.family = self.objectspace.paths.get_family(family_path,
namespace, namespace,
force_path_prefix=path_prefix, )
) except DictConsistencyError as err:
param.family = self.objectspace.paths.get_family(family_path, if err.errno != 42 or not param.optional:
namespace, raise err
path_prefix, param_to_delete.append(param_idx)
)
except DictConsistencyError as err:
if err.errno != 42 or not param.optional:
raise err
param_to_delete.append(param_idx)
elif param.type == 'function': elif param.type == 'function':
if not self.allow_function: if not self.allow_function:
msg = _(f'cannot use "function" type') msg = _(f'cannot use "function" type')
@ -106,7 +101,7 @@ class ParamAnnotator:
# no param.text # no param.text
if param.type == 'suffix': if param.type == 'suffix':
for target in obj.target: for target in obj.target:
if not self.objectspace.paths.is_dynamic(target.name): if not self.objectspace.paths.variable_is_dynamic(target.name.path):
target_name = target.name target_name = target.name
if isinstance(target_name, self.objectspace.variable): if isinstance(target_name, self.objectspace.variable):
target_name = target_name.name target_name = target_name.name
@ -115,7 +110,7 @@ class ParamAnnotator:
raise DictConsistencyError(msg, 53, obj.xmlfiles) raise DictConsistencyError(msg, 53, obj.xmlfiles)
elif param.type == 'index': elif param.type == 'index':
for target in obj.target: for target in obj.target:
if not self.objectspace.paths.is_follower(target.name): if not self.objectspace.paths.is_follower(target.name.path):
msg = _(f'"{param.type}" parameter cannot be set with target ' msg = _(f'"{param.type}" parameter cannot be set with target '
f'"{target.name.name}" which is not a follower variable') f'"{target.name.name}" which is not a follower variable')
raise DictConsistencyError(msg, 60, obj.xmlfiles) raise DictConsistencyError(msg, 60, obj.xmlfiles)

View file

@ -42,16 +42,8 @@ class Annotator(Walk):
*args *args
) -> None: ) -> None:
self.objectspace = objectspace self.objectspace = objectspace
services = [] if hasattr(self.objectspace.space, 'services'):
if not self.objectspace.paths.has_path_prefix() and hasattr(self.objectspace.space, 'services'): self.convert_services()
services.append(self.objectspace.space.services)
elif hasattr(self.objectspace.space, 'variables'):
for path_prefix in self.objectspace.paths.get_path_prefixes():
if path_prefix in self.objectspace.space.variables and \
hasattr(self.objectspace.space.variables[path_prefix], 'services'):
services.append(self.objectspace.space.variables[path_prefix].services)
for service in services:
self.convert_services(service)
if hasattr(self.objectspace.space, 'variables'): if hasattr(self.objectspace.space, 'variables'):
self.convert_family() self.convert_family()
self.convert_variable() self.convert_variable()
@ -65,12 +57,12 @@ class Annotator(Walk):
if isinstance(variable, self.objectspace.variable) and variable.hidden is True and \ if isinstance(variable, self.objectspace.variable) and variable.hidden is True and \
variable.name != self.objectspace.rougailconfig['auto_freeze_variable']: variable.name != self.objectspace.rougailconfig['auto_freeze_variable']:
if not variable.auto_freeze and \ if not variable.auto_freeze and \
not hasattr(variable, 'provider') and not hasattr(variable, 'supplier'): not hasattr(variable, 'provider'):
variable.frozen = True variable.frozen = True
if not variable.auto_save and \ if not variable.auto_save and \
not variable.auto_freeze and \ not variable.auto_freeze and \
'force_default_on_freeze' not in vars(variable) and \ 'force_default_on_freeze' not in vars(variable) and \
not hasattr(variable, 'provider') and not hasattr(variable, 'supplier'): not hasattr(variable, 'provider'):
variable.force_default_on_freeze = True variable.force_default_on_freeze = True
if not hasattr(variable, 'properties'): if not hasattr(variable, 'properties'):
variable.properties = [] variable.properties = []
@ -80,11 +72,6 @@ class Annotator(Walk):
# for subprop in CONVERT_PROPERTIES.get(prop, [prop]): # for subprop in CONVERT_PROPERTIES.get(prop, [prop]):
variable.properties.append(prop) variable.properties.append(prop)
setattr(variable, prop, None) setattr(variable, prop, None)
if hasattr(variable, 'unique') and variable.unique != 'nil':
if variable.unique == 'False':
variable.properties.append('notunique')
else:
variable.properties.append('unique')
if hasattr(variable, 'mode') and variable.mode: if hasattr(variable, 'mode') and variable.mode:
variable.properties.append(variable.mode) variable.properties.append(variable.mode)
variable.mode = None variable.mode = None
@ -97,13 +84,13 @@ class Annotator(Walk):
if not variable.properties: if not variable.properties:
del variable.properties del variable.properties
def convert_services(self, services) -> None: def convert_services(self) -> None:
"""convert services """convert services
""" """
self.convert_property(services) self.convert_property(self.objectspace.space.services)
for services_ in services.service.values(): for services in self.objectspace.space.services.service.values():
self.convert_property(services_) self.convert_property(services)
for service in vars(services_).values(): for service in vars(services).values():
if not isinstance(service, self.objectspace.family): if not isinstance(service, self.objectspace.family):
continue continue
self.convert_property(service) self.convert_property(service)

View file

@ -53,39 +53,23 @@ class Annotator:
*args, *args,
) -> None: ) -> None:
self.objectspace = objectspace self.objectspace = objectspace
self.uniq_overrides = {} self.uniq_overrides = []
if 'network_type' not in self.objectspace.types: if 'network_type' not in self.objectspace.types:
self.objectspace.types['network_type'] = self.objectspace.types['ip_type'] self.objectspace.types['network_type'] = self.objectspace.types['ip_type']
services = [] if hasattr(self.objectspace.space, 'services'):
if not self.objectspace.paths.has_path_prefix(): if not hasattr(self.objectspace.space.services, 'service'):
self.uniq_overrides[None] = [] del self.objectspace.space.services
if hasattr(self.objectspace.space, 'services'): else:
if not hasattr(self.objectspace.space.services, 'service'): self.convert_services()
del self.objectspace.space.services
else:
services.append((None, 'services', self.objectspace.space.services))
elif hasattr(self.objectspace.space, 'variables'):
for path_prefix in self.objectspace.paths.get_path_prefixes():
self.uniq_overrides[path_prefix] = []
root_path = f'{path_prefix}.services'
if not path_prefix in self.objectspace.space.variables or \
not hasattr(self.objectspace.space.variables[path_prefix], 'services'):
continue
if not hasattr(self.objectspace.space.variables[path_prefix].services, 'service'):
del self.objectspace.space.variables[path_prefix].services
else:
services.append((path_prefix, root_path, self.objectspace.space.variables[path_prefix].services))
for path_prefix, root_path, service in services:
self.convert_services(path_prefix, root_path, service)
def convert_services(self, path_prefix, root_path, services): def convert_services(self):
"""convert services to variables """convert services to variables
""" """
services.hidden = True self.objectspace.space.services.hidden = True
services.name = 'services' self.objectspace.space.services.name = 'services'
services.doc = 'services' self.objectspace.space.services.doc = 'services'
services.path = root_path self.objectspace.space.services.path = 'services'
for service_name, service in services.service.items(): for service_name, service in self.objectspace.space.services.service.items():
service.name = normalize_family(service_name) service.name = normalize_family(service_name)
activate_obj = self._generate_element('boolean', activate_obj = self._generate_element('boolean',
None, None,
@ -93,26 +77,19 @@ class Annotator:
'activate', 'activate',
not service.disabled, not service.disabled,
service, service,
f'{root_path}.{service.name}', '.'.join(['services', service.name, 'activate']),
path_prefix,
) )
service.disabled = None service.disabled = None
dico = dict(vars(service)) for elttype, values in dict(vars(service)).items():
if 'type' not in dico:
if service.manage:
dico['type'] = service.type
else:
dico['type'] = 'none'
for elttype, values in dico.items():
if elttype == 'servicelist': if elttype == 'servicelist':
self.objectspace.paths.list_conditions[path_prefix].setdefault('servicelist', self.objectspace.list_conditions.setdefault('servicelist',
{}).setdefault( {}).setdefault(
values, values,
[]).append(activate_obj) []).append(activate_obj)
continue continue
if elttype in ERASED_ATTRIBUTES: if elttype in ERASED_ATTRIBUTES:
continue continue
if not service.manage and elttype not in ALLOW_ATTRIBUT_NOT_MANAGE and (elttype != 'type' or values != 'none'): if not service.manage and elttype not in ALLOW_ATTRIBUT_NOT_MANAGE:
msg = _(f'unmanage service cannot have "{elttype}"') msg = _(f'unmanage service cannot have "{elttype}"')
raise DictConsistencyError(msg, 66, service.xmlfiles) raise DictConsistencyError(msg, 66, service.xmlfiles)
if isinstance(values, (dict, list)): if isinstance(values, (dict, list)):
@ -120,14 +97,10 @@ class Annotator:
eltname = elttype + 's' eltname = elttype + 's'
else: else:
eltname = elttype eltname = elttype
if hasattr(service, 'servicelist'): path = '.'.join(['services', service.name, eltname])
if isinstance(values, dict):
for key, value in values.items():
setattr(value, 'servicelist', service.servicelist)
family = self._gen_family(eltname, family = self._gen_family(eltname,
f'{root_path}.{service.name}', path,
service.xmlfiles, service.xmlfiles,
path_prefix,
with_informations=False, with_informations=False,
) )
if isinstance(values, dict): if isinstance(values, dict):
@ -135,25 +108,22 @@ class Annotator:
family.family = self.make_group_from_elts(service_name, family.family = self.make_group_from_elts(service_name,
elttype, elttype,
values, values,
f'{root_path}.{service.name}.{eltname}', path,
root_path,
path_prefix,
) )
setattr(service, elttype, family) setattr(service, elttype, family)
else: else:
if not hasattr(service, 'information'): if not hasattr(service, 'information'):
service.information = self.objectspace.information(service.xmlfiles) service.information = self.objectspace.information(service.xmlfiles)
setattr(service.information, elttype, values) setattr(service.information, elttype, values)
service.path = f'{root_path}.{service.name}' service.path = '.'.join(['services', service.name])
manage = self._generate_element('boolean', manage = self._generate_element('boolean',
None, None,
None, None,
'manage', 'manage',
service.manage, service.manage,
service, service,
f'{root_path}.{service.name}', '.'.join(['services', service.name, 'manage']),
path_prefix, )
)
service.variable = [activate_obj, manage] service.variable = [activate_obj, manage]
service.doc = service_name service.doc = service_name
@ -162,8 +132,6 @@ class Annotator:
elttype, elttype,
elts, elts,
path, path,
root_path,
path_prefix,
): ):
"""Splits each objects into a group (and `OptionDescription`, in tiramisu terms) """Splits each objects into a group (and `OptionDescription`, in tiramisu terms)
and build elements and its attributes (the `Options` in tiramisu terms) and build elements and its attributes (the `Options` in tiramisu terms)
@ -176,17 +144,13 @@ class Annotator:
if hasattr(self, update_elt): if hasattr(self, update_elt):
getattr(self, update_elt)(elt, getattr(self, update_elt)(elt,
service_name, service_name,
path_prefix,
) )
c_name, subpath = self._get_name_path(elt, c_name, subpath = self._get_name_path(elt,
path, path,
root_path,
path_prefix,
) )
family = self._gen_family(c_name, family = self._gen_family(c_name,
subpath.rsplit('.', 1)[0], subpath,
elt.xmlfiles, elt.xmlfiles,
path_prefix,
) )
family.variable = [] family.variable = []
if hasattr(elt, 'disabled'): if hasattr(elt, 'disabled'):
@ -199,18 +163,17 @@ class Annotator:
'activate', 'activate',
not disabled, not disabled,
elt, elt,
subpath, '.'.join([subpath, 'activate']),
path_prefix,
) )
for key in dir(elt): for key in dir(elt):
if key.startswith('_') or key.endswith('_type') or key in ERASED_ATTRIBUTES2: if key.startswith('_') or key.endswith('_type') or key in ERASED_ATTRIBUTES2:
continue continue
value = getattr(elt, key) value = getattr(elt, key)
if key in [listname, 'servicelist']: if key == listname:
self.objectspace.paths.list_conditions[path_prefix].setdefault(key, self.objectspace.list_conditions.setdefault(listname,
{}).setdefault( {}).setdefault(
value, value,
[]).append(activate_obj) []).append(activate_obj)
continue continue
if key == 'name': if key == 'name':
dtd_key_type = elttype + '_type' dtd_key_type = elttype + '_type'
@ -226,8 +189,7 @@ class Annotator:
key, key,
value, value,
elt, elt,
subpath, f'{subpath}.{key}'
path_prefix,
)) ))
else: else:
setattr(family.information, key, value) setattr(family.information, key, value)
@ -239,8 +201,6 @@ class Annotator:
def _get_name_path(self, def _get_name_path(self,
elt, elt,
path: str, path: str,
root_path: str,
path_prefix: str,
) -> Tuple[str, str]: ) -> Tuple[str, str]:
# create element name, if already exists, add _xx to be uniq # create element name, if already exists, add _xx to be uniq
if hasattr(elt, 'source') and elt.source: if hasattr(elt, 'source') and elt.source:
@ -254,7 +214,7 @@ class Annotator:
c_name += f'_{idx}' c_name += f'_{idx}'
subpath = '{}.{}'.format(path, normalize_family(c_name)) subpath = '{}.{}'.format(path, normalize_family(c_name))
try: try:
self.objectspace.paths.get_family(subpath, root_path, path_prefix) self.objectspace.paths.get_family(subpath, 'services')
except DictConsistencyError as err: except DictConsistencyError as err:
if err.errno == 42: if err.errno == 42:
return c_name, subpath return c_name, subpath
@ -262,9 +222,8 @@ class Annotator:
def _gen_family(self, def _gen_family(self,
name, name,
subpath, path,
xmlfiles, xmlfiles,
path_prefix,
with_informations=True, with_informations=True,
): ):
family = self.objectspace.family(xmlfiles) family = self.objectspace.family(xmlfiles)
@ -272,10 +231,9 @@ class Annotator:
family.doc = name family.doc = name
family.mode = None family.mode = None
self.objectspace.paths.add_family('services', self.objectspace.paths.add_family('services',
subpath, path,
family, family,
False, None,
force_path_prefix=path_prefix,
) )
if with_informations: if with_informations:
family.information = self.objectspace.information(xmlfiles) family.information = self.objectspace.information(xmlfiles)
@ -289,19 +247,13 @@ class Annotator:
value, value,
elt, elt,
path, path,
path_prefix,
): # pylint: disable=R0913 ): # pylint: disable=R0913
variable = self.objectspace.variable(elt.xmlfiles) variable = self.objectspace.variable(elt.xmlfiles)
variable.name = normalize_family(key) variable.name = normalize_family(key)
variable.mode = None variable.mode = None
variable.type = type_ variable.type = type_
if type_ == 'symlink': if type_ == 'symlink':
variable.opt = self.objectspace.paths.get_variable(value, variable.opt = self.objectspace.paths.get_variable(value, xmlfiles=elt.xmlfiles)
self.objectspace.rougailconfig['variable_namespace'],
xmlfiles=elt.xmlfiles,
force_path_prefix=path_prefix,
add_path_prefix=True,
)
variable.multi = None variable.multi = None
needed_type = self.objectspace.types[dtd_key_type] needed_type = self.objectspace.types[dtd_key_type]
if needed_type not in ('variable', variable.opt.type): if needed_type not in ('variable', variable.opt.type):
@ -315,22 +267,22 @@ class Annotator:
variable.namespace = 'services' variable.namespace = 'services'
self.objectspace.paths.add_variable('services', self.objectspace.paths.add_variable('services',
path, path,
'service',
False,
variable, variable,
force_path_prefix=path_prefix
) )
return variable return variable
def _update_override(self, def _update_override(self,
override, override,
service_name, service_name,
path_prefix,
): ):
if service_name in self.uniq_overrides[path_prefix]: if service_name in self.uniq_overrides:
msg = _('only one override is allowed by service, ' msg = _('only one override is allowed by service, '
'please use a variable multiple if you want have more than one IP') 'please use a variable multiple if you want have more than one IP')
raise DictConsistencyError(msg, 69, override.xmlfiles) raise DictConsistencyError(msg, 69, override.xmlfiles)
self.uniq_overrides[path_prefix].append(service_name) self.uniq_overrides.append(service_name)
override.name = service_name override.name = service_name
if not hasattr(override, 'source'): if not hasattr(override, 'source'):
override.source = service_name override.source = service_name
@ -338,7 +290,6 @@ class Annotator:
@staticmethod @staticmethod
def _update_file(file_, def _update_file(file_,
service_name, service_name,
path_prefix,
): ):
if not hasattr(file_, 'file_type') or file_.file_type == "filename": if not hasattr(file_, 'file_type') or file_.file_type == "filename":
if not hasattr(file_, 'source'): if not hasattr(file_, 'source'):
@ -351,14 +302,8 @@ class Annotator:
def _update_ip(self, def _update_ip(self,
ip, ip,
service_name, service_name,
path_prefix,
) -> None: ) -> None:
variable = self.objectspace.paths.get_variable(ip.name, variable = self.objectspace.paths.get_variable(ip.name, ip.xmlfiles)
ip.namespace,
xmlfiles=ip.xmlfiles,
force_path_prefix=path_prefix,
add_path_prefix=True,
)
if variable.type not in ['ip', 'network', 'network_cidr']: if variable.type not in ['ip', 'network', 'network_cidr']:
msg = _(f'ip cannot be linked to "{variable.type}" variable "{ip.name}"') msg = _(f'ip cannot be linked to "{variable.type}" variable "{ip.name}"')
raise DictConsistencyError(msg, 70, ip.xmlfiles) raise DictConsistencyError(msg, 70, ip.xmlfiles)
@ -369,12 +314,7 @@ class Annotator:
msg = _(f'ip with ip_type "{variable.type}" must have netmask') msg = _(f'ip with ip_type "{variable.type}" must have netmask')
raise DictConsistencyError(msg, 64, ip.xmlfiles) raise DictConsistencyError(msg, 64, ip.xmlfiles)
if hasattr(ip, 'netmask'): if hasattr(ip, 'netmask'):
netmask = self.objectspace.paths.get_variable(ip.netmask, netmask = self.objectspace.paths.get_variable(ip.netmask, ip.xmlfiles)
ip.namespace,
xmlfiles=ip.xmlfiles,
force_path_prefix=path_prefix,
add_path_prefix=True,
)
if netmask.type != 'netmask': if netmask.type != 'netmask':
msg = _(f'netmask in ip must have type "netmask", not "{netmask.type}"') msg = _(f'netmask in ip must have type "netmask", not "{netmask.type}"')
raise DictConsistencyError(msg, 65, ip.xmlfiles) raise DictConsistencyError(msg, 65, ip.xmlfiles)

View file

@ -26,15 +26,13 @@ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
""" """
from rougail.i18n import _ from rougail.i18n import _
from rougail.error import DictConsistencyError from rougail.error import DictConsistencyError
from rougail.annotator.variable import Walk
class TargetAnnotator(Walk): class TargetAnnotator:
"""Target annotator """Target annotator
""" """
def convert_target(self, def convert_target(self,
objects, objects,
path_prefix,
) -> None: ) -> None:
""" valid and convert param """ valid and convert param
""" """
@ -54,15 +52,13 @@ class TargetAnnotator(Walk):
# let's replace the target by the path # let's replace the target by the path
try: try:
if target.type == 'variable': if target.type == 'variable':
if not isinstance(target.name, self.objectspace.variable): path, suffix = self.objectspace.paths.get_variable_path(target.name,
target.name, suffix = self.objectspace.paths.get_variable_with_suffix(target.name, obj.namespace,
obj.namespace, )
target.xmlfiles, target.name = self.objectspace.paths.get_variable(path)
path_prefix, if suffix:
) msg = _(f'target to {target.name.path} with suffix is not allowed')
if suffix: raise DictConsistencyError(msg, 35, obj.xmlfiles)
msg = _(f'target to {target.name.path} with suffix is not allowed')
raise DictConsistencyError(msg, 35, obj.xmlfiles)
elif self.only_variable: elif self.only_variable:
msg = _(f'target to "{target.name}" with param type "{target.type}" ' msg = _(f'target to "{target.name}" with param type "{target.type}" '
f'is not allowed') f'is not allowed')
@ -77,8 +73,6 @@ class TargetAnnotator(Walk):
raise DictConsistencyError(msg, 51, target.xmlfiles) raise DictConsistencyError(msg, 51, target.xmlfiles)
target.name = self.objectspace.paths.get_family(target.name, target.name = self.objectspace.paths.get_family(target.name,
obj.namespace, obj.namespace,
path_prefix,
allow_variable_namespace=True,
) )
elif target.type.endswith('list') and \ elif target.type.endswith('list') and \
obj.name not in ['disabled_if_in', 'disabled_if_not_in']: obj.name not in ['disabled_if_in', 'disabled_if_not_in']:

View file

@ -75,13 +75,9 @@ class Annotator(Walk): # pylint: disable=R0903
if variable.value[0].type == 'calculation': if variable.value[0].type == 'calculation':
variable.default = variable.value[0] variable.default = variable.value[0]
elif variable.multi: elif variable.multi:
if self.objectspace.paths.is_follower(variable): if not self.objectspace.paths.is_follower(variable.path):
if variable.multi != 'submulti' and len(variable.value) != 1:
msg = _(f'the follower "{variable.name}" without multi attribute can only have one value')
raise DictConsistencyError(msg, 87, variable.xmlfiles)
else:
variable.default = [value.name for value in variable.value] variable.default = [value.name for value in variable.value]
if not self.objectspace.paths.is_leader(variable): if not self.objectspace.paths.is_leader(variable.path):
if variable.multi == 'submulti': if variable.multi == 'submulti':
variable.default_multi = [value.name for value in variable.value] variable.default_multi = [value.name for value in variable.value]
else: else:

View file

@ -27,7 +27,7 @@ Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
from rougail.i18n import _ from rougail.i18n import _
from rougail.error import DictConsistencyError from rougail.error import DictConsistencyError
from rougail.objspace import convert_boolean, get_variables from rougail.objspace import convert_boolean
CONVERT_OPTION = {'number': dict(opttype="IntOption", func=int), CONVERT_OPTION = {'number': dict(opttype="IntOption", func=int),
@ -56,7 +56,7 @@ CONVERT_OPTION = {'number': dict(opttype="IntOption", func=int),
'allow_ip': False}), 'allow_ip': False}),
'web_address': dict(opttype="URLOption", initkwargs={'allow_ip': True, 'web_address': dict(opttype="URLOption", initkwargs={'allow_ip': True,
'allow_without_dot': True}), 'allow_without_dot': True}),
'port': dict(opttype="PortOption", initkwargs={'allow_private': True, 'allow_protocol': True}), 'port': dict(opttype="PortOption", initkwargs={'allow_private': True}),
'mac': dict(opttype="MACOption"), 'mac': dict(opttype="MACOption"),
'cidr': dict(opttype="IPOption", initkwargs={'cidr': True}), 'cidr': dict(opttype="IPOption", initkwargs={'cidr': True}),
'network_cidr': dict(opttype="NetworkOption", initkwargs={'cidr': True}), 'network_cidr': dict(opttype="NetworkOption", initkwargs={'cidr': True}),
@ -71,56 +71,35 @@ class Walk:
def get_variables(self): def get_variables(self):
"""Iter all variables from the objectspace """Iter all variables from the objectspace
""" """
yield from get_variables(self.objectspace) for family in self.objectspace.space.variables.values():
yield from self._get_variables(family)
def get_families(self, def _get_variables(self,
with_parent: bool=False, family: 'self.objectspace.family',
): ):
if not hasattr(family, 'variable'):
return
for variable in family.variable.values():
if isinstance(variable, self.objectspace.family):
yield from self._get_variables(variable)
else:
yield variable
def get_families(self):
"""Iter all families from the objectspace """Iter all families from the objectspace
""" """
for family in self.objectspace.space.variables.values(): for family in self.objectspace.space.variables.values():
yield from self._get_families(family, None, with_parent) yield from self._get_families(family)
def _get_families(self, def _get_families(self,
family: 'self.objectspace.family', family: 'self.objectspace.family',
old_family: 'self.objectspace.family',
with_parent: bool,
): ):
if with_parent: yield family
yield family, old_family, if not hasattr(family, 'variable'):
if hasattr(family, 'variable'): return
if not with_parent: for fam in family.variable.values():
yield family if isinstance(fam, self.objectspace.family):
for fam in family.variable.values(): yield from self._get_families(fam)
if isinstance(fam, self.objectspace.family):
yield from self._get_families(fam, family, with_parent)
if hasattr(family, 'variables'):
for fam in family.variables.values():
yield from self._get_families(fam, family, with_parent)
def get_constraints(self,
create: bool=False,
path_prefix: str=None,
):
if not self.objectspace.paths.has_path_prefix():
if hasattr(self.objectspace.space, 'constraints'):
yield None, self.objectspace.space.constraints
elif create:
self.objectspace.space.constraints = self.objectspace.constraints(None)
yield None, self.objectspace.space.constraints
else:
if path_prefix:
path_prefixes = [path_prefix]
else:
path_prefixes = self.objectspace.paths.get_path_prefixes()
for path_prefix in path_prefixes:
if hasattr(self.objectspace.space, 'variables') and \
path_prefix in self.objectspace.space.variables and \
hasattr(self.objectspace.space.variables[path_prefix], 'constraints'):
yield path_prefix, self.objectspace.space.variables[path_prefix].constraints
elif create:
self.objectspace.space.variables[path_prefix].constraints = self.objectspace.constraints(None)
yield path_prefix, self.objectspace.space.variables[path_prefix].constraints
class Annotator(Walk): # pylint: disable=R0903 class Annotator(Walk): # pylint: disable=R0903
@ -187,10 +166,7 @@ class Annotator(Walk): # pylint: disable=R0903
elif choice.type == 'space': elif choice.type == 'space':
choice.name = ' ' choice.name = ' '
elif choice.type == 'variable': elif choice.type == 'variable':
choice.name = self.objectspace.paths.get_variable(choice.name, choice.name = self.objectspace.paths.get_variable(choice.name)
variable.namespace,
force_path_prefix=variable.path_prefix,
)
if not choice.name.multi: if not choice.name.multi:
msg = _(f'only multi "variable" is allowed for a choice ' msg = _(f'only multi "variable" is allowed for a choice '
f'of variable "{variable.name}"') f'of variable "{variable.name}"')
@ -210,10 +186,10 @@ class Annotator(Walk): # pylint: disable=R0903
f'of all expected values ({values})') f'of all expected values ({values})')
raise DictConsistencyError(msg, 15, value.xmlfiles) raise DictConsistencyError(msg, 15, value.xmlfiles)
ref_choice = variable.choice[0] ref_choice = variable.choice[0]
self.objectspace.paths.set_valid_enums(variable.path, self.objectspace.valid_enums[variable.path] = {'type': ref_choice.type,
values, 'values': values,
variable.path_prefix, 'xmlfiles': ref_choice.xmlfiles,
) }
elif variable.type == 'choice': elif variable.type == 'choice':
msg = _(f'choice is mandatory for the variable "{variable.name}" with choice type') msg = _(f'choice is mandatory for the variable "{variable.name}" with choice type')
raise DictConsistencyError(msg, 4, variable.xmlfiles) raise DictConsistencyError(msg, 4, variable.xmlfiles)

View file

@ -42,7 +42,6 @@ RougailConfig = {'dictionaries_dir': [join(ROUGAILROOT, 'dictionaries')],
'functions_file': join(ROUGAILROOT, 'functions.py'), 'functions_file': join(ROUGAILROOT, 'functions.py'),
'tmpfile_dest_dir': '/usr/local/lib', 'tmpfile_dest_dir': '/usr/local/lib',
'variable_namespace': 'rougail', 'variable_namespace': 'rougail',
'variable_namespace_description': 'Rougail',
'auto_freeze_variable': 'server_deployed', 'auto_freeze_variable': 'server_deployed',
'internal_functions': [], 'internal_functions': [],
'multi_functions': [], 'multi_functions': [],
@ -56,10 +55,4 @@ RougailConfig = {'dictionaries_dir': [join(ROUGAILROOT, 'dictionaries')],
'default_files_group': 'root', 'default_files_group': 'root',
'default_files_included': 'no', 'default_files_included': 'no',
'default_overrides_engine': 'creole', 'default_overrides_engine': 'creole',
'default_service_names_engine': 'none',
'default_systemd_directory': '/systemd',
'base_option_name': 'baseoption',
'export_with_import': True,
'force_convert_dyn_option_description': False,
'suffix': '',
} }

View file

@ -50,8 +50,6 @@ from .xmlreflector import XMLReflector
from .tiramisureflector import TiramisuReflector from .tiramisureflector import TiramisuReflector
from .annotator import SpaceAnnotator from .annotator import SpaceAnnotator
from .error import DictConsistencyError from .error import DictConsistencyError
from .providersupplier import provider_supplier
from .utils import normalize_family
class RougailConvert: class RougailConvert:
@ -62,92 +60,53 @@ class RougailConvert:
) -> None: ) -> None:
if rougailconfig is None: if rougailconfig is None:
rougailconfig = RougailConfig rougailconfig = RougailConfig
self.rougailconfig = rougailconfig xmlreflector = XMLReflector(rougailconfig)
xmlreflector = XMLReflector(self.rougailconfig) rougailobjspace = RougailObjSpace(xmlreflector,
self.rougailobjspace = RougailObjSpace(xmlreflector, rougailconfig,
self.rougailconfig, )
) self._load_dictionaries(xmlreflector,
self.internal_functions = self.rougailconfig['internal_functions'] rougailobjspace,
self.functions_file = self.rougailconfig['functions_file'] rougailconfig['variable_namespace'],
if not isinstance(self.functions_file, list): rougailconfig['dictionaries_dir'],
self.functions_file = [self.functions_file]
self.dictionaries = False
self.annotator = False
self.reflector = None
def load_dictionaries(self,
path_prefix: str=None,
) -> None:
self.rougailobjspace.paths.set_path_prefix(normalize_family(path_prefix))
self._load_dictionaries(self.rougailobjspace.xmlreflector,
self.rougailconfig['variable_namespace'],
self.rougailconfig['dictionaries_dir'],
path_prefix,
self.rougailconfig['variable_namespace_description'],
) )
for namespace, extra_dir in self.rougailconfig['extra_dictionaries'].items(): for namespace, extra_dir in rougailconfig['extra_dictionaries'].items():
if namespace in ['services', self.rougailconfig['variable_namespace']]: if namespace in ['services', rougailconfig['variable_namespace']]:
msg = _(f'Namespace name "{namespace}" is not allowed') msg = _(f'Namespace name "{namespace}" is not allowed')
raise DictConsistencyError(msg, 21, None) raise DictConsistencyError(msg, 21, None)
self._load_dictionaries(self.rougailobjspace.xmlreflector, self._load_dictionaries(xmlreflector,
rougailobjspace,
namespace, namespace,
extra_dir, extra_dir,
path_prefix,
) )
if hasattr(self.rougailobjspace.space, 'variables'): functions_file = rougailconfig['functions_file']
provider_supplier(self.rougailobjspace, if not isinstance(functions_file, list):
path_prefix, functions_file = [functions_file]
) SpaceAnnotator(rougailobjspace,
self.dictionaries = True functions_file,
)
self.output = TiramisuReflector(rougailobjspace,
functions_file,
rougailconfig['internal_functions'],
).get_text() + '\n'
def _load_dictionaries(self, @staticmethod
xmlreflector: XMLReflector, def _load_dictionaries(xmlreflector: XMLReflector,
rougailobjspace: RougailObjSpace,
namespace: str, namespace: str,
xmlfolders: List[str], xmlfolders: List[str],
path_prefix: str,
namespace_description: str=None,
) -> List[str]: ) -> List[str]:
for xmlfile, document in xmlreflector.load_xml_from_folders(xmlfolders): for xmlfile, document in xmlreflector.load_xml_from_folders(xmlfolders):
self.rougailobjspace.xml_parse_document(xmlfile, rougailobjspace.xml_parse_document(xmlfile,
document, document,
namespace, namespace,
namespace_description, )
path_prefix,
)
def annotate(self):
if self.annotator:
raise DictConsistencyError(_('Cannot execute annotate multiple time'), 85, None)
SpaceAnnotator(self.rougailobjspace,
self.functions_file,
)
self.annotator = True
def reflexion(self,
exclude_imports: list=[],
):
if not self.dictionaries:
self.load_dictionaries()
if not self.annotator:
self.annotate()
if self.reflector:
raise DictConsistencyError(_('Cannot execute reflexion multiple time'), 86, None)
functions_file = [func for func in self.functions_file if func not in exclude_imports]
self.reflector = TiramisuReflector(self.rougailobjspace,
functions_file,
self.internal_functions,
self.rougailconfig,
)
def save(self, def save(self,
filename: str, filename: str,
) -> str: ) -> str:
"""Return tiramisu object declaration as a string """Return tiramisu object declaration as a string
""" """
if self.reflector is None:
self.reflexion()
output = self.reflector.get_text() + '\n'
if filename: if filename:
with open(filename, 'w') as tiramisu: with open(filename, 'w') as tiramisu:
tiramisu.write(output) tiramisu.write(self.output)
return output return self.output

View file

@ -53,7 +53,7 @@
<!ATTLIST service disabled (True|False) "False"> <!ATTLIST service disabled (True|False) "False">
<!ATTLIST service engine (none|creole|jinja2) #IMPLIED> <!ATTLIST service engine (none|creole|jinja2) #IMPLIED>
<!ATTLIST service target CDATA #IMPLIED> <!ATTLIST service target CDATA #IMPLIED>
<!ATTLIST service type (service|mount|swap|timer|target) "service"> <!ATTLIST service type (service|mount|swap|timer) "service">
<!ATTLIST service undisable (True|False) "False"> <!ATTLIST service undisable (True|False) "False">
<!ELEMENT ip (#PCDATA)> <!ELEMENT ip (#PCDATA)>
@ -101,7 +101,6 @@
<!ATTLIST variable hidden (True|False) "False"> <!ATTLIST variable hidden (True|False) "False">
<!ATTLIST variable disabled (True|False) "False"> <!ATTLIST variable disabled (True|False) "False">
<!ATTLIST variable multi (True|False) "False"> <!ATTLIST variable multi (True|False) "False">
<!ATTLIST variable unique (nil|True|False) "nil">
<!ATTLIST variable redefine (True|False) "False"> <!ATTLIST variable redefine (True|False) "False">
<!ATTLIST variable exists (True|False) "True"> <!ATTLIST variable exists (True|False) "True">
<!ATTLIST variable mandatory (True|False) "False"> <!ATTLIST variable mandatory (True|False) "False">
@ -113,7 +112,6 @@
<!ATTLIST variable remove_condition (True|False) "False"> <!ATTLIST variable remove_condition (True|False) "False">
<!ATTLIST variable remove_fill (True|False) "False"> <!ATTLIST variable remove_fill (True|False) "False">
<!ATTLIST variable provider CDATA #IMPLIED> <!ATTLIST variable provider CDATA #IMPLIED>
<!ATTLIST variable supplier CDATA #IMPLIED>
<!ATTLIST variable test CDATA #IMPLIED> <!ATTLIST variable test CDATA #IMPLIED>
<!ELEMENT value (#PCDATA)> <!ELEMENT value (#PCDATA)>

View file

@ -29,7 +29,7 @@ from typing import Optional
from .i18n import _ from .i18n import _
from .xmlreflector import XMLReflector from .xmlreflector import XMLReflector
from .utils import valid_variable_family_name, normalize_family from .utils import valid_variable_family_name
from .error import SpaceObjShallNotBeUpdated, DictConsistencyError from .error import SpaceObjShallNotBeUpdated, DictConsistencyError
from .path import Path from .path import Path
@ -106,13 +106,14 @@ class RougailObjSpace:
self.paths = Path(rougailconfig) self.paths = Path(rougailconfig)
self.forced_text_elts_as_name = set(FORCED_TEXT_ELTS_AS_NAME) self.forced_text_elts_as_name = set(FORCED_TEXT_ELTS_AS_NAME)
self.list_conditions = {}
self.valid_enums = {}
self.booleans_attributs = [] self.booleans_attributs = []
self.has_dyn_option = False self.has_dyn_option = False
self.types = {} self.types = {}
self.make_object_space_classes(xmlreflector) self.make_object_space_classes(xmlreflector)
self.rougailconfig = rougailconfig self.rougailconfig = rougailconfig
self.xmlreflector = xmlreflector
def make_object_space_classes(self, def make_object_space_classes(self,
xmlreflector: XMLReflector, xmlreflector: XMLReflector,
@ -169,31 +170,14 @@ class RougailObjSpace:
xmlfile, xmlfile,
document, document,
namespace, namespace,
namespace_description,
path_prefix,
): ):
"""Parses a Rougail XML file and populates the RougailObjSpace """Parses a Rougail XML file and populates the RougailObjSpace
""" """
redefine_variables = [] redefine_variables = []
if path_prefix:
if not hasattr(self.space, 'variables'):
self.space.variables = {}
n_path_prefix = normalize_family(path_prefix)
if n_path_prefix not in self.space.variables:
space = self.variables([xmlfile])
space.name = n_path_prefix
space.doc = path_prefix
space.path = path_prefix
self.space.variables[n_path_prefix] = space
else:
space = self.space.variables[n_path_prefix]
else:
space = self.space
self._xml_parse(xmlfile, self._xml_parse(xmlfile,
document, document,
space, self.space,
namespace, namespace,
namespace_description,
redefine_variables, redefine_variables,
False, False,
) )
@ -203,22 +187,19 @@ class RougailObjSpace:
document, document,
space, space,
namespace, namespace,
namespace_description,
redefine_variables, redefine_variables,
is_dynamic, is_dynamic,
) -> None: ) -> None:
# var to check unique family name in a XML file # var to check unique family name in a XML file
family_names = [] family_names = []
for child in document: for child in document:
if not isinstance(child.tag, str):
# doesn't proceed the XML commentaries
continue
if is_dynamic: if is_dynamic:
is_sub_dynamic = True is_sub_dynamic = True
else: else:
is_sub_dynamic = child.attrib.get('dynamic') is not None is_sub_dynamic = document.attrib.get('dynamic') is not None
if namespace_description and child.tag == 'variables': if not isinstance(child.tag, str):
child.attrib['description'] = namespace_description # doesn't proceed the XML commentaries
continue
if child.tag == 'family': if child.tag == 'family':
if child.attrib['name'] in family_names: if child.attrib['name'] in family_names:
msg = _(f'Family "{child.attrib["name"]}" is set several times') msg = _(f'Family "{child.attrib["name"]}" is set several times')
@ -244,7 +225,6 @@ class RougailObjSpace:
self.remove(child, self.remove(child,
variableobj, variableobj,
redefine_variables, redefine_variables,
namespace,
) )
if not exists: if not exists:
self.set_path(namespace, self.set_path(namespace,
@ -253,11 +233,6 @@ class RougailObjSpace:
space, space,
is_sub_dynamic, is_sub_dynamic,
) )
elif isinstance(variableobj, self.variable):
if 'name' in document.attrib:
family_name = document.attrib['name']
else:
family_name = namespace
self.add_to_tree_structure(variableobj, self.add_to_tree_structure(variableobj,
space, space,
child, child,
@ -268,7 +243,6 @@ class RougailObjSpace:
child, child,
variableobj, variableobj,
namespace, namespace,
namespace_description,
redefine_variables, redefine_variables,
is_sub_dynamic, is_sub_dynamic,
) )
@ -344,10 +318,10 @@ class RougailObjSpace:
redefine = convert_boolean(subspace.get('redefine', default_redefine)) redefine = convert_boolean(subspace.get('redefine', default_redefine))
if redefine is True: if redefine is True:
if isinstance(existed_var, self.variable): # pylint: disable=E1101 if isinstance(existed_var, self.variable): # pylint: disable=E1101
# if namespace == self.rougailconfig['variable_namespace']: if namespace == self.rougailconfig['variable_namespace']:
# redefine_variables.append(name) redefine_variables.append(name)
# else: else:
redefine_variables.append(space.path + '.' + name) redefine_variables.append(space.path + '.' + name)
existed_var.xmlfiles.append(xmlfile) existed_var.xmlfiles.append(xmlfile)
return True, existed_var return True, existed_var
exists = convert_boolean(subspace.get('exists', True)) exists = convert_boolean(subspace.get('exists', True))
@ -375,7 +349,7 @@ class RougailObjSpace:
def get_existed_obj(self, def get_existed_obj(self,
name: str, name: str,
xmlfile: str, xmlfile: str,
space, space: str,
child, child,
namespace: str, namespace: str,
) -> None: ) -> None:
@ -386,19 +360,20 @@ class RougailObjSpace:
if child.tag == 'variable': # pylint: disable=E1101 if child.tag == 'variable': # pylint: disable=E1101
if namespace != self.rougailconfig['variable_namespace']: if namespace != self.rougailconfig['variable_namespace']:
name = space.path + '.' + name name = space.path + '.' + name
if not self.paths.path_is_defined(name, namespace): if not self.paths.path_is_defined(name):
return None return None
old_family_name = self.paths.get_variable_family_path(name, namespace) old_family_name = self.paths.get_variable_family_path(name)
if space.path != old_family_name: if space.path != old_family_name:
msg = _(f'Variable "{name}" was previously create in family "{old_family_name}", ' msg = _(f'Variable "{name}" was previously create in family "{old_family_name}", '
f'now it is in "{space.path}"') f'now it is in "{space.path}"')
raise DictConsistencyError(msg, 47, space.xmlfiles) raise DictConsistencyError(msg, 47, space.xmlfiles)
return self.paths.get_variable(name, namespace) return self.paths.get_variable(name)
# it's not a variable # it's not a family
tag = FORCE_TAG.get(child.tag, child.tag) tag = FORCE_TAG.get(child.tag, child.tag)
children = getattr(space, tag, {}) children = getattr(space, tag, {})
if name in children and isinstance(children[name], getattr(self, child.tag)): if name in children and isinstance(children[name], getattr(self, child.tag)):
return children[name] return children[name]
return None
def set_text(self, def set_text(self,
child, child,
@ -441,7 +416,6 @@ class RougailObjSpace:
child, child,
variableobj, variableobj,
redefine_variables, redefine_variables,
namespace,
): ):
"""Rougail object tree manipulations """Rougail object tree manipulations
""" """
@ -458,34 +432,23 @@ class RougailObjSpace:
self.remove_condition(variableobj.name) self.remove_condition(variableobj.name)
if child.attrib.get('remove_fill', False): if child.attrib.get('remove_fill', False):
self.remove_fill(variableobj.name) self.remove_fill(variableobj.name)
elif child.tag == 'fill': if child.tag == 'fill':
for target in child: for target in child:
if target.tag == 'target' and \ if target.tag == 'target' and target.text in redefine_variables:
self.paths.get_path(target.text, namespace) in redefine_variables:
self.remove_fill(target.text) self.remove_fill(target.text)
def remove_check(self, name): def remove_check(self, name):
"""Remove a check with a specified target """Remove a check with a specified target
""" """
constraints = self.get_constraints() if hasattr(self.space.constraints, 'check'):
if not constraints or not hasattr(constraints, 'check'): remove_checks = []
return for idx, check in enumerate(self.space.constraints.check): # pylint: disable=E1101
remove_checks = [] for target in check.target:
for idx, check in enumerate(constraints.check): # pylint: disable=E1101 if target.name == name:
for target in check.target: remove_checks.append(idx)
if target.name == name: remove_checks.sort(reverse=True)
remove_checks.append(idx) for idx in remove_checks:
remove_checks.sort(reverse=True) self.space.constraints.check.pop(idx) # pylint: disable=E1101
for idx in remove_checks:
constraints.check.pop(idx) # pylint: disable=E1101
def get_constraints(self):
path_prefix = self.paths.get_path_prefix()
if not path_prefix:
if hasattr(self.space, 'constraints'):
return self.space.constraints
elif hasattr(self.space.variables[path_prefix], 'constraints'):
return self.space.variables[path_prefix].constraints
def remove_condition(self, def remove_condition(self,
name: str, name: str,
@ -493,13 +456,12 @@ class RougailObjSpace:
"""Remove a condition with a specified source """Remove a condition with a specified source
""" """
remove_conditions = [] remove_conditions = []
constraints = self.get_constraints() for idx, condition in enumerate(self.space.constraints.condition): # pylint: disable=E1101
for idx, condition in enumerate(constraints.condition): # pylint: disable=E1101
if condition.source == name: if condition.source == name:
remove_conditions.append(idx) remove_conditions.append(idx)
remove_conditions.sort(reverse=True) remove_conditions.sort(reverse=True)
for idx in remove_conditions: for idx in remove_conditions:
del constraints.condition[idx] # pylint: disable=E1101 del self.space.constraints.condition[idx] # pylint: disable=E1101
def remove_fill(self, def remove_fill(self,
name: str, name: str,
@ -507,14 +469,13 @@ class RougailObjSpace:
"""Remove a fill with a specified target """Remove a fill with a specified target
""" """
remove_fills = [] remove_fills = []
constraints = self.get_constraints() for idx, fill in enumerate(self.space.constraints.fill): # pylint: disable=E1101
for idx, fill in enumerate(constraints.fill): # pylint: disable=E1101
for target in fill.target: for target in fill.target:
if target.name == name: if target.name == name:
remove_fills.append(idx) remove_fills.append(idx)
remove_fills.sort(reverse=True) remove_fills.sort(reverse=True)
for idx in remove_fills: for idx in remove_fills:
constraints.fill.pop(idx) # pylint: disable=E1101 self.space.constraints.fill.pop(idx) # pylint: disable=E1101
def set_path(self, def set_path(self,
namespace, namespace,
@ -526,24 +487,33 @@ class RougailObjSpace:
"""Fill self.paths attributes """Fill self.paths attributes
""" """
if isinstance(variableobj, self.variable): # pylint: disable=E1101 if isinstance(variableobj, self.variable): # pylint: disable=E1101
if 'name' in document.attrib:
family_name = document.attrib['name']
else:
family_name = namespace
if isinstance(space, self.family) and space.leadership:
leader = space.path
else:
leader = None
self.paths.add_variable(namespace, self.paths.add_variable(namespace,
variableobj.name,
space.path, space.path,
variableobj,
is_dynamic, is_dynamic,
isinstance(space, self.family) and space.leadership, variableobj,
leader,
) )
elif isinstance(variableobj, self.family): # pylint: disable=E1101 elif isinstance(variableobj, self.family): # pylint: disable=E1101
family_name = variableobj.name
if namespace != self.rougailconfig['variable_namespace']:
family_name = space.path + '.' + family_name
self.paths.add_family(namespace, self.paths.add_family(namespace,
space.path, family_name,
variableobj, variableobj,
is_dynamic, space.path,
) )
elif isinstance(variableobj, self.variables): elif isinstance(variableobj, self.variables):
path_prefix = self.paths.get_path_prefix() variableobj.path = variableobj.name
if path_prefix:
variableobj.path = path_prefix + '.' + variableobj.name
else:
variableobj.path = variableobj.name
@staticmethod @staticmethod
def add_to_tree_structure(variableobj, def add_to_tree_structure(variableobj,
@ -562,22 +532,3 @@ class RougailObjSpace:
getattr(space, child.tag).append(variableobj) getattr(space, child.tag).append(variableobj)
else: else:
setattr(space, child.tag, variableobj) setattr(space, child.tag, variableobj)
def get_variables(objectspace):
"""Iter all variables from the objectspace
"""
for family in objectspace.space.variables.values():
yield from _get_variables(family, objectspace.family)
def _get_variables(family, family_type):
if hasattr(family, 'variable'):
for variable in family.variable.values():
if isinstance(variable, family_type):
yield from _get_variables(variable, family_type)
else:
yield variable
if hasattr(family, 'variables'):
for family in family.variables.values():
yield from _get_variables(family, family_type)

View file

@ -40,293 +40,140 @@ class Path:
) -> None: ) -> None:
self.variables = {} self.variables = {}
self.families = {} self.families = {}
#self.names = {}
self.full_paths_families = {} self.full_paths_families = {}
self.full_paths_variables = {} self.full_paths_variables = {}
self.full_dyn_paths_families = {}
self.valid_enums = {}
self.variable_namespace = rougailconfig['variable_namespace'] self.variable_namespace = rougailconfig['variable_namespace']
self.providers = {}
self.suppliers = {}
self.list_conditions = {}
self.suffix = rougailconfig['suffix']
self.index = 0
def set_path_prefix(self, prefix: str) -> None:
self._path_prefix = prefix
if prefix:
if None in self.full_paths_families:
raise DictConsistencyError(_(f'prefix "{prefix}" cannot be set if a prefix "None" exists'), 39, None)
else:
for old_prefix in self.full_paths_families:
if old_prefix != None:
raise DictConsistencyError(_(f'no prefix cannot be set if a prefix exists'), 84, None)
if prefix in self.full_paths_families:
raise DictConsistencyError(_(f'prefix "{prefix}" already exists'), 83, None)
self.full_paths_families[prefix] = {}
self.full_paths_variables[prefix] = {}
self.valid_enums[prefix] = {}
self.providers[prefix] = {}
self.suppliers[prefix] = {}
self.list_conditions[prefix] = {}
def has_path_prefix(self) -> bool:
return None not in self.full_paths_families
def get_path_prefixes(self) -> list:
return list(self.full_paths_families)
def get_path_prefix(self) -> str:
return self._path_prefix
# Family # Family
def add_family(self, def add_family(self,
namespace: str, namespace: str,
subpath: str, name: str,
variableobj: str, variableobj: str,
is_dynamic: str, subpath: str,
force_path_prefix: str=None,
) -> str: # pylint: disable=C0111 ) -> str: # pylint: disable=C0111
"""Add a new family """Add a new family
""" """
if force_path_prefix is None:
force_path_prefix = self._path_prefix
path = subpath + '.' + variableobj.name
if namespace == self.variable_namespace: if namespace == self.variable_namespace:
if variableobj.name in self.full_paths_families[force_path_prefix]: full_name = '.'.join([subpath, name])
msg = _(f'Duplicate family name "{variableobj.name}"') if name in self.full_paths_families:
msg = _(f'Duplicate family name "{name}"')
raise DictConsistencyError(msg, 55, variableobj.xmlfiles) raise DictConsistencyError(msg, 55, variableobj.xmlfiles)
self.full_paths_families[force_path_prefix][variableobj.name] = path self.full_paths_families[name] = full_name
if is_dynamic: else:
if subpath in self.full_dyn_paths_families: if '.' not in name: # pragma: no cover
dyn_subpath = self.full_dyn_paths_families[subpath] msg = _(f'Variable "{name}" in namespace "{namespace}" must have dot')
else: raise DictConsistencyError(msg, 39, variableobj.xmlfiles)
dyn_subpath = subpath full_name = name
self.full_dyn_paths_families[path] = f'{dyn_subpath}.{variableobj.name}{{suffix}}' if full_name in self.families and \
if path in self.families: self.families[full_name]['variableobj'] != variableobj: # pragma: no cover
msg = _(f'Duplicate family name "{path}"') msg = _(f'Duplicate family name "{name}"')
raise DictConsistencyError(msg, 37, variableobj.xmlfiles) raise DictConsistencyError(msg, 37, variableobj.xmlfiles)
if path in self.variables: if full_name in self.variables:
msg = _(f'A variable and a family has the same path "{path}"') msg = _(f'A variable and a family has the same path "{full_name}"')
raise DictConsistencyError(msg, 56, variableobj.xmlfiles) raise DictConsistencyError(msg, 56, variableobj.xmlfiles)
self.families[path] = dict(name=path, self.families[full_name] = dict(name=name,
namespace=namespace, namespace=namespace,
variableobj=variableobj, variableobj=variableobj,
) )
self.set_name(variableobj, 'optiondescription_') variableobj.path = full_name
variableobj.path = path
variableobj.path_prefix = force_path_prefix
def get_family(self, def get_family(self,
path: str, name: str,
current_namespace: str, current_namespace: str,
path_prefix: str,
allow_variable_namespace: bool=False,
) -> 'Family': # pylint: disable=C0111 ) -> 'Family': # pylint: disable=C0111
"""Get a family """Get a family
""" """
if (current_namespace == self.variable_namespace or allow_variable_namespace) and path in self.full_paths_families[path_prefix]: name = '.'.join([normalize_family(subname) for subname in name.split('.')])
path = self.full_paths_families[path_prefix][path] if name not in self.families and name in self.full_paths_families:
elif allow_variable_namespace and path_prefix: name = self.full_paths_families[name]
path = f'{path_prefix}.{path}' if name not in self.families:
if path not in self.families: raise DictConsistencyError(_(f'unknown option {name}'), 42, [])
raise DictConsistencyError(_(f'unknown option "{path}"'), 42, []) dico = self.families[name]
dico = self.families[path] if current_namespace not in [self.variable_namespace, 'services'] and \
if current_namespace != dico['namespace'] and \ current_namespace != dico['namespace']:
(not allow_variable_namespace or current_namespace != self.variable_namespace):
msg = _(f'A family located in the "{dico["namespace"]}" namespace ' msg = _(f'A family located in the "{dico["namespace"]}" namespace '
f'shall not be used in the "{current_namespace}" namespace') f'shall not be used in the "{current_namespace}" namespace')
raise DictConsistencyError(msg, 38, []) raise DictConsistencyError(msg, 38, [])
return dico['variableobj'] return dico['variableobj']
def _get_dyn_path(self, def is_leader(self, path): # pylint: disable=C0111
subpath: str, """Is the variable is a leader
name: bool, """
) -> str: variable = self._get_variable(path)
if subpath in self.full_dyn_paths_families: if not variable['leader']:
subpath = self.full_dyn_paths_families[subpath] return False
path = f'{subpath}.{name}{{suffix}}' leadership = self.get_family(variable['leader'], variable['variableobj'].namespace)
else: return next(iter(leadership.variable.values())).path == path
path = f'{subpath}.{name}'
return path
def set_provider(self, def is_follower(self, path):
variableobj, """Is the variable is a follower
name, """
family, variable = self._get_variable(path)
): if not variable['leader']:
if not hasattr(variableobj, 'provider'): return False
return leadership = self.get_family(variable['leader'], variable['variableobj'].namespace)
p_name = 'provider:' + variableobj.provider return next(iter(leadership.variable.values())).path != path
if '.' in name:
msg = f'provider "{p_name}" not allowed in extra'
raise DictConsistencyError(msg, 82, variableobj.xmlfiles)
if p_name in self.providers[variableobj.path_prefix]:
msg = f'provider "{p_name}" declare multiple time'
raise DictConsistencyError(msg, 79, variableobj.xmlfiles)
self.providers[variableobj.path_prefix][p_name] = {'path': self._get_dyn_path(family,
name,
),
'option': variableobj,
}
def get_provider(self,
name: str,
path_prefix: str=None,
) -> 'self.objectspace.variable':
return self.providers[path_prefix][name]['option']
def get_providers_path(self, path_prefix=None):
if path_prefix:
return {name: option['path'].split('.', 1)[-1] for name, option in self.providers[path_prefix].items()}
return {name: option['path'] for name, option in self.providers[path_prefix].items()}
def set_supplier(self,
variableobj,
name,
family,
):
if not hasattr(variableobj, 'supplier'):
return
s_name = 'supplier:' + variableobj.supplier
if '.' in name:
msg = f'supplier "{s_name}" not allowed in extra'
raise DictConsistencyError(msg, 82, variableobj.xmlfiles)
if s_name in self.suppliers[variableobj.path_prefix]:
msg = f'supplier "{s_name}" declare multiple time'
raise DictConsistencyError(msg, 79, variableobj.xmlfiles)
self.suppliers[variableobj.path_prefix][s_name] = {'path': self._get_dyn_path(family,
name),
'option': variableobj,
}
def get_supplier(self,
name: str,
path_prefix: str=None,
) -> 'self.objectspace.variable':
return self.suppliers[path_prefix][name]['option']
def get_suppliers_path(self, path_prefix=None):
if path_prefix:
return {name: option['path'].split('.', 1)[-1] for name, option in self.suppliers[path_prefix].items()}
return {name: option['path'] for name, option in self.suppliers[path_prefix].items()}
# Variable # Variable
def add_variable(self, # pylint: disable=R0913 def add_variable(self, # pylint: disable=R0913
namespace: str, namespace: str,
subpath: str, name: str,
variableobj: "self.objectspace.variable", family: str,
is_dynamic: bool=False, is_dynamic: bool,
is_leader: bool=False, variableobj,
force_path_prefix: str=None, leader: 'self.objectspace.family'=None,
) -> str: # pylint: disable=C0111 ) -> str: # pylint: disable=C0111
"""Add a new variable (with path) """Add a new variable (with path)
""" """
if force_path_prefix is None: if name == 'hostname_' and not is_dynamic:
force_path_prefix = self._path_prefix raise Exception('pffff')
path = subpath + '.' + variableobj.name if '.' not in name:
if namespace == self.variable_namespace: full_path = '.'.join([family, name])
self.full_paths_variables[force_path_prefix][variableobj.name] = path if namespace == self.variable_namespace:
if path in self.families: self.full_paths_variables[name] = full_path
msg = _(f'A family and a variable has the same path "{path}"')
raise DictConsistencyError(msg, 57, variableobj.xmlfiles)
if is_leader:
leader = subpath
else: else:
leader = None full_path = name
self.variables[path] = dict(name=path, variableobj.path = full_path
family=subpath, if full_path in self.families:
leader=leader, msg = _(f'A family and a variable has the same path "{full_path}"')
is_dynamic=is_dynamic, raise DictConsistencyError(msg, 57, variableobj.xmlfiles)
variableobj=variableobj, self.variables[full_path] = dict(name=name,
) family=family,
variableobj.path = path leader=leader,
variableobj.path_prefix = force_path_prefix is_dynamic=is_dynamic,
self.set_name(variableobj, 'option_') variableobj=variableobj,
)
def set_name(self,
variableobj,
option_prefix,
):
self.index += 1
variableobj.reflector_name = f'{option_prefix}{self.index}{self.suffix}'
def get_variable(self, def get_variable(self,
name: str, name: str,
namespace: str,
xmlfiles: List[str]=[], xmlfiles: List[str]=[],
allow_variable_namespace: bool=False,
force_path_prefix: str=None,
add_path_prefix: bool=False,
) -> 'Variable': # pylint: disable=C0111 ) -> 'Variable': # pylint: disable=C0111
"""Get variable object from a path """Get variable object from a path
""" """
if force_path_prefix is None: variable, suffix = self._get_variable(name, with_suffix=True, xmlfiles=xmlfiles)
force_path_prefix = self._path_prefix
try:
variable, suffix = self._get_variable(name,
namespace,
with_suffix=True,
xmlfiles=xmlfiles,
path_prefix=force_path_prefix,
add_path_prefix=add_path_prefix,
)
except DictConsistencyError as err:
if not allow_variable_namespace or err.errno != 42 or namespace == self.variable_namespace:
raise err from err
variable, suffix = self._get_variable(name,
self.variable_namespace,
with_suffix=True,
xmlfiles=xmlfiles,
path_prefix=force_path_prefix,
)
if suffix: if suffix:
raise DictConsistencyError(_(f"{name} is a dynamic variable"), 36, []) raise DictConsistencyError(_(f"{name} is a dynamic variable"), 36, [])
return variable['variableobj'] return variable['variableobj']
def get_variable_family_path(self, def get_variable_family_path(self,
name: str, name: str,
namespace: str,
xmlfiles: List[str]=False, xmlfiles: List[str]=False,
force_path_prefix: str=None,
) -> str: # pylint: disable=C0111 ) -> str: # pylint: disable=C0111
"""Get the full path of a family """Get the full path of a family
""" """
if force_path_prefix is None: return self._get_variable(name, xmlfiles=xmlfiles)['family']
force_path_prefix = self._path_prefix
return self._get_variable(name,
namespace,
xmlfiles=xmlfiles,
path_prefix=force_path_prefix,
)['family']
def get_variable_with_suffix(self, def get_variable_path(self,
name: str, name: str,
current_namespace: str, current_namespace: str,
xmlfiles: List[str], xmlfiles: List[str]=[],
path_prefix: str, ) -> str: # pylint: disable=C0111
) -> str: # pylint: disable=C0111
"""get full path of a variable """get full path of a variable
""" """
try: dico, suffix = self._get_variable(name,
dico, suffix = self._get_variable(name, with_suffix=True,
current_namespace, xmlfiles=xmlfiles,
with_suffix=True, )
xmlfiles=xmlfiles,
path_prefix=path_prefix,
add_path_prefix=True,
)
except DictConsistencyError as err:
if err.errno != 42 or current_namespace == self.variable_namespace:
raise err from err
dico, suffix = self._get_variable(name,
self.variable_namespace,
with_suffix=True,
xmlfiles=xmlfiles,
path_prefix=path_prefix,
add_path_prefix=True,
)
namespace = dico['variableobj'].namespace namespace = dico['variableobj'].namespace
if namespace not in [self.variable_namespace, 'services'] and \ if namespace not in [self.variable_namespace, 'services'] and \
current_namespace != 'services' and \ current_namespace != 'services' and \
@ -334,131 +181,41 @@ class Path:
msg = _(f'A variable located in the "{namespace}" namespace shall not be used ' msg = _(f'A variable located in the "{namespace}" namespace shall not be used '
f'in the "{current_namespace}" namespace') f'in the "{current_namespace}" namespace')
raise DictConsistencyError(msg, 41, xmlfiles) raise DictConsistencyError(msg, 41, xmlfiles)
return dico['variableobj'], suffix return dico['variableobj'].path, suffix
def path_is_defined(self, def path_is_defined(self,
path: str, path: str,
namespace: str,
force_path_prefix: str=None,
) -> str: # pylint: disable=C0111 ) -> str: # pylint: disable=C0111
"""The path is a valid path """The path is a valid path
""" """
if namespace == self.variable_namespace: if '.' not in path and path not in self.variables and path in self.full_paths_variables:
if force_path_prefix is None: return True
force_path_prefix = self._path_prefix
return path in self.full_paths_variables[force_path_prefix]
return path in self.variables return path in self.variables
def get_path(self, def variable_is_dynamic(self,
path: str, name: str,
namespace: str, ) -> bool:
) -> str:
if namespace == self.variable_namespace:
if path not in self.full_paths_variables[self._path_prefix]:
return None
path = self.full_paths_variables[self._path_prefix][path]
else:
path = f'{self._path_prefix}.{path}'
return path
def is_dynamic(self, variableobj) -> bool:
"""This variable is in dynamic family """This variable is in dynamic family
""" """
return self._get_variable(variableobj.path, return self._get_variable(name)['is_dynamic']
variableobj.namespace,
path_prefix=variableobj.path_prefix,
)['is_dynamic']
def is_leader(self, variableobj): # pylint: disable=C0111
"""Is the variable is a leader
"""
path = variableobj.path
variable = self._get_variable(path,
variableobj.namespace,
path_prefix=variableobj.path_prefix,
)
if not variable['leader']:
return False
leadership = self.get_family(variable['leader'],
variableobj.namespace,
path_prefix=variableobj.path_prefix,
)
return next(iter(leadership.variable.values())).path == path
def is_follower(self, variableobj) -> bool:
"""Is the variable is a follower
"""
variable = self._get_variable(variableobj.path,
variableobj.namespace,
path_prefix=variableobj.path_prefix,
)
if not variable['leader']:
return False
leadership = self.get_family(variable['leader'],
variableobj.namespace,
path_prefix=variableobj.path_prefix,
)
return next(iter(leadership.variable.values())).path != variableobj.path
def get_leader(self, variableobj) -> str:
variable = self._get_variable(variableobj.path,
variableobj.namespace,
path_prefix=variableobj.path_prefix,
)
if not variable['leader']:
raise Exception(f'cannot find leader for {variableobj.path}')
leadership = self.get_family(variable['leader'],
variableobj.namespace,
path_prefix=variableobj.path_prefix,
)
return next(iter(leadership.variable.values()))
def _get_variable(self, def _get_variable(self,
path: str, name: str,
namespace: str,
with_suffix: bool=False, with_suffix: bool=False,
xmlfiles: List[str]=[], xmlfiles: List[str]=[],
path_prefix: str=None,
add_path_prefix: bool=False,
) -> str: ) -> str:
if namespace == self.variable_namespace: name = '.'.join([normalize_family(subname) for subname in name.split('.')])
if path in self.full_paths_variables[path_prefix]: if name not in self.variables:
path = self.full_paths_variables[path_prefix][path] if '.' not in name and name in self.full_paths_variables:
else: name = self.full_paths_variables[name]
if with_suffix: elif with_suffix:
for var_name, full_path in self.full_paths_variables[path_prefix].items(): for var_name, full_path in self.full_paths_variables.items():
if not path.startswith(var_name): if name.startswith(var_name):
continue variable = self._get_variable(full_path)
variable = self._get_variable(full_path, namespace, path_prefix=path_prefix) if variable['is_dynamic']:
if not variable['is_dynamic']: return variable, name[len(var_name):]
continue if name not in self.variables:
return variable, path[len(var_name):] raise DictConsistencyError(_(f'unknown option "{name}"'), 42, xmlfiles)
if path_prefix and add_path_prefix:
path = f'{path_prefix}.{path}'
elif path_prefix and add_path_prefix:
path = f'{path_prefix}.{path}'
#FIXME with_suffix and variable in extra?
if path not in self.variables:
raise DictConsistencyError(_(f'unknown option "{path}"'), 42, xmlfiles)
if with_suffix: if with_suffix:
return self.variables[path], None return self.variables[name], None
return self.variables[path] return self.variables[name]
def set_valid_enums(self,
path,
values,
path_prefix,
):
self.valid_enums[path_prefix][path] = values
def has_valid_enums(self,
path: str,
path_prefix: str,
) -> bool:
return path in self.valid_enums[path_prefix]
def get_valid_enums(self,
path: str,
path_prefix: str,
):
return self.valid_enums[path_prefix][path]

View file

@ -1,41 +0,0 @@
"""Provider/supplier
distribued with GPL-2 or later license
This program is free software; you can redistribute it and/or modify
it under the terms of the GNU General Public License as published by
the Free Software Foundation; either version 2 of the License, or
(at your option) any later version.
This program is distributed in the hope that it will be useful,
but WITHOUT ANY WARRANTY; without even the implied warranty of
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
GNU General Public License for more details.
You should have received a copy of the GNU General Public License
along with this program; if not, write to the Free Software
Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
"""
from rougail.objspace import get_variables
from rougail.utils import normalize_family
def provider_supplier(objectspace,
path_prefix,
):
n_path_prefix = normalize_family(path_prefix)
for variable in get_variables(objectspace):
if variable.path_prefix != n_path_prefix:
continue
if hasattr(variable, 'provider'):
family_name, variable.name = variable.path.rsplit('.', 1)
objectspace.paths.set_provider(variable,
variable.name,
family_name,
)
if hasattr(variable, 'supplier'):
family_name, variable.name = variable.path.rsplit('.', 1)
objectspace.paths.set_supplier(variable,
variable.name,
family_name,
)

View file

@ -35,11 +35,9 @@ from os.path import dirname, join, isfile, isdir, abspath
try: try:
from tiramisu3 import Config, undefined from tiramisu3 import Config, undefined
from tiramisu3.api import TiramisuOption
from tiramisu3.error import PropertiesOptionError # pragma: no cover from tiramisu3.error import PropertiesOptionError # pragma: no cover
except ModuleNotFoundError: # pragma: no cover except ModuleNotFoundError: # pragma: no cover
from tiramisu import Config, undefined from tiramisu import Config, undefined
from tiramisu.api import TiramisuOption
from tiramisu.error import PropertiesOptionError from tiramisu.error import PropertiesOptionError
from ..config import RougailConfig from ..config import RougailConfig
@ -59,7 +57,6 @@ log.addHandler(logging.NullHandler())
INFORMATIONS = {'files': ['source', 'mode', 'engine', 'included'], INFORMATIONS = {'files': ['source', 'mode', 'engine', 'included'],
'overrides': ['name', 'source', 'engine'], 'overrides': ['name', 'source', 'engine'],
'service_names': ['doc', 'engine', 'type'],
} }
DEFAULT = {'files': ['owner', 'group'], DEFAULT = {'files': ['owner', 'group'],
'overrides': [], 'overrides': [],
@ -181,13 +178,9 @@ class RougailExtra:
For example %%extra1.family.variable For example %%extra1.family.variable
""" """
def __init__(self, def __init__(self,
name: str,
suboption: Dict, suboption: Dict,
path: str,
) -> None: ) -> None:
self._name = name
self._suboption = suboption self._suboption = suboption
self._path = path
def __getattr__(self, def __getattr__(self,
key: str, key: str,
@ -195,7 +188,7 @@ class RougailExtra:
try: try:
return self._suboption[key] return self._suboption[key]
except KeyError: except KeyError:
raise AttributeError(f'unable to find extra "{self._path}.{key}"') raise AttributeError(f'unable to find extra "{key}"')
def __getitem__(self, def __getitem__(self,
key: str, key: str,
@ -209,7 +202,10 @@ class RougailExtra:
return self._suboption.items() return self._suboption.items()
def __str__(self): def __str__(self):
return self._name suboptions = {}
for key, value in self._suboption.items():
suboptions[key] = str(value)
return f'<extra object with: {suboptions}>'
class RougailBaseTemplate: class RougailBaseTemplate:
@ -338,19 +334,6 @@ class RougailBaseTemplate:
destfilenames.append(destfilename) destfilenames.append(destfilename)
return destfilenames return destfilenames
async def load_variables(self):
for option in await self.config.option.list(type='all'):
namespace = await option.option.name()
is_variable_namespace = namespace == self.rougailconfig['variable_namespace']
if namespace == 'services':
is_service_namespace = 'root'
else:
is_service_namespace = False
self.rougail_variables_dict[namespace] = await self._load_variables(option,
is_variable_namespace,
is_service_namespace,
)
async def instance_files(self) -> None: async def instance_files(self) -> None:
"""Run templatisation on all files """Run templatisation on all files
""" """
@ -359,8 +342,17 @@ class RougailBaseTemplate:
except FileNotFoundError: except FileNotFoundError:
ori_dir = None ori_dir = None
chdir(self.tmp_dir) chdir(self.tmp_dir)
if not self.rougail_variables_dict: for option in await self.config.option.list(type='all'):
await self.load_variables() namespace = await option.option.name()
is_variable_namespace = namespace == self.rougailconfig['variable_namespace']
if namespace == 'services':
is_service_namespace = 'root'
else:
is_service_namespace = False
self.rougail_variables_dict[namespace] = await self.load_variables(option,
is_variable_namespace,
is_service_namespace,
)
for templates_dir in self.templates_dir: for templates_dir in self.templates_dir:
for template in listdir(templates_dir): for template in listdir(templates_dir):
self.prepare_template(template, self.prepare_template(template,
@ -406,7 +398,7 @@ class RougailBaseTemplate:
) )
if included and fill.get('included', 'no') == 'content': if included and fill.get('included', 'no') == 'content':
files_to_delete.extend(destfilenames) files_to_delete.extend(destfilenames)
elif 'name' in fill: else:
self.log.debug(_(f"Instantiation of file '{fill['name']}' disabled")) self.log.debug(_(f"Instantiation of file '{fill['name']}' disabled"))
self.post_instance_service(service_name) self.post_instance_service(service_name)
for filename in files_to_delete: for filename in files_to_delete:
@ -491,16 +483,14 @@ class RougailBaseTemplate:
) -> None: # pragma: no cover ) -> None: # pragma: no cover
raise NotImplementedError(_('cannot instanciate this service type override')) raise NotImplementedError(_('cannot instanciate this service type override'))
async def _load_variables(self, async def load_variables(self,
optiondescription, optiondescription,
is_variable_namespace: str, is_variable_namespace: str,
is_service_namespace: str, is_service_namespace: str,
) -> RougailExtra: ) -> RougailExtra:
"""Load all variables and set it in RougailExtra objects """Load all variables and set it in RougailExtra objects
""" """
variables = {} variables = {}
if isinstance(self.config, TiramisuOption):
len_root_path = len(await self.config.option.path()) + 1
for option in await optiondescription.list('all'): for option in await optiondescription.list('all'):
if await option.option.isoptiondescription(): if await option.option.isoptiondescription():
if await option.option.isleadership(): if await option.option.isleadership():
@ -512,15 +502,11 @@ class RougailBaseTemplate:
if is_variable_namespace: if is_variable_namespace:
self.rougail_variables_dict[await suboption.option.name()] = leader self.rougail_variables_dict[await suboption.option.name()] = leader
else: else:
if isinstance(self.config, TiramisuOption):
path = (await suboption.option.path())[len_root_path:]
else:
path = await suboption.option.path()
await leader._add_follower(self.config, await leader._add_follower(self.config,
await suboption.option.name(), await suboption.option.name(),
path, await suboption.option.path(),
) )
variables[leadership_name] = RougailExtra(await optiondescription.option.name(), {leader_name: leader}, await optiondescription.option.path()) variables[leadership_name] = RougailExtra({leader_name: leader})
else: else:
if is_service_namespace == 'root': if is_service_namespace == 'root':
new_is_service_namespace = 'service_name' new_is_service_namespace = 'service_name'
@ -531,10 +517,10 @@ class RougailBaseTemplate:
new_is_service_namespace = is_service_namespace[:-1] new_is_service_namespace = is_service_namespace[:-1]
else: else:
new_is_service_namespace = is_service_namespace new_is_service_namespace = is_service_namespace
subfamilies = await self._load_variables(option, subfamilies = await self.load_variables(option,
is_variable_namespace, is_variable_namespace,
new_is_service_namespace, new_is_service_namespace,
) )
variables[await option.option.name()] = subfamilies variables[await option.option.name()] = subfamilies
else: else:
if is_variable_namespace: if is_variable_namespace:
@ -542,10 +528,7 @@ class RougailBaseTemplate:
self.rougail_variables_dict[await option.option.name()] = value self.rougail_variables_dict[await option.option.name()] = value
if await option.option.issymlinkoption() and await option.option.isfollower(): if await option.option.issymlinkoption() and await option.option.isfollower():
value = [] value = []
if isinstance(self.config, TiramisuOption): path = await option.option.path()
path = (await option.option.path())[len_root_path:]
else:
path = await option.option.path()
for index in range(await option.value.len()): for index in range(await option.value.len()):
value.append(await self.config.option(path, index).value.get()) value.append(await self.config.option(path, index).value.get())
else: else:
@ -560,4 +543,4 @@ class RougailBaseTemplate:
variables, variables,
optiondescription, optiondescription,
) )
return RougailExtra(await optiondescription.option.name(), variables, await optiondescription.option.path()) return RougailExtra(variables)

View file

@ -29,12 +29,7 @@ from shutil import copy
def process(filename: str, def process(filename: str,
source: str,
destfilename: str, destfilename: str,
**kwargs **kwargs
): ):
if filename is not None: copy(filename, destfilename)
copy(filename, destfilename)
else:
with open(destfilename, 'w') as fh:
fh.write(source)

View file

@ -104,7 +104,7 @@ C %%filename %%file.mode %%file.owner %%file.group - {self.rougailconfig['tmpfil
raise FileNotFound(_(f'Override source file "{source}" does not exist in {", ".join(self.templates_dir)}')) raise FileNotFound(_(f'Override source file "{source}" does not exist in {", ".join(self.templates_dir)}'))
tmp_file = join(self.tmp_dir, source) tmp_file = join(self.tmp_dir, source)
service_name = filevar['name'] service_name = filevar['name']
destfile = f'{self.rougailconfig["default_systemd_directory"]}/system/{service_name}.d/rougail.conf' destfile = f'/systemd/system/{service_name}.d/rougail.conf'
return tmp_file, None, destfile, None return tmp_file, None, destfile, None
def get_data_ip(self, def get_data_ip(self,
@ -134,7 +134,7 @@ C %%filename %%file.mode %%file.owner %%file.group - {self.rougailconfig['tmpfil
): ):
tmp_file = join(self.tmp_dir, service_name) tmp_file = join(self.tmp_dir, service_name)
var = None var = None
destfile = f'{self.rougailconfig["default_systemd_directory"]}/system/{service_name}' destfile = f'/systemd/system/{service_name}'
return tmp_file, None, destfile, var return tmp_file, None, destfile, var
@ -148,7 +148,7 @@ C %%filename %%file.mode %%file.owner %%file.group - {self.rougailconfig['tmpfil
def target_service(self, def target_service(self,
service_name: str, service_name: str,
target_name: str, target_name: str,
global_service: bool, global_service: str,
): ):
filename = f'{self.destinations_dir}/systemd/system/{target_name}.target.wants/{service_name}' filename = f'{self.destinations_dir}/systemd/system/{target_name}.target.wants/{service_name}'
makedirs(dirname(filename), exist_ok=True) makedirs(dirname(filename), exist_ok=True)
@ -163,7 +163,7 @@ C %%filename %%file.mode %%file.owner %%file.group - {self.rougailconfig['tmpfil
) -> None: # pragma: no cover ) -> None: # pragma: no cover
if self.ip_per_service is None: if self.ip_per_service is None:
return return
destfile = f'{self.rougailconfig["default_systemd_directory"]}/system/{service_name}.d/rougail_ip.conf' destfile = f'/systemd/system/{service_name}.d/rougail_ip.conf'
destfilename = join(self.destinations_dir, destfile[1:]) destfilename = join(self.destinations_dir, destfile[1:])
makedirs(dirname(destfilename), exist_ok=True) makedirs(dirname(destfilename), exist_ok=True)
self.log.info(_(f"creole processing: '{destfilename}'")) self.log.info(_(f"creole processing: '{destfilename}'"))

View file

@ -32,12 +32,13 @@ from .i18n import _
from .annotator import CONVERT_OPTION from .annotator import CONVERT_OPTION
from .objspace import RootRougailObject from .objspace import RootRougailObject
from .error import DictConsistencyError from .error import DictConsistencyError
from .utils import normalize_family
class BaseElt: # pylint: disable=R0903 class BaseElt: # pylint: disable=R0903
"""Base element """Base element
""" """
name = 'baseoption'
doc = 'baseoption'
path = '.' path = '.'
@ -48,105 +49,83 @@ class TiramisuReflector:
objectspace, objectspace,
funcs_paths, funcs_paths,
internal_functions, internal_functions,
cfg,
): ):
self.cfg = cfg self.index = 0
self.text = {'header': [], self.text = []
'option': [],
'optiondescription': [],
}
if funcs_paths: if funcs_paths:
if self.cfg['export_with_import']: self.text.extend(["from importlib.machinery import SourceFileLoader as _SourceFileLoader",
self.text['header'].extend(["from importlib.machinery import SourceFileLoader as _SourceFileLoader", "from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec",
"from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec", "class func:",
"class func:", " pass",
" pass", ])
"",
"def _load_functions(path):",
" global _SourceFileLoader, _spec_from_loader, _module_from_spec, func",
" loader = _SourceFileLoader('func', path)",
" spec = _spec_from_loader(loader.name, loader)",
" func_ = _module_from_spec(spec)",
" loader.exec_module(func_)",
" for function in dir(func_):",
" if function.startswith('_'):",
" continue",
" setattr(func, function, getattr(func_, function))",
])
for funcs_path in funcs_paths: for funcs_path in funcs_paths:
if not isfile(funcs_path): if not isfile(funcs_path):
continue continue
self.text['header'].append(f"_load_functions('{funcs_path}')") self.text.extend([f"_loader = _SourceFileLoader('func', '{funcs_path}')",
if self.cfg['export_with_import']: "_spec = _spec_from_loader(_loader.name, _loader)",
if internal_functions: "_func = _module_from_spec(_spec)",
for func in internal_functions: "_loader.exec_module(_func)",
self.text['header'].append(f"setattr(func, '{func}', {func})") "for function in dir(_func):",
self.text['header'].extend(["try:", " if function.startswith('_'):",
" from tiramisu3 import *", " continue",
"except:", " setattr(func, function, getattr(_func, function))",
" from tiramisu import *", ])
]) if internal_functions:
for func in internal_functions:
self.text.append(f"setattr(func, '{func}', {func})")
self.text.extend(["try:",
" from tiramisu3 import *",
"except:",
" from tiramisu import *",
])
self.objectspace = objectspace self.objectspace = objectspace
self.make_tiramisu_objects() self.make_tiramisu_objects()
if self.cfg['export_with_import'] and (self.cfg['force_convert_dyn_option_description'] or self.objectspace.has_dyn_option is True): if self.objectspace.has_dyn_option is True:
self.text['header'].append("from rougail.tiramisu import ConvertDynOptionDescription") self.text.append("from rougail.tiramisu import ConvertDynOptionDescription")
def make_tiramisu_objects(self) -> None: def make_tiramisu_objects(self) -> None:
"""make tiramisu objects """make tiramisu objects
""" """
providers = {}
baseelt = BaseElt() baseelt = BaseElt()
baseelt.reflector_name = f'option_0{self.objectspace.rougailconfig["suffix"]}'
self.set_name(baseelt) self.set_name(baseelt)
dynamic_path = ''
dynamic = False
basefamily = Family(baseelt, basefamily = Family(baseelt,
self.text, self.text,
self.objectspace, self.objectspace,
) )
if not self.objectspace.paths.has_path_prefix(): for elt in self.reorder_family():
for elt in self.reorder_family(self.objectspace.space): self.populate_family(basefamily,
self.populate_family(basefamily, elt,
elt, providers,
) dynamic,
basefamily.populate_informations() dynamic_path,
basefamily.elt.information = self.objectspace.paths.get_providers_path() )
basefamily.elt.information.update(self.objectspace.paths.get_suppliers_path()) basefamily.elt.information = providers
else: basefamily.populate_informations()
path_prefixes = self.objectspace.paths.get_path_prefixes() self.baseelt = baseelt
for path_prefix in path_prefixes:
space = self.objectspace.space.variables[path_prefix]
self.set_name(space)
baseprefix = Family(space,
self.text,
self.objectspace,
)
basefamily.add(baseprefix)
for elt in self.reorder_family(space):
self.populate_family(baseprefix,
elt,
)
baseprefix.populate_informations()
baseprefix.elt.information = self.objectspace.paths.get_providers_path(path_prefix)
baseprefix.elt.information.update(self.objectspace.paths.get_suppliers_path(path_prefix))
baseelt.name = normalize_family(self.cfg['base_option_name'])
baseelt.doc = self.cfg['base_option_name']
baseelt.reflector_object.get([], baseelt.doc, 'base') # pylint: disable=E1101
def reorder_family(self, space): def reorder_family(self):
"""variable_namespace family has to be loaded before any other family """variable_namespace family has to be loaded before any other family
because `extra` family could use `variable_namespace` variables. because `extra` family could use `variable_namespace` variables.
""" """
if hasattr(space, 'variables'): if hasattr(self.objectspace.space, 'variables'):
variable_namespace = self.objectspace.rougailconfig['variable_namespace'] variable_namespace = self.objectspace.rougailconfig['variable_namespace']
if variable_namespace in space.variables: if variable_namespace in self.objectspace.space.variables:
yield space.variables[variable_namespace] yield self.objectspace.space.variables[variable_namespace]
for elt, value in space.variables.items(): for elt, value in self.objectspace.space.variables.items():
if elt != self.objectspace.rougailconfig['variable_namespace']: if elt != self.objectspace.rougailconfig['variable_namespace']:
yield value yield value
if hasattr(space, 'services'): if hasattr(self.objectspace.space, 'services'):
yield space.services yield self.objectspace.space.services
def populate_family(self, def populate_family(self,
parent_family, parent_family,
elt, elt,
providers,
dynamic,
dynamic_path,
): ):
"""Populate family """Populate family
""" """
@ -155,11 +134,21 @@ class TiramisuReflector:
self.text, self.text,
self.objectspace, self.objectspace,
) )
if not dynamic_path:
dynamic_path = elt.name
else:
dynamic_path = dynamic_path + '.' + elt.name
if dynamic or hasattr(elt, 'suffixes'):
dynamic_path += '{suffix}'
dynamic = True
parent_family.add(family) parent_family.add(family)
for children in vars(elt).values(): for children in vars(elt).values():
if isinstance(children, self.objectspace.family): if isinstance(children, self.objectspace.family):
self.populate_family(family, self.populate_family(family,
children, children,
providers,
dynamic,
dynamic_path,
) )
continue continue
if isinstance(children, dict): if isinstance(children, dict):
@ -171,13 +160,21 @@ class TiramisuReflector:
continue continue
if isinstance(child, self.objectspace.variable): if isinstance(child, self.objectspace.variable):
self.set_name(child) self.set_name(child)
sub_dynamic_path = dynamic_path + '.' + child.name
if dynamic:
sub_dynamic_path += '{suffix}'
family.add(Variable(child, family.add(Variable(child,
self.text, self.text,
self.objectspace, self.objectspace,
providers,
sub_dynamic_path,
)) ))
else: else:
self.populate_family(family, self.populate_family(family,
child, child,
providers,
dynamic,
dynamic_path,
) )
def set_name(self, def set_name(self,
@ -185,14 +182,14 @@ class TiramisuReflector:
): ):
"""Set name """Set name
""" """
if not hasattr(elt, 'reflector_name'): elt.reflector_name = f'option_{self.index}'
self.objectspace.paths.set_name(elt, 'optiondescription_') self.index += 1
return elt.reflector_name
def get_text(self): def get_text(self):
"""Get text """Get text
""" """
return '\n'.join(self.text['header'] + self.text['option'] + self.text['optiondescription']) self.baseelt.reflector_object.get([]) # pylint: disable=E1101
return '\n'.join(self.text)
class Common: class Common:
@ -210,7 +207,7 @@ class Common:
self.elt.reflector_object = self self.elt.reflector_object = self
self.object_type = None self.object_type = None
def get(self, calls, parent_name, typ): def get(self, calls):
"""Get tiramisu's object """Get tiramisu's object
""" """
self_calls = calls.copy() self_calls = calls.copy()
@ -223,6 +220,12 @@ class Common:
self.option_name = self.elt.reflector_name self.option_name = self.elt.reflector_name
self.populate_attrib() self.populate_attrib()
self.populate_informations() self.populate_informations()
if hasattr(self.elt, 'provider'):
name = 'provider:' + self.elt.provider
if name in self.providers:
msg = f'provider {name} declare multiple time'
raise DictConsistencyError(msg, 79, self.elt.xmlfiles)
self.providers[name] = self.dynamic_path
return self.option_name return self.option_name
def populate_attrib(self): def populate_attrib(self):
@ -235,13 +238,7 @@ class Common:
if hasattr(self.elt, 'properties'): if hasattr(self.elt, 'properties'):
keys['properties'] = self.properties_to_string(self.elt.properties) keys['properties'] = self.properties_to_string(self.elt.properties)
attrib = ', '.join([f'{key}={value}' for key, value in keys.items()]) attrib = ', '.join([f'{key}={value}' for key, value in keys.items()])
if self.__class__.__name__ == 'Family': self.text.append(f'{self.option_name} = {self.object_type}({attrib})')
#pouet
name = 'option'
#name = 'optiondescription'
else:
name = 'option'
self.text[name].append(f'{self.option_name} = {self.object_type}({attrib})')
def _populate_attrib(self, def _populate_attrib(self,
keys: dict, keys: dict,
@ -270,7 +267,7 @@ class Common:
) -> str: ) -> str:
"""Populate properties """Populate properties
""" """
option_name = child.source.reflector_object.get(self.calls, self.elt.path, 'property') option_name = child.source.reflector_object.get(self.calls)
kwargs = (f"'condition': ParamOption({option_name}, todict=True, notraisepropertyerror=True), " kwargs = (f"'condition': ParamOption({option_name}, todict=True, notraisepropertyerror=True), "
f"'expected': {self.populate_param(child.expected)}") f"'expected': {self.populate_param(child.expected)}")
if child.inverse: if child.inverse:
@ -292,8 +289,7 @@ class Common:
continue continue
if isinstance(value, str): if isinstance(value, str):
value = self.convert_str(value) value = self.convert_str(value)
#pouet self.text['optiondescription'].append(f"{self.option_name}.impl_set_information('{key}', {value})") self.text.append(f"{self.option_name}.impl_set_information('{key}', {value})")
self.text['option'].append(f"{self.option_name}.impl_set_information('{key}', {value})")
def populate_param(self, def populate_param(self,
param, param,
@ -305,7 +301,7 @@ class Common:
if param.type == 'string' and value is not None: if param.type == 'string' and value is not None:
value = self.convert_str(value) value = self.convert_str(value)
return f'ParamValue({value})' return f'ParamValue({value})'
if param.type in ['variable_name', 'variable']: if param.type == 'variable':
return self.build_option_param(param) return self.build_option_param(param)
if param.type == 'information': if param.type == 'information':
if hasattr(self.elt, 'multi') and self.elt.multi: if hasattr(self.elt, 'multi') and self.elt.multi:
@ -326,14 +322,11 @@ class Common:
) -> str: ) -> str:
"""build variable parameters """build variable parameters
""" """
if param.type == 'variable': option_name = param.text.reflector_object.get(self.calls)
option_name = param.text.reflector_object.get(self.calls, self.elt.path, 'param')
else:
option_name = param.text
params = [f'{option_name}'] params = [f'{option_name}']
if hasattr(param, 'suffix'): if hasattr(param, 'suffix'):
param_type = 'ParamDynOption' param_type = 'ParamDynOption'
family = param.family.reflector_object.get(self.calls, self.elt.path, 'suffix') family = param.family.reflector_object.get(self.calls)
params.extend([f"'{param.suffix}'", f'{family}']) params.extend([f"'{param.suffix}'", f'{family}'])
else: else:
param_type = 'ParamOption' param_type = 'ParamOption'
@ -349,7 +342,11 @@ class Variable(Common):
elt, elt,
text, text,
objectspace, objectspace,
providers,
dynamic_path,
): ):
self.providers = providers
self.dynamic_path = dynamic_path
super().__init__(elt, text, objectspace) super().__init__(elt, text, objectspace)
self.object_type = CONVERT_OPTION[elt.type]['opttype'] self.object_type = CONVERT_OPTION[elt.type]['opttype']
@ -357,11 +354,11 @@ class Variable(Common):
keys: dict, keys: dict,
): ):
if hasattr(self.elt, 'opt'): if hasattr(self.elt, 'opt'):
keys['opt'] = self.elt.opt.reflector_object.get(self.calls, self.elt.path, 'opt') keys['opt'] = self.elt.opt.reflector_object.get(self.calls)
if hasattr(self.elt, 'choice'): if hasattr(self.elt, 'choice'):
values = self.elt.choice values = self.elt.choice
if values[0].type == 'variable': if values[0].type == 'variable':
value = values[0].name.reflector_object.get(self.calls, self.elt.path, 'choice') value = values[0].name.reflector_object.get(self.calls)
keys['values'] = f"Calculation(func.calc_value, Params((ParamOption({value}))))" keys['values'] = f"Calculation(func.calc_value, Params((ParamOption({value}))))"
elif values[0].type == 'function': elif values[0].type == 'function':
keys['values'] = self.calculation_value(values[0], []) keys['values'] = self.calculation_value(values[0], [])
@ -450,6 +447,6 @@ class Family(Common):
keys: list, keys: list,
) -> None: ) -> None:
if hasattr(self.elt, 'suffixes'): if hasattr(self.elt, 'suffixes'):
dyn = self.elt.suffixes.reflector_object.get(self.calls, self.elt.path, 'suffixes') dyn = self.elt.suffixes.reflector_object.get(self.calls)
keys['suffixes'] = f"Calculation(func.calc_value, Params((ParamOption({dyn}, notraisepropertyerror=True))))" keys['suffixes'] = f"Calculation(func.calc_value, Params((ParamOption({dyn}, notraisepropertyerror=True))))"
keys['children'] = '[' + ', '.join([child.get(self.calls, self.elt.path, 'child') for child in self.children]) + ']' keys['children'] = '[' + ', '.join([child.get(self.calls) for child in self.children]) + ']'

View file

@ -50,8 +50,6 @@ def valid_variable_family_name(name: str,
def normalize_family(family_name: str) -> str: def normalize_family(family_name: str) -> str:
"""replace space, accent, uppercase, ... by valid character """replace space, accent, uppercase, ... by valid character
""" """
if not family_name:
return
family_name = family_name.replace('-', '_').replace(' ', '_').replace('.', '_') family_name = family_name.replace('-', '_').replace(' ', '_').replace('.', '_')
nfkd_form = normalize('NFKD', family_name) nfkd_form = normalize('NFKD', family_name)
family_name = ''.join([c for c in nfkd_form if not combining(c)]) family_name = ''.join([c for c in nfkd_form if not combining(c)])

View file

@ -66,10 +66,9 @@ class XMLReflector:
for filename in listdir(xmlfolder): for filename in listdir(xmlfolder):
if not filename.endswith('.xml'): if not filename.endswith('.xml'):
continue continue
full_filename = join(xmlfolder, filename)
if filename in filenames: if filename in filenames:
raise DictConsistencyError(_(f'duplicate xml file name {filename}'), 78, [filenames[filename], full_filename]) raise DictConsistencyError(_(f'duplicate xml file name {filename}'), 78, [xmlfolder])
filenames[filename] = full_filename filenames[filename] = join(xmlfolder, filename)
if not filenames: if not filenames:
raise DictConsistencyError(_('there is no XML file'), 77, [xmlfolder]) raise DictConsistencyError(_('there is no XML file'), 77, [xmlfolder])
file_names = list(filenames.keys()) file_names = list(filenames.keys())

View file

@ -2,6 +2,6 @@
<rougail version="0.10"> <rougail version="0.10">
<services> <services>
<service name="tata"> <service name="tata">
</service> </service>
</services> </services>
</rougail> </rougail>

View file

@ -2,25 +2,20 @@ from importlib.machinery import SourceFileLoader as _SourceFileLoader
from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec
class func: class func:
pass pass
_loader = _SourceFileLoader('func', 'tests/dictionaries/../eosfunc/test.py')
def _load_functions(path): _spec = _spec_from_loader(_loader.name, _loader)
global _SourceFileLoader, _spec_from_loader, _module_from_spec, func _func = _module_from_spec(_spec)
loader = _SourceFileLoader('func', path) _loader.exec_module(_func)
spec = _spec_from_loader(loader.name, loader) for function in dir(_func):
func_ = _module_from_spec(spec) if function.startswith('_'):
loader.exec_module(func_) continue
for function in dir(func_): setattr(func, function, getattr(_func, function))
if function.startswith('_'):
continue
setattr(func, function, getattr(func_, function))
_load_functions('tests/dictionaries/../eosfunc/test.py')
try: try:
from tiramisu3 import * from tiramisu3 import *
except: except:
from tiramisu import * from tiramisu import *
option_1 = BoolOption(name="activate", doc="activate", default=True) option_3 = BoolOption(name="activate", doc="activate", default=True)
option_2 = BoolOption(name="manage", doc="manage", default=True) option_4 = BoolOption(name="manage", doc="manage", default=True)
optiondescription_4 = OptionDescription(name="tata_service", doc="tata.service", children=[option_1, option_2]) option_2 = OptionDescription(name="tata_service", doc="tata.service", children=[option_3, option_4])
optiondescription_4.impl_set_information('type', "service") option_1 = OptionDescription(name="services", doc="services", children=[option_2], properties=frozenset({"hidden"}))
optiondescription_3 = OptionDescription(name="services", doc="services", children=[optiondescription_4], properties=frozenset({"hidden"})) option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[option_1])
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_3])

View file

@ -1,33 +0,0 @@
from importlib.machinery import SourceFileLoader as _SourceFileLoader
from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec
class func:
pass
def _load_functions(path):
global _SourceFileLoader, _spec_from_loader, _module_from_spec, func
loader = _SourceFileLoader('func', path)
spec = _spec_from_loader(loader.name, loader)
func_ = _module_from_spec(spec)
loader.exec_module(func_)
for function in dir(func_):
if function.startswith('_'):
continue
setattr(func, function, getattr(func_, function))
_load_functions('tests/dictionaries/../eosfunc/test.py')
try:
from tiramisu3 import *
except:
from tiramisu import *
option_1 = BoolOption(name="activate", doc="activate", default=True)
option_2 = BoolOption(name="manage", doc="manage", default=True)
optiondescription_7 = OptionDescription(name="tata_service", doc="tata.service", children=[option_1, option_2])
optiondescription_7.impl_set_information('type', "service")
optiondescription_6 = OptionDescription(name="services", doc="services", children=[optiondescription_7], properties=frozenset({"hidden"}))
optiondescription_5 = OptionDescription(name="1", doc="1", children=[optiondescription_6])
option_3 = BoolOption(name="activate", doc="activate", default=True)
option_4 = BoolOption(name="manage", doc="manage", default=True)
optiondescription_10 = OptionDescription(name="tata_service", doc="tata.service", children=[option_3, option_4])
optiondescription_10.impl_set_information('type', "service")
optiondescription_9 = OptionDescription(name="services", doc="services", children=[optiondescription_10], properties=frozenset({"hidden"}))
optiondescription_8 = OptionDescription(name="2", doc="2", children=[optiondescription_9])
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_5, optiondescription_8])

View file

@ -2,23 +2,19 @@ from importlib.machinery import SourceFileLoader as _SourceFileLoader
from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec
class func: class func:
pass pass
_loader = _SourceFileLoader('func', 'tests/dictionaries/../eosfunc/test.py')
def _load_functions(path): _spec = _spec_from_loader(_loader.name, _loader)
global _SourceFileLoader, _spec_from_loader, _module_from_spec, func _func = _module_from_spec(_spec)
loader = _SourceFileLoader('func', path) _loader.exec_module(_func)
spec = _spec_from_loader(loader.name, loader) for function in dir(_func):
func_ = _module_from_spec(spec) if function.startswith('_'):
loader.exec_module(func_) continue
for function in dir(func_): setattr(func, function, getattr(_func, function))
if function.startswith('_'):
continue
setattr(func, function, getattr(func_, function))
_load_functions('tests/dictionaries/../eosfunc/test.py')
try: try:
from tiramisu3 import * from tiramisu3 import *
except: except:
from tiramisu import * from tiramisu import *
option_2 = BoolOption(name="server_deployed", doc="server_deployed", default=False, properties=frozenset({"mandatory", "normal"})) option_3 = BoolOption(name="server_deployed", doc="server_deployed", default=False, properties=frozenset({"mandatory", "normal"}))
option_1 = StrOption(name="myvar", doc="myvar", default="no", properties=frozenset({"basic", "force_store_value", "mandatory", Calculation(func.calc_value, Params(ParamValue('frozen'), kwargs={'condition': ParamOption(option_2, todict=True, notraisepropertyerror=True), 'expected': ParamValue(True)}))})) option_2 = StrOption(name="myvar", doc="myvar", default="no", properties=frozenset({"basic", "force_store_value", "mandatory", Calculation(func.calc_value, Params(ParamValue('frozen'), kwargs={'condition': ParamOption(option_3, todict=True, notraisepropertyerror=True), 'expected': ParamValue(True)}))}))
optiondescription_3 = OptionDescription(name="rougail", doc="Rougail", children=[option_1, option_2]) option_1 = OptionDescription(name="rougail", doc="rougail", children=[option_2, option_3])
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_3]) option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[option_1])

View file

@ -1,29 +0,0 @@
from importlib.machinery import SourceFileLoader as _SourceFileLoader
from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec
class func:
pass
def _load_functions(path):
global _SourceFileLoader, _spec_from_loader, _module_from_spec, func
loader = _SourceFileLoader('func', path)
spec = _spec_from_loader(loader.name, loader)
func_ = _module_from_spec(spec)
loader.exec_module(func_)
for function in dir(func_):
if function.startswith('_'):
continue
setattr(func, function, getattr(func_, function))
_load_functions('tests/dictionaries/../eosfunc/test.py')
try:
from tiramisu3 import *
except:
from tiramisu import *
option_2 = BoolOption(name="server_deployed", doc="server_deployed", default=False, properties=frozenset({"mandatory", "normal"}))
option_1 = StrOption(name="myvar", doc="myvar", default="no", properties=frozenset({"basic", "force_store_value", "mandatory", Calculation(func.calc_value, Params(ParamValue('frozen'), kwargs={'condition': ParamOption(option_2, todict=True, notraisepropertyerror=True), 'expected': ParamValue(True)}))}))
optiondescription_6 = OptionDescription(name="rougail", doc="Rougail", children=[option_1, option_2])
optiondescription_5 = OptionDescription(name="1", doc="1", children=[optiondescription_6])
option_4 = BoolOption(name="server_deployed", doc="server_deployed", default=False, properties=frozenset({"mandatory", "normal"}))
option_3 = StrOption(name="myvar", doc="myvar", default="no", properties=frozenset({"basic", "force_store_value", "mandatory", Calculation(func.calc_value, Params(ParamValue('frozen'), kwargs={'condition': ParamOption(option_4, todict=True, notraisepropertyerror=True), 'expected': ParamValue(True)}))}))
optiondescription_8 = OptionDescription(name="rougail", doc="Rougail", children=[option_3, option_4])
optiondescription_7 = OptionDescription(name="2", doc="2", children=[optiondescription_8])
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_5, optiondescription_7])

View file

@ -2,23 +2,19 @@ from importlib.machinery import SourceFileLoader as _SourceFileLoader
from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec
class func: class func:
pass pass
_loader = _SourceFileLoader('func', 'tests/dictionaries/../eosfunc/test.py')
def _load_functions(path): _spec = _spec_from_loader(_loader.name, _loader)
global _SourceFileLoader, _spec_from_loader, _module_from_spec, func _func = _module_from_spec(_spec)
loader = _SourceFileLoader('func', path) _loader.exec_module(_func)
spec = _spec_from_loader(loader.name, loader) for function in dir(_func):
func_ = _module_from_spec(spec) if function.startswith('_'):
loader.exec_module(func_) continue
for function in dir(func_): setattr(func, function, getattr(_func, function))
if function.startswith('_'):
continue
setattr(func, function, getattr(func_, function))
_load_functions('tests/dictionaries/../eosfunc/test.py')
try: try:
from tiramisu3 import * from tiramisu3 import *
except: except:
from tiramisu import * from tiramisu import *
option_2 = BoolOption(name="server_deployed", doc="server_deployed", default=False, properties=frozenset({"mandatory", "normal"})) option_3 = BoolOption(name="server_deployed", doc="server_deployed", default=False, properties=frozenset({"mandatory", "normal"}))
option_1 = StrOption(name="my_var", doc="my_var", default="no", properties=frozenset({"expert", "force_store_value", "mandatory", Calculation(func.calc_value, Params(ParamValue('frozen'), kwargs={'condition': ParamOption(option_2, todict=True, notraisepropertyerror=True), 'expected': ParamValue(True)}))})) option_2 = StrOption(name="my_var", doc="my_var", default="no", properties=frozenset({"expert", "force_store_value", "mandatory", Calculation(func.calc_value, Params(ParamValue('frozen'), kwargs={'condition': ParamOption(option_3, todict=True, notraisepropertyerror=True), 'expected': ParamValue(True)}))}))
optiondescription_3 = OptionDescription(name="rougail", doc="Rougail", children=[option_1, option_2]) option_1 = OptionDescription(name="rougail", doc="rougail", children=[option_2, option_3])
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_3]) option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[option_1])

View file

@ -1,29 +0,0 @@
from importlib.machinery import SourceFileLoader as _SourceFileLoader
from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec
class func:
pass
def _load_functions(path):
global _SourceFileLoader, _spec_from_loader, _module_from_spec, func
loader = _SourceFileLoader('func', path)
spec = _spec_from_loader(loader.name, loader)
func_ = _module_from_spec(spec)
loader.exec_module(func_)
for function in dir(func_):
if function.startswith('_'):
continue
setattr(func, function, getattr(func_, function))
_load_functions('tests/dictionaries/../eosfunc/test.py')
try:
from tiramisu3 import *
except:
from tiramisu import *
option_2 = BoolOption(name="server_deployed", doc="server_deployed", default=False, properties=frozenset({"mandatory", "normal"}))
option_1 = StrOption(name="my_var", doc="my_var", default="no", properties=frozenset({"expert", "force_store_value", "mandatory", Calculation(func.calc_value, Params(ParamValue('frozen'), kwargs={'condition': ParamOption(option_2, todict=True, notraisepropertyerror=True), 'expected': ParamValue(True)}))}))
optiondescription_6 = OptionDescription(name="rougail", doc="Rougail", children=[option_1, option_2])
optiondescription_5 = OptionDescription(name="1", doc="1", children=[optiondescription_6])
option_4 = BoolOption(name="server_deployed", doc="server_deployed", default=False, properties=frozenset({"mandatory", "normal"}))
option_3 = StrOption(name="my_var", doc="my_var", default="no", properties=frozenset({"expert", "force_store_value", "mandatory", Calculation(func.calc_value, Params(ParamValue('frozen'), kwargs={'condition': ParamOption(option_4, todict=True, notraisepropertyerror=True), 'expected': ParamValue(True)}))}))
optiondescription_8 = OptionDescription(name="rougail", doc="Rougail", children=[option_3, option_4])
optiondescription_7 = OptionDescription(name="2", doc="2", children=[optiondescription_8])
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_5, optiondescription_7])

View file

@ -2,24 +2,20 @@ from importlib.machinery import SourceFileLoader as _SourceFileLoader
from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec
class func: class func:
pass pass
_loader = _SourceFileLoader('func', 'tests/dictionaries/../eosfunc/test.py')
def _load_functions(path): _spec = _spec_from_loader(_loader.name, _loader)
global _SourceFileLoader, _spec_from_loader, _module_from_spec, func _func = _module_from_spec(_spec)
loader = _SourceFileLoader('func', path) _loader.exec_module(_func)
spec = _spec_from_loader(loader.name, loader) for function in dir(_func):
func_ = _module_from_spec(spec) if function.startswith('_'):
loader.exec_module(func_) continue
for function in dir(func_): setattr(func, function, getattr(_func, function))
if function.startswith('_'):
continue
setattr(func, function, getattr(func_, function))
_load_functions('tests/dictionaries/../eosfunc/test.py')
try: try:
from tiramisu3 import * from tiramisu3 import *
except: except:
from tiramisu import * from tiramisu import *
option_1 = BoolOption(name="server_deployed", doc="server_deployed", default=True, properties=frozenset({"mandatory", "normal"})) option_2 = BoolOption(name="server_deployed", doc="server_deployed", default=True, properties=frozenset({"mandatory", "normal"}))
option_3 = StrOption(name="mode_conteneur_actif", doc="No change", default="non", properties=frozenset({"basic", "force_store_value", "mandatory"})) option_4 = StrOption(name="mode_conteneur_actif", doc="No change", default="non", properties=frozenset({"basic", "force_store_value", "mandatory"}))
optiondescription_2 = OptionDescription(name="general", doc="général", children=[option_3], properties=frozenset({"basic"})) option_3 = OptionDescription(name="general", doc="général", children=[option_4], properties=frozenset({"basic"}))
optiondescription_4 = OptionDescription(name="rougail", doc="Rougail", children=[option_1, optiondescription_2]) option_1 = OptionDescription(name="rougail", doc="rougail", children=[option_2, option_3])
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_4]) option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[option_1])

View file

@ -1,31 +0,0 @@
from importlib.machinery import SourceFileLoader as _SourceFileLoader
from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec
class func:
pass
def _load_functions(path):
global _SourceFileLoader, _spec_from_loader, _module_from_spec, func
loader = _SourceFileLoader('func', path)
spec = _spec_from_loader(loader.name, loader)
func_ = _module_from_spec(spec)
loader.exec_module(func_)
for function in dir(func_):
if function.startswith('_'):
continue
setattr(func, function, getattr(func_, function))
_load_functions('tests/dictionaries/../eosfunc/test.py')
try:
from tiramisu3 import *
except:
from tiramisu import *
option_1 = BoolOption(name="server_deployed", doc="server_deployed", default=True, properties=frozenset({"mandatory", "normal"}))
option_3 = StrOption(name="mode_conteneur_actif", doc="No change", default="non", properties=frozenset({"basic", "force_store_value", "mandatory"}))
optiondescription_2 = OptionDescription(name="general", doc="général", children=[option_3], properties=frozenset({"basic"}))
optiondescription_8 = OptionDescription(name="rougail", doc="Rougail", children=[option_1, optiondescription_2])
optiondescription_7 = OptionDescription(name="1", doc="1", children=[optiondescription_8])
option_4 = BoolOption(name="server_deployed", doc="server_deployed", default=True, properties=frozenset({"mandatory", "normal"}))
option_6 = StrOption(name="mode_conteneur_actif", doc="No change", default="non", properties=frozenset({"basic", "force_store_value", "mandatory"}))
optiondescription_5 = OptionDescription(name="general", doc="général", children=[option_6], properties=frozenset({"basic"}))
optiondescription_10 = OptionDescription(name="rougail", doc="Rougail", children=[option_4, optiondescription_5])
optiondescription_9 = OptionDescription(name="2", doc="2", children=[optiondescription_10])
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_7, optiondescription_9])

View file

@ -2,24 +2,20 @@ from importlib.machinery import SourceFileLoader as _SourceFileLoader
from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec
class func: class func:
pass pass
_loader = _SourceFileLoader('func', 'tests/dictionaries/../eosfunc/test.py')
def _load_functions(path): _spec = _spec_from_loader(_loader.name, _loader)
global _SourceFileLoader, _spec_from_loader, _module_from_spec, func _func = _module_from_spec(_spec)
loader = _SourceFileLoader('func', path) _loader.exec_module(_func)
spec = _spec_from_loader(loader.name, loader) for function in dir(_func):
func_ = _module_from_spec(spec) if function.startswith('_'):
loader.exec_module(func_) continue
for function in dir(func_): setattr(func, function, getattr(_func, function))
if function.startswith('_'):
continue
setattr(func, function, getattr(func_, function))
_load_functions('tests/dictionaries/../eosfunc/test.py')
try: try:
from tiramisu3 import * from tiramisu3 import *
except: except:
from tiramisu import * from tiramisu import *
option_1 = BoolOption(name="server_deployed", doc="server_deployed", default=True, properties=frozenset({"mandatory", "normal"})) option_2 = BoolOption(name="server_deployed", doc="server_deployed", default=True, properties=frozenset({"mandatory", "normal"}))
option_3 = StrOption(name="mode_conteneur_actif", doc="No change", default="non", properties=frozenset({"expert", "force_store_value", "mandatory"})) option_4 = StrOption(name="mode_conteneur_actif", doc="No change", default="non", properties=frozenset({"expert", "force_store_value", "mandatory"}))
optiondescription_2 = OptionDescription(name="general", doc="général", children=[option_3], properties=frozenset({"expert"})) option_3 = OptionDescription(name="general", doc="général", children=[option_4], properties=frozenset({"expert"}))
optiondescription_4 = OptionDescription(name="rougail", doc="Rougail", children=[option_1, optiondescription_2]) option_1 = OptionDescription(name="rougail", doc="rougail", children=[option_2, option_3])
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_4]) option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[option_1])

View file

@ -1,31 +0,0 @@
from importlib.machinery import SourceFileLoader as _SourceFileLoader
from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec
class func:
pass
def _load_functions(path):
global _SourceFileLoader, _spec_from_loader, _module_from_spec, func
loader = _SourceFileLoader('func', path)
spec = _spec_from_loader(loader.name, loader)
func_ = _module_from_spec(spec)
loader.exec_module(func_)
for function in dir(func_):
if function.startswith('_'):
continue
setattr(func, function, getattr(func_, function))
_load_functions('tests/dictionaries/../eosfunc/test.py')
try:
from tiramisu3 import *
except:
from tiramisu import *
option_1 = BoolOption(name="server_deployed", doc="server_deployed", default=True, properties=frozenset({"mandatory", "normal"}))
option_3 = StrOption(name="mode_conteneur_actif", doc="No change", default="non", properties=frozenset({"expert", "force_store_value", "mandatory"}))
optiondescription_2 = OptionDescription(name="general", doc="général", children=[option_3], properties=frozenset({"expert"}))
optiondescription_8 = OptionDescription(name="rougail", doc="Rougail", children=[option_1, optiondescription_2])
optiondescription_7 = OptionDescription(name="1", doc="1", children=[optiondescription_8])
option_4 = BoolOption(name="server_deployed", doc="server_deployed", default=True, properties=frozenset({"mandatory", "normal"}))
option_6 = StrOption(name="mode_conteneur_actif", doc="No change", default="non", properties=frozenset({"expert", "force_store_value", "mandatory"}))
optiondescription_5 = OptionDescription(name="general", doc="général", children=[option_6], properties=frozenset({"expert"}))
optiondescription_10 = OptionDescription(name="rougail", doc="Rougail", children=[option_4, optiondescription_5])
optiondescription_9 = OptionDescription(name="2", doc="2", children=[optiondescription_10])
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_7, optiondescription_9])

View file

@ -2,23 +2,19 @@ from importlib.machinery import SourceFileLoader as _SourceFileLoader
from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec
class func: class func:
pass pass
_loader = _SourceFileLoader('func', 'tests/dictionaries/../eosfunc/test.py')
def _load_functions(path): _spec = _spec_from_loader(_loader.name, _loader)
global _SourceFileLoader, _spec_from_loader, _module_from_spec, func _func = _module_from_spec(_spec)
loader = _SourceFileLoader('func', path) _loader.exec_module(_func)
spec = _spec_from_loader(loader.name, loader) for function in dir(_func):
func_ = _module_from_spec(spec) if function.startswith('_'):
loader.exec_module(func_) continue
for function in dir(func_): setattr(func, function, getattr(_func, function))
if function.startswith('_'):
continue
setattr(func, function, getattr(func_, function))
_load_functions('tests/dictionaries/../eosfunc/test.py')
try: try:
from tiramisu3 import * from tiramisu3 import *
except: except:
from tiramisu import * from tiramisu import *
option_2 = StrOption(name="mode_conteneur_actif", doc="No change", default="non", properties=frozenset({"force_default_on_freeze", "frozen", "hidden", "mandatory", "normal"})) option_3 = StrOption(name="mode_conteneur_actif", doc="No change", default="non", properties=frozenset({"force_default_on_freeze", "frozen", "hidden", "mandatory", "normal"}))
optiondescription_1 = OptionDescription(name="general", doc="général", children=[option_2], properties=frozenset({"normal"})) option_2 = OptionDescription(name="general", doc="général", children=[option_3], properties=frozenset({"normal"}))
optiondescription_3 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_1]) option_1 = OptionDescription(name="rougail", doc="rougail", children=[option_2])
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_3]) option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[option_1])

View file

@ -1,29 +0,0 @@
from importlib.machinery import SourceFileLoader as _SourceFileLoader
from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec
class func:
pass
def _load_functions(path):
global _SourceFileLoader, _spec_from_loader, _module_from_spec, func
loader = _SourceFileLoader('func', path)
spec = _spec_from_loader(loader.name, loader)
func_ = _module_from_spec(spec)
loader.exec_module(func_)
for function in dir(func_):
if function.startswith('_'):
continue
setattr(func, function, getattr(func_, function))
_load_functions('tests/dictionaries/../eosfunc/test.py')
try:
from tiramisu3 import *
except:
from tiramisu import *
option_2 = StrOption(name="mode_conteneur_actif", doc="No change", default="non", properties=frozenset({"force_default_on_freeze", "frozen", "hidden", "mandatory", "normal"}))
optiondescription_1 = OptionDescription(name="general", doc="général", children=[option_2], properties=frozenset({"normal"}))
optiondescription_6 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_1])
optiondescription_5 = OptionDescription(name="1", doc="1", children=[optiondescription_6])
option_4 = StrOption(name="mode_conteneur_actif", doc="No change", default="non", properties=frozenset({"force_default_on_freeze", "frozen", "hidden", "mandatory", "normal"}))
optiondescription_3 = OptionDescription(name="general", doc="général", children=[option_4], properties=frozenset({"normal"}))
optiondescription_8 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_3])
optiondescription_7 = OptionDescription(name="2", doc="2", children=[optiondescription_8])
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_5, optiondescription_7])

View file

@ -2,24 +2,20 @@ from importlib.machinery import SourceFileLoader as _SourceFileLoader
from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec
class func: class func:
pass pass
_loader = _SourceFileLoader('func', 'tests/dictionaries/../eosfunc/test.py')
def _load_functions(path): _spec = _spec_from_loader(_loader.name, _loader)
global _SourceFileLoader, _spec_from_loader, _module_from_spec, func _func = _module_from_spec(_spec)
loader = _SourceFileLoader('func', path) _loader.exec_module(_func)
spec = _spec_from_loader(loader.name, loader) for function in dir(_func):
func_ = _module_from_spec(spec) if function.startswith('_'):
loader.exec_module(func_) continue
for function in dir(func_): setattr(func, function, getattr(_func, function))
if function.startswith('_'):
continue
setattr(func, function, getattr(func_, function))
_load_functions('tests/dictionaries/../eosfunc/test.py')
try: try:
from tiramisu3 import * from tiramisu3 import *
except: except:
from tiramisu import * from tiramisu import *
option_2 = StrOption(name="mode_conteneur_actif", doc="No change", default="non", properties=frozenset({"force_default_on_freeze", "frozen", "hidden", "mandatory", "normal"})) option_3 = StrOption(name="mode_conteneur_actif", doc="No change", default="non", properties=frozenset({"force_default_on_freeze", "frozen", "hidden", "mandatory", "normal"}))
option_3 = StrOption(name="without_type", doc="without_type", default="non", properties=frozenset({"mandatory", "normal"})) option_4 = StrOption(name="without_type", doc="without_type", default="non", properties=frozenset({"mandatory", "normal"}))
optiondescription_1 = OptionDescription(name="general", doc="général", children=[option_2, option_3], properties=frozenset({"normal"})) option_2 = OptionDescription(name="general", doc="général", children=[option_3, option_4], properties=frozenset({"normal"}))
optiondescription_4 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_1]) option_1 = OptionDescription(name="rougail", doc="rougail", children=[option_2])
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_4]) option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[option_1])

View file

@ -1,31 +0,0 @@
from importlib.machinery import SourceFileLoader as _SourceFileLoader
from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec
class func:
pass
def _load_functions(path):
global _SourceFileLoader, _spec_from_loader, _module_from_spec, func
loader = _SourceFileLoader('func', path)
spec = _spec_from_loader(loader.name, loader)
func_ = _module_from_spec(spec)
loader.exec_module(func_)
for function in dir(func_):
if function.startswith('_'):
continue
setattr(func, function, getattr(func_, function))
_load_functions('tests/dictionaries/../eosfunc/test.py')
try:
from tiramisu3 import *
except:
from tiramisu import *
option_2 = StrOption(name="mode_conteneur_actif", doc="No change", default="non", properties=frozenset({"force_default_on_freeze", "frozen", "hidden", "mandatory", "normal"}))
option_3 = StrOption(name="without_type", doc="without_type", default="non", properties=frozenset({"mandatory", "normal"}))
optiondescription_1 = OptionDescription(name="general", doc="général", children=[option_2, option_3], properties=frozenset({"normal"}))
optiondescription_8 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_1])
optiondescription_7 = OptionDescription(name="1", doc="1", children=[optiondescription_8])
option_5 = StrOption(name="mode_conteneur_actif", doc="No change", default="non", properties=frozenset({"force_default_on_freeze", "frozen", "hidden", "mandatory", "normal"}))
option_6 = StrOption(name="without_type", doc="without_type", default="non", properties=frozenset({"mandatory", "normal"}))
optiondescription_4 = OptionDescription(name="general", doc="général", children=[option_5, option_6], properties=frozenset({"normal"}))
optiondescription_10 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_4])
optiondescription_9 = OptionDescription(name="2", doc="2", children=[optiondescription_10])
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_7, optiondescription_9])

View file

@ -2,23 +2,19 @@ from importlib.machinery import SourceFileLoader as _SourceFileLoader
from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec
class func: class func:
pass pass
_loader = _SourceFileLoader('func', 'tests/dictionaries/../eosfunc/test.py')
def _load_functions(path): _spec = _spec_from_loader(_loader.name, _loader)
global _SourceFileLoader, _spec_from_loader, _module_from_spec, func _func = _module_from_spec(_spec)
loader = _SourceFileLoader('func', path) _loader.exec_module(_func)
spec = _spec_from_loader(loader.name, loader) for function in dir(_func):
func_ = _module_from_spec(spec) if function.startswith('_'):
loader.exec_module(func_) continue
for function in dir(func_): setattr(func, function, getattr(_func, function))
if function.startswith('_'):
continue
setattr(func, function, getattr(func_, function))
_load_functions('tests/dictionaries/../eosfunc/test.py')
try: try:
from tiramisu3 import * from tiramisu3 import *
except: except:
from tiramisu import * from tiramisu import *
option_2 = StrOption(name="mode_conteneur_actif", doc="No change", default="non", properties=frozenset({"force_default_on_freeze", "frozen", "hidden", "mandatory", "normal"})) option_3 = StrOption(name="mode_conteneur_actif", doc="No change", default="non", properties=frozenset({"force_default_on_freeze", "frozen", "hidden", "mandatory", "normal"}))
optiondescription_1 = OptionDescription(name="general", doc="général", children=[option_2], properties=frozenset({"normal"})) option_2 = OptionDescription(name="general", doc="général", children=[option_3], properties=frozenset({"normal"}))
optiondescription_3 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_1]) option_1 = OptionDescription(name="rougail", doc="rougail", children=[option_2])
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_3]) option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[option_1])

View file

@ -1,29 +0,0 @@
from importlib.machinery import SourceFileLoader as _SourceFileLoader
from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec
class func:
pass
def _load_functions(path):
global _SourceFileLoader, _spec_from_loader, _module_from_spec, func
loader = _SourceFileLoader('func', path)
spec = _spec_from_loader(loader.name, loader)
func_ = _module_from_spec(spec)
loader.exec_module(func_)
for function in dir(func_):
if function.startswith('_'):
continue
setattr(func, function, getattr(func_, function))
_load_functions('tests/dictionaries/../eosfunc/test.py')
try:
from tiramisu3 import *
except:
from tiramisu import *
option_2 = StrOption(name="mode_conteneur_actif", doc="No change", default="non", properties=frozenset({"force_default_on_freeze", "frozen", "hidden", "mandatory", "normal"}))
optiondescription_1 = OptionDescription(name="general", doc="général", children=[option_2], properties=frozenset({"normal"}))
optiondescription_6 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_1])
optiondescription_5 = OptionDescription(name="1", doc="1", children=[optiondescription_6])
option_4 = StrOption(name="mode_conteneur_actif", doc="No change", default="non", properties=frozenset({"force_default_on_freeze", "frozen", "hidden", "mandatory", "normal"}))
optiondescription_3 = OptionDescription(name="general", doc="général", children=[option_4], properties=frozenset({"normal"}))
optiondescription_8 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_3])
optiondescription_7 = OptionDescription(name="2", doc="2", children=[optiondescription_8])
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_5, optiondescription_7])

View file

@ -2,24 +2,20 @@ from importlib.machinery import SourceFileLoader as _SourceFileLoader
from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec
class func: class func:
pass pass
_loader = _SourceFileLoader('func', 'tests/dictionaries/../eosfunc/test.py')
def _load_functions(path): _spec = _spec_from_loader(_loader.name, _loader)
global _SourceFileLoader, _spec_from_loader, _module_from_spec, func _func = _module_from_spec(_spec)
loader = _SourceFileLoader('func', path) _loader.exec_module(_func)
spec = _spec_from_loader(loader.name, loader) for function in dir(_func):
func_ = _module_from_spec(spec) if function.startswith('_'):
loader.exec_module(func_) continue
for function in dir(func_): setattr(func, function, getattr(_func, function))
if function.startswith('_'):
continue
setattr(func, function, getattr(func_, function))
_load_functions('tests/dictionaries/../eosfunc/test.py')
try: try:
from tiramisu3 import * from tiramisu3 import *
except: except:
from tiramisu import * from tiramisu import *
option_2 = StrOption(name="mode_conteneur_actif1", doc="No change", default="non", properties=frozenset({"force_default_on_freeze", "frozen", "hidden", "mandatory", "normal"})) option_3 = StrOption(name="mode_conteneur_actif1", doc="No change", default="non", properties=frozenset({"force_default_on_freeze", "frozen", "hidden", "mandatory", "normal"}))
option_3 = StrOption(name="mode_conteneur_actif", doc="No change", default="non", properties=frozenset({"force_default_on_freeze", "frozen", "hidden", "mandatory", "normal"})) option_4 = StrOption(name="mode_conteneur_actif", doc="No change", default="non", properties=frozenset({"force_default_on_freeze", "frozen", "hidden", "mandatory", "normal"}))
optiondescription_1 = OptionDescription(name="general", doc="général", children=[option_2, option_3], properties=frozenset({"normal"})) option_2 = OptionDescription(name="general", doc="général", children=[option_3, option_4], properties=frozenset({"normal"}))
optiondescription_4 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_1]) option_1 = OptionDescription(name="rougail", doc="rougail", children=[option_2])
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_4]) option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[option_1])

View file

@ -1,31 +0,0 @@
from importlib.machinery import SourceFileLoader as _SourceFileLoader
from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec
class func:
pass
def _load_functions(path):
global _SourceFileLoader, _spec_from_loader, _module_from_spec, func
loader = _SourceFileLoader('func', path)
spec = _spec_from_loader(loader.name, loader)
func_ = _module_from_spec(spec)
loader.exec_module(func_)
for function in dir(func_):
if function.startswith('_'):
continue
setattr(func, function, getattr(func_, function))
_load_functions('tests/dictionaries/../eosfunc/test.py')
try:
from tiramisu3 import *
except:
from tiramisu import *
option_2 = StrOption(name="mode_conteneur_actif1", doc="No change", default="non", properties=frozenset({"force_default_on_freeze", "frozen", "hidden", "mandatory", "normal"}))
option_3 = StrOption(name="mode_conteneur_actif", doc="No change", default="non", properties=frozenset({"force_default_on_freeze", "frozen", "hidden", "mandatory", "normal"}))
optiondescription_1 = OptionDescription(name="general", doc="général", children=[option_2, option_3], properties=frozenset({"normal"}))
optiondescription_8 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_1])
optiondescription_7 = OptionDescription(name="1", doc="1", children=[optiondescription_8])
option_5 = StrOption(name="mode_conteneur_actif1", doc="No change", default="non", properties=frozenset({"force_default_on_freeze", "frozen", "hidden", "mandatory", "normal"}))
option_6 = StrOption(name="mode_conteneur_actif", doc="No change", default="non", properties=frozenset({"force_default_on_freeze", "frozen", "hidden", "mandatory", "normal"}))
optiondescription_4 = OptionDescription(name="general", doc="général", children=[option_5, option_6], properties=frozenset({"normal"}))
optiondescription_10 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_4])
optiondescription_9 = OptionDescription(name="2", doc="2", children=[optiondescription_10])
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_7, optiondescription_9])

View file

@ -2,23 +2,19 @@ from importlib.machinery import SourceFileLoader as _SourceFileLoader
from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec
class func: class func:
pass pass
_loader = _SourceFileLoader('func', 'tests/dictionaries/../eosfunc/test.py')
def _load_functions(path): _spec = _spec_from_loader(_loader.name, _loader)
global _SourceFileLoader, _spec_from_loader, _module_from_spec, func _func = _module_from_spec(_spec)
loader = _SourceFileLoader('func', path) _loader.exec_module(_func)
spec = _spec_from_loader(loader.name, loader) for function in dir(_func):
func_ = _module_from_spec(spec) if function.startswith('_'):
loader.exec_module(func_) continue
for function in dir(func_): setattr(func, function, getattr(_func, function))
if function.startswith('_'):
continue
setattr(func, function, getattr(func_, function))
_load_functions('tests/dictionaries/../eosfunc/test.py')
try: try:
from tiramisu3 import * from tiramisu3 import *
except: except:
from tiramisu import * from tiramisu import *
option_1 = BoolOption(name="server_deployed", doc="server_deployed", default=False, properties=frozenset({"mandatory", "normal"})) option_2 = BoolOption(name="server_deployed", doc="server_deployed", default=False, properties=frozenset({"mandatory", "normal"}))
option_2 = StrOption(name="my_variable", doc="my_variable", default=Calculation(func.calc_val, Params((ParamValue("yes")))), properties=frozenset({"basic", "force_store_value", "hidden", Calculation(func.calc_value, Params(ParamValue('frozen'), kwargs={'condition': ParamOption(option_1, todict=True, notraisepropertyerror=True), 'expected': ParamValue(True)}))})) option_3 = StrOption(name="my_variable", doc="my_variable", default=Calculation(func.calc_val, Params((ParamValue("yes")))), properties=frozenset({"basic", "force_store_value", "hidden", Calculation(func.calc_value, Params(ParamValue('frozen'), kwargs={'condition': ParamOption(option_2, todict=True, notraisepropertyerror=True), 'expected': ParamValue(True)}))}))
optiondescription_3 = OptionDescription(name="rougail", doc="Rougail", children=[option_1, option_2]) option_1 = OptionDescription(name="rougail", doc="rougail", children=[option_2, option_3])
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_3]) option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[option_1])

View file

@ -1,29 +0,0 @@
from importlib.machinery import SourceFileLoader as _SourceFileLoader
from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec
class func:
pass
def _load_functions(path):
global _SourceFileLoader, _spec_from_loader, _module_from_spec, func
loader = _SourceFileLoader('func', path)
spec = _spec_from_loader(loader.name, loader)
func_ = _module_from_spec(spec)
loader.exec_module(func_)
for function in dir(func_):
if function.startswith('_'):
continue
setattr(func, function, getattr(func_, function))
_load_functions('tests/dictionaries/../eosfunc/test.py')
try:
from tiramisu3 import *
except:
from tiramisu import *
option_1 = BoolOption(name="server_deployed", doc="server_deployed", default=False, properties=frozenset({"mandatory", "normal"}))
option_2 = StrOption(name="my_variable", doc="my_variable", default=Calculation(func.calc_val, Params((ParamValue("yes")))), properties=frozenset({"basic", "force_store_value", "hidden", Calculation(func.calc_value, Params(ParamValue('frozen'), kwargs={'condition': ParamOption(option_1, todict=True, notraisepropertyerror=True), 'expected': ParamValue(True)}))}))
optiondescription_6 = OptionDescription(name="rougail", doc="Rougail", children=[option_1, option_2])
optiondescription_5 = OptionDescription(name="1", doc="1", children=[optiondescription_6])
option_3 = BoolOption(name="server_deployed", doc="server_deployed", default=False, properties=frozenset({"mandatory", "normal"}))
option_4 = StrOption(name="my_variable", doc="my_variable", default=Calculation(func.calc_val, Params((ParamValue("yes")))), properties=frozenset({"basic", "force_store_value", "hidden", Calculation(func.calc_value, Params(ParamValue('frozen'), kwargs={'condition': ParamOption(option_3, todict=True, notraisepropertyerror=True), 'expected': ParamValue(True)}))}))
optiondescription_8 = OptionDescription(name="rougail", doc="Rougail", children=[option_3, option_4])
optiondescription_7 = OptionDescription(name="2", doc="2", children=[optiondescription_8])
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_5, optiondescription_7])

View file

@ -2,24 +2,20 @@ from importlib.machinery import SourceFileLoader as _SourceFileLoader
from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec
class func: class func:
pass pass
_loader = _SourceFileLoader('func', 'tests/dictionaries/../eosfunc/test.py')
def _load_functions(path): _spec = _spec_from_loader(_loader.name, _loader)
global _SourceFileLoader, _spec_from_loader, _module_from_spec, func _func = _module_from_spec(_spec)
loader = _SourceFileLoader('func', path) _loader.exec_module(_func)
spec = _spec_from_loader(loader.name, loader) for function in dir(_func):
func_ = _module_from_spec(spec) if function.startswith('_'):
loader.exec_module(func_) continue
for function in dir(func_): setattr(func, function, getattr(_func, function))
if function.startswith('_'):
continue
setattr(func, function, getattr(func_, function))
_load_functions('tests/dictionaries/../eosfunc/test.py')
try: try:
from tiramisu3 import * from tiramisu3 import *
except: except:
from tiramisu import * from tiramisu import *
option_3 = StrOption(name="mode_conteneur_actif1", doc="No change", default="non", properties=frozenset({"mandatory", "normal"})) option_4 = StrOption(name="mode_conteneur_actif1", doc="No change", default="non", properties=frozenset({"mandatory", "normal"}))
option_2 = StrOption(name="mode_conteneur_actif", doc="No change", default=Calculation(func.calc_val, Params((ParamOption(option_3)))), properties=frozenset({"force_default_on_freeze", "frozen", "hidden", "normal"})) option_3 = StrOption(name="mode_conteneur_actif", doc="No change", default=Calculation(func.calc_val, Params((ParamOption(option_4)))), properties=frozenset({"force_default_on_freeze", "frozen", "hidden", "normal"}))
optiondescription_1 = OptionDescription(name="general", doc="general", children=[option_2, option_3], properties=frozenset({"normal"})) option_2 = OptionDescription(name="general", doc="general", children=[option_3, option_4], properties=frozenset({"normal"}))
optiondescription_4 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_1]) option_1 = OptionDescription(name="rougail", doc="rougail", children=[option_2])
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_4]) option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[option_1])

View file

@ -1,31 +0,0 @@
from importlib.machinery import SourceFileLoader as _SourceFileLoader
from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec
class func:
pass
def _load_functions(path):
global _SourceFileLoader, _spec_from_loader, _module_from_spec, func
loader = _SourceFileLoader('func', path)
spec = _spec_from_loader(loader.name, loader)
func_ = _module_from_spec(spec)
loader.exec_module(func_)
for function in dir(func_):
if function.startswith('_'):
continue
setattr(func, function, getattr(func_, function))
_load_functions('tests/dictionaries/../eosfunc/test.py')
try:
from tiramisu3 import *
except:
from tiramisu import *
option_3 = StrOption(name="mode_conteneur_actif1", doc="No change", default="non", properties=frozenset({"mandatory", "normal"}))
option_2 = StrOption(name="mode_conteneur_actif", doc="No change", default=Calculation(func.calc_val, Params((ParamOption(option_3)))), properties=frozenset({"force_default_on_freeze", "frozen", "hidden", "normal"}))
optiondescription_1 = OptionDescription(name="general", doc="general", children=[option_2, option_3], properties=frozenset({"normal"}))
optiondescription_8 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_1])
optiondescription_7 = OptionDescription(name="1", doc="1", children=[optiondescription_8])
option_6 = StrOption(name="mode_conteneur_actif1", doc="No change", default="non", properties=frozenset({"mandatory", "normal"}))
option_5 = StrOption(name="mode_conteneur_actif", doc="No change", default=Calculation(func.calc_val, Params((ParamOption(option_6)))), properties=frozenset({"force_default_on_freeze", "frozen", "hidden", "normal"}))
optiondescription_4 = OptionDescription(name="general", doc="general", children=[option_5, option_6], properties=frozenset({"normal"}))
optiondescription_10 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_4])
optiondescription_9 = OptionDescription(name="2", doc="2", children=[optiondescription_10])
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_7, optiondescription_9])

View file

@ -2,24 +2,20 @@ from importlib.machinery import SourceFileLoader as _SourceFileLoader
from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec
class func: class func:
pass pass
_loader = _SourceFileLoader('func', 'tests/dictionaries/../eosfunc/test.py')
def _load_functions(path): _spec = _spec_from_loader(_loader.name, _loader)
global _SourceFileLoader, _spec_from_loader, _module_from_spec, func _func = _module_from_spec(_spec)
loader = _SourceFileLoader('func', path) _loader.exec_module(_func)
spec = _spec_from_loader(loader.name, loader) for function in dir(_func):
func_ = _module_from_spec(spec) if function.startswith('_'):
loader.exec_module(func_) continue
for function in dir(func_): setattr(func, function, getattr(_func, function))
if function.startswith('_'):
continue
setattr(func, function, getattr(func_, function))
_load_functions('tests/dictionaries/../eosfunc/test.py')
try: try:
from tiramisu3 import * from tiramisu3 import *
except: except:
from tiramisu import * from tiramisu import *
option_2 = StrOption(name="mode_conteneur_actif", doc="No change", default=Calculation(func.calc_val, Params(())), properties=frozenset({"force_default_on_freeze", "frozen", "hidden", "normal"})) option_3 = StrOption(name="mode_conteneur_actif", doc="No change", default=Calculation(func.calc_val, Params(())), properties=frozenset({"force_default_on_freeze", "frozen", "hidden", "normal"}))
option_3 = StrOption(name="mode_conteneur_actif1", doc="No change", default="non", properties=frozenset({"mandatory", "normal"})) option_4 = StrOption(name="mode_conteneur_actif1", doc="No change", default="non", properties=frozenset({"mandatory", "normal"}))
optiondescription_1 = OptionDescription(name="general", doc="general", children=[option_2, option_3], properties=frozenset({"normal"})) option_2 = OptionDescription(name="general", doc="general", children=[option_3, option_4], properties=frozenset({"normal"}))
optiondescription_4 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_1]) option_1 = OptionDescription(name="rougail", doc="rougail", children=[option_2])
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_4]) option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[option_1])

View file

@ -1,31 +0,0 @@
from importlib.machinery import SourceFileLoader as _SourceFileLoader
from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec
class func:
pass
def _load_functions(path):
global _SourceFileLoader, _spec_from_loader, _module_from_spec, func
loader = _SourceFileLoader('func', path)
spec = _spec_from_loader(loader.name, loader)
func_ = _module_from_spec(spec)
loader.exec_module(func_)
for function in dir(func_):
if function.startswith('_'):
continue
setattr(func, function, getattr(func_, function))
_load_functions('tests/dictionaries/../eosfunc/test.py')
try:
from tiramisu3 import *
except:
from tiramisu import *
option_2 = StrOption(name="mode_conteneur_actif", doc="No change", default=Calculation(func.calc_val, Params(())), properties=frozenset({"force_default_on_freeze", "frozen", "hidden", "normal"}))
option_3 = StrOption(name="mode_conteneur_actif1", doc="No change", default="non", properties=frozenset({"mandatory", "normal"}))
optiondescription_1 = OptionDescription(name="general", doc="general", children=[option_2, option_3], properties=frozenset({"normal"}))
optiondescription_8 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_1])
optiondescription_7 = OptionDescription(name="1", doc="1", children=[optiondescription_8])
option_5 = StrOption(name="mode_conteneur_actif", doc="No change", default=Calculation(func.calc_val, Params(())), properties=frozenset({"force_default_on_freeze", "frozen", "hidden", "normal"}))
option_6 = StrOption(name="mode_conteneur_actif1", doc="No change", default="non", properties=frozenset({"mandatory", "normal"}))
optiondescription_4 = OptionDescription(name="general", doc="general", children=[option_5, option_6], properties=frozenset({"normal"}))
optiondescription_10 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_4])
optiondescription_9 = OptionDescription(name="2", doc="2", children=[optiondescription_10])
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_7, optiondescription_9])

View file

@ -2,23 +2,19 @@ from importlib.machinery import SourceFileLoader as _SourceFileLoader
from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec
class func: class func:
pass pass
_loader = _SourceFileLoader('func', 'tests/dictionaries/../eosfunc/test.py')
def _load_functions(path): _spec = _spec_from_loader(_loader.name, _loader)
global _SourceFileLoader, _spec_from_loader, _module_from_spec, func _func = _module_from_spec(_spec)
loader = _SourceFileLoader('func', path) _loader.exec_module(_func)
spec = _spec_from_loader(loader.name, loader) for function in dir(_func):
func_ = _module_from_spec(spec) if function.startswith('_'):
loader.exec_module(func_) continue
for function in dir(func_): setattr(func, function, getattr(_func, function))
if function.startswith('_'):
continue
setattr(func, function, getattr(func_, function))
_load_functions('tests/dictionaries/../eosfunc/test.py')
try: try:
from tiramisu3 import * from tiramisu3 import *
except: except:
from tiramisu import * from tiramisu import *
option_2 = DomainnameOption(name="domain", doc="Description", default="my.domain.name", type='domainname', allow_ip=False, properties=frozenset({"mandatory", "normal"})) option_3 = DomainnameOption(name="domain", doc="Description", default="my.domain.name", type='domainname', allow_ip=False, properties=frozenset({"mandatory", "normal"}))
optiondescription_1 = OptionDescription(name="general", doc="general", children=[option_2], properties=frozenset({"normal"})) option_2 = OptionDescription(name="general", doc="general", children=[option_3], properties=frozenset({"normal"}))
optiondescription_3 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_1]) option_1 = OptionDescription(name="rougail", doc="rougail", children=[option_2])
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_3]) option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[option_1])

View file

@ -1,29 +0,0 @@
from importlib.machinery import SourceFileLoader as _SourceFileLoader
from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec
class func:
pass
def _load_functions(path):
global _SourceFileLoader, _spec_from_loader, _module_from_spec, func
loader = _SourceFileLoader('func', path)
spec = _spec_from_loader(loader.name, loader)
func_ = _module_from_spec(spec)
loader.exec_module(func_)
for function in dir(func_):
if function.startswith('_'):
continue
setattr(func, function, getattr(func_, function))
_load_functions('tests/dictionaries/../eosfunc/test.py')
try:
from tiramisu3 import *
except:
from tiramisu import *
option_2 = DomainnameOption(name="domain", doc="Description", default="my.domain.name", type='domainname', allow_ip=False, properties=frozenset({"mandatory", "normal"}))
optiondescription_1 = OptionDescription(name="general", doc="general", children=[option_2], properties=frozenset({"normal"}))
optiondescription_6 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_1])
optiondescription_5 = OptionDescription(name="1", doc="1", children=[optiondescription_6])
option_4 = DomainnameOption(name="domain", doc="Description", default="my.domain.name", type='domainname', allow_ip=False, properties=frozenset({"mandatory", "normal"}))
optiondescription_3 = OptionDescription(name="general", doc="general", children=[option_4], properties=frozenset({"normal"}))
optiondescription_8 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_3])
optiondescription_7 = OptionDescription(name="2", doc="2", children=[optiondescription_8])
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_5, optiondescription_7])

View file

@ -2,38 +2,33 @@ from importlib.machinery import SourceFileLoader as _SourceFileLoader
from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec
class func: class func:
pass pass
_loader = _SourceFileLoader('func', 'tests/dictionaries/../eosfunc/test.py')
def _load_functions(path): _spec = _spec_from_loader(_loader.name, _loader)
global _SourceFileLoader, _spec_from_loader, _module_from_spec, func _func = _module_from_spec(_spec)
loader = _SourceFileLoader('func', path) _loader.exec_module(_func)
spec = _spec_from_loader(loader.name, loader) for function in dir(_func):
func_ = _module_from_spec(spec) if function.startswith('_'):
loader.exec_module(func_) continue
for function in dir(func_): setattr(func, function, getattr(_func, function))
if function.startswith('_'):
continue
setattr(func, function, getattr(func_, function))
_load_functions('tests/dictionaries/../eosfunc/test.py')
try: try:
from tiramisu3 import * from tiramisu3 import *
except: except:
from tiramisu import * from tiramisu import *
option_2 = StrOption(name="mode_conteneur_actif", doc="Description", default="non", properties=frozenset({"mandatory", "normal"})) option_3 = StrOption(name="mode_conteneur_actif", doc="Description", default="non", properties=frozenset({"mandatory", "normal"}))
optiondescription_1 = OptionDescription(name="general", doc="general", children=[option_2], properties=frozenset({"normal"})) option_2 = OptionDescription(name="general", doc="general", children=[option_3], properties=frozenset({"normal"}))
optiondescription_12 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_1]) option_1 = OptionDescription(name="rougail", doc="rougail", children=[option_2])
option_7 = FilenameOption(name="name", doc="name", default="/etc/file") option_8 = FilenameOption(name="name", doc="name", default="/etc/file")
option_6 = BoolOption(name="activate", doc="activate", default=True)
optiondescription_5 = OptionDescription(name="file", doc="file", children=[option_7, option_6])
optiondescription_5.impl_set_information('source', "file")
option_10 = FilenameOption(name="name", doc="name", default="/etc/file2")
option_9 = BoolOption(name="activate", doc="activate", default=True) option_9 = BoolOption(name="activate", doc="activate", default=True)
optiondescription_8 = OptionDescription(name="file2", doc="file2", children=[option_10, option_9]) option_7 = OptionDescription(name="file", doc="file", children=[option_8, option_9])
optiondescription_8.impl_set_information('engine', "jinja2") option_7.impl_set_information('source', "file")
optiondescription_8.impl_set_information('source', "file2") option_11 = FilenameOption(name="name", doc="name", default="/etc/file2")
optiondescription_4 = OptionDescription(name="files", doc="files", children=[optiondescription_5, optiondescription_8]) option_12 = BoolOption(name="activate", doc="activate", default=True)
option_3 = BoolOption(name="activate", doc="activate", default=True) option_10 = OptionDescription(name="file2", doc="file2", children=[option_11, option_12])
option_11 = BoolOption(name="manage", doc="manage", default=True) option_10.impl_set_information('engine', "jinja2")
optiondescription_14 = OptionDescription(name="test_service", doc="test.service", children=[optiondescription_4, option_3, option_11]) option_10.impl_set_information('source', "file2")
optiondescription_14.impl_set_information('type', "service") option_6 = OptionDescription(name="files", doc="files", children=[option_7, option_10])
optiondescription_13 = OptionDescription(name="services", doc="services", children=[optiondescription_14], properties=frozenset({"hidden"})) option_13 = BoolOption(name="activate", doc="activate", default=True)
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_12, optiondescription_13]) option_14 = BoolOption(name="manage", doc="manage", default=True)
option_5 = OptionDescription(name="test_service", doc="test.service", children=[option_6, option_13, option_14])
option_4 = OptionDescription(name="services", doc="services", children=[option_5], properties=frozenset({"hidden"}))
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[option_1, option_4])

View file

@ -1,59 +0,0 @@
from importlib.machinery import SourceFileLoader as _SourceFileLoader
from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec
class func:
pass
def _load_functions(path):
global _SourceFileLoader, _spec_from_loader, _module_from_spec, func
loader = _SourceFileLoader('func', path)
spec = _spec_from_loader(loader.name, loader)
func_ = _module_from_spec(spec)
loader.exec_module(func_)
for function in dir(func_):
if function.startswith('_'):
continue
setattr(func, function, getattr(func_, function))
_load_functions('tests/dictionaries/../eosfunc/test.py')
try:
from tiramisu3 import *
except:
from tiramisu import *
option_2 = StrOption(name="mode_conteneur_actif", doc="Description", default="non", properties=frozenset({"mandatory", "normal"}))
optiondescription_1 = OptionDescription(name="general", doc="general", children=[option_2], properties=frozenset({"normal"}))
optiondescription_24 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_1])
option_9 = FilenameOption(name="name", doc="name", default="/etc/file")
option_8 = BoolOption(name="activate", doc="activate", default=True)
optiondescription_7 = OptionDescription(name="file", doc="file", children=[option_9, option_8])
optiondescription_7.impl_set_information('source', "file")
option_12 = FilenameOption(name="name", doc="name", default="/etc/file2")
option_11 = BoolOption(name="activate", doc="activate", default=True)
optiondescription_10 = OptionDescription(name="file2", doc="file2", children=[option_12, option_11])
optiondescription_10.impl_set_information('engine', "jinja2")
optiondescription_10.impl_set_information('source', "file2")
optiondescription_6 = OptionDescription(name="files", doc="files", children=[optiondescription_7, optiondescription_10])
option_5 = BoolOption(name="activate", doc="activate", default=True)
option_13 = BoolOption(name="manage", doc="manage", default=True)
optiondescription_26 = OptionDescription(name="test_service", doc="test.service", children=[optiondescription_6, option_5, option_13])
optiondescription_26.impl_set_information('type', "service")
optiondescription_25 = OptionDescription(name="services", doc="services", children=[optiondescription_26], properties=frozenset({"hidden"}))
optiondescription_23 = OptionDescription(name="1", doc="1", children=[optiondescription_24, optiondescription_25])
option_4 = StrOption(name="mode_conteneur_actif", doc="Description", default="non", properties=frozenset({"mandatory", "normal"}))
optiondescription_3 = OptionDescription(name="general", doc="general", children=[option_4], properties=frozenset({"normal"}))
optiondescription_28 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_3])
option_18 = FilenameOption(name="name", doc="name", default="/etc/file")
option_17 = BoolOption(name="activate", doc="activate", default=True)
optiondescription_16 = OptionDescription(name="file", doc="file", children=[option_18, option_17])
optiondescription_16.impl_set_information('source', "file")
option_21 = FilenameOption(name="name", doc="name", default="/etc/file2")
option_20 = BoolOption(name="activate", doc="activate", default=True)
optiondescription_19 = OptionDescription(name="file2", doc="file2", children=[option_21, option_20])
optiondescription_19.impl_set_information('engine', "jinja2")
optiondescription_19.impl_set_information('source', "file2")
optiondescription_15 = OptionDescription(name="files", doc="files", children=[optiondescription_16, optiondescription_19])
option_14 = BoolOption(name="activate", doc="activate", default=True)
option_22 = BoolOption(name="manage", doc="manage", default=True)
optiondescription_30 = OptionDescription(name="test_service", doc="test.service", children=[optiondescription_15, option_14, option_22])
optiondescription_30.impl_set_information('type', "service")
optiondescription_29 = OptionDescription(name="services", doc="services", children=[optiondescription_30], properties=frozenset({"hidden"}))
optiondescription_27 = OptionDescription(name="2", doc="2", children=[optiondescription_28, optiondescription_29])
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_23, optiondescription_27])

View file

@ -2,42 +2,37 @@ from importlib.machinery import SourceFileLoader as _SourceFileLoader
from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec
class func: class func:
pass pass
_loader = _SourceFileLoader('func', 'tests/dictionaries/../eosfunc/test.py')
def _load_functions(path): _spec = _spec_from_loader(_loader.name, _loader)
global _SourceFileLoader, _spec_from_loader, _module_from_spec, func _func = _module_from_spec(_spec)
loader = _SourceFileLoader('func', path) _loader.exec_module(_func)
spec = _spec_from_loader(loader.name, loader) for function in dir(_func):
func_ = _module_from_spec(spec) if function.startswith('_'):
loader.exec_module(func_) continue
for function in dir(func_): setattr(func, function, getattr(_func, function))
if function.startswith('_'):
continue
setattr(func, function, getattr(func_, function))
_load_functions('tests/dictionaries/../eosfunc/test.py')
try: try:
from tiramisu3 import * from tiramisu3 import *
except: except:
from tiramisu import * from tiramisu import *
option_2 = StrOption(name="mode_conteneur_actif", doc="Description", default="non", properties=frozenset({"mandatory", "normal"})) option_3 = StrOption(name="mode_conteneur_actif", doc="Description", default="non", properties=frozenset({"mandatory", "normal"}))
optiondescription_1 = OptionDescription(name="general", doc="general", children=[option_2], properties=frozenset({"normal"})) option_2 = OptionDescription(name="general", doc="general", children=[option_3], properties=frozenset({"normal"}))
optiondescription_15 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_1]) option_1 = OptionDescription(name="rougail", doc="rougail", children=[option_2])
option_7 = FilenameOption(name="name", doc="name", default="/etc/file") option_8 = FilenameOption(name="name", doc="name", default="/etc/file")
option_6 = BoolOption(name="activate", doc="activate", default=True)
optiondescription_5 = OptionDescription(name="file", doc="file", children=[option_7, option_6])
optiondescription_5.impl_set_information('source', "file")
option_10 = FilenameOption(name="name", doc="name", default="/etc/file2")
option_9 = BoolOption(name="activate", doc="activate", default=True) option_9 = BoolOption(name="activate", doc="activate", default=True)
optiondescription_8 = OptionDescription(name="file2", doc="file2", children=[option_10, option_9]) option_7 = OptionDescription(name="file", doc="file", children=[option_8, option_9])
optiondescription_8.impl_set_information('engine', "jinja2") option_7.impl_set_information('source', "file")
optiondescription_8.impl_set_information('source', "file2") option_11 = FilenameOption(name="name", doc="name", default="/etc/file2")
option_13 = FilenameOption(name="name", doc="name", default="/etc/file3") option_12 = BoolOption(name="activate", doc="activate", default=True)
option_12 = BoolOption(name="activate", doc="activate", default=False) option_10 = OptionDescription(name="file2", doc="file2", children=[option_11, option_12])
optiondescription_11 = OptionDescription(name="file3", doc="file3", children=[option_13, option_12]) option_10.impl_set_information('engine', "jinja2")
optiondescription_11.impl_set_information('source', "file3") option_10.impl_set_information('source', "file2")
optiondescription_4 = OptionDescription(name="files", doc="files", children=[optiondescription_5, optiondescription_8, optiondescription_11]) option_14 = FilenameOption(name="name", doc="name", default="/etc/file3")
option_3 = BoolOption(name="activate", doc="activate", default=True) option_15 = BoolOption(name="activate", doc="activate", default=False)
option_14 = BoolOption(name="manage", doc="manage", default=True) option_13 = OptionDescription(name="file3", doc="file3", children=[option_14, option_15])
optiondescription_17 = OptionDescription(name="test_service", doc="test.service", children=[optiondescription_4, option_3, option_14]) option_13.impl_set_information('source', "file3")
optiondescription_17.impl_set_information('type', "service") option_6 = OptionDescription(name="files", doc="files", children=[option_7, option_10, option_13])
optiondescription_16 = OptionDescription(name="services", doc="services", children=[optiondescription_17], properties=frozenset({"hidden"})) option_16 = BoolOption(name="activate", doc="activate", default=True)
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_15, optiondescription_16]) option_17 = BoolOption(name="manage", doc="manage", default=True)
option_5 = OptionDescription(name="test_service", doc="test.service", children=[option_6, option_16, option_17])
option_4 = OptionDescription(name="services", doc="services", children=[option_5], properties=frozenset({"hidden"}))
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[option_1, option_4])

View file

@ -1,67 +0,0 @@
from importlib.machinery import SourceFileLoader as _SourceFileLoader
from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec
class func:
pass
def _load_functions(path):
global _SourceFileLoader, _spec_from_loader, _module_from_spec, func
loader = _SourceFileLoader('func', path)
spec = _spec_from_loader(loader.name, loader)
func_ = _module_from_spec(spec)
loader.exec_module(func_)
for function in dir(func_):
if function.startswith('_'):
continue
setattr(func, function, getattr(func_, function))
_load_functions('tests/dictionaries/../eosfunc/test.py')
try:
from tiramisu3 import *
except:
from tiramisu import *
option_2 = StrOption(name="mode_conteneur_actif", doc="Description", default="non", properties=frozenset({"mandatory", "normal"}))
optiondescription_1 = OptionDescription(name="general", doc="general", children=[option_2], properties=frozenset({"normal"}))
optiondescription_30 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_1])
option_9 = FilenameOption(name="name", doc="name", default="/etc/file")
option_8 = BoolOption(name="activate", doc="activate", default=True)
optiondescription_7 = OptionDescription(name="file", doc="file", children=[option_9, option_8])
optiondescription_7.impl_set_information('source', "file")
option_12 = FilenameOption(name="name", doc="name", default="/etc/file2")
option_11 = BoolOption(name="activate", doc="activate", default=True)
optiondescription_10 = OptionDescription(name="file2", doc="file2", children=[option_12, option_11])
optiondescription_10.impl_set_information('engine', "jinja2")
optiondescription_10.impl_set_information('source', "file2")
option_15 = FilenameOption(name="name", doc="name", default="/etc/file3")
option_14 = BoolOption(name="activate", doc="activate", default=False)
optiondescription_13 = OptionDescription(name="file3", doc="file3", children=[option_15, option_14])
optiondescription_13.impl_set_information('source', "file3")
optiondescription_6 = OptionDescription(name="files", doc="files", children=[optiondescription_7, optiondescription_10, optiondescription_13])
option_5 = BoolOption(name="activate", doc="activate", default=True)
option_16 = BoolOption(name="manage", doc="manage", default=True)
optiondescription_32 = OptionDescription(name="test_service", doc="test.service", children=[optiondescription_6, option_5, option_16])
optiondescription_32.impl_set_information('type', "service")
optiondescription_31 = OptionDescription(name="services", doc="services", children=[optiondescription_32], properties=frozenset({"hidden"}))
optiondescription_29 = OptionDescription(name="1", doc="1", children=[optiondescription_30, optiondescription_31])
option_4 = StrOption(name="mode_conteneur_actif", doc="Description", default="non", properties=frozenset({"mandatory", "normal"}))
optiondescription_3 = OptionDescription(name="general", doc="general", children=[option_4], properties=frozenset({"normal"}))
optiondescription_34 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_3])
option_21 = FilenameOption(name="name", doc="name", default="/etc/file")
option_20 = BoolOption(name="activate", doc="activate", default=True)
optiondescription_19 = OptionDescription(name="file", doc="file", children=[option_21, option_20])
optiondescription_19.impl_set_information('source', "file")
option_24 = FilenameOption(name="name", doc="name", default="/etc/file2")
option_23 = BoolOption(name="activate", doc="activate", default=True)
optiondescription_22 = OptionDescription(name="file2", doc="file2", children=[option_24, option_23])
optiondescription_22.impl_set_information('engine', "jinja2")
optiondescription_22.impl_set_information('source', "file2")
option_27 = FilenameOption(name="name", doc="name", default="/etc/file3")
option_26 = BoolOption(name="activate", doc="activate", default=False)
optiondescription_25 = OptionDescription(name="file3", doc="file3", children=[option_27, option_26])
optiondescription_25.impl_set_information('source', "file3")
optiondescription_18 = OptionDescription(name="files", doc="files", children=[optiondescription_19, optiondescription_22, optiondescription_25])
option_17 = BoolOption(name="activate", doc="activate", default=True)
option_28 = BoolOption(name="manage", doc="manage", default=True)
optiondescription_36 = OptionDescription(name="test_service", doc="test.service", children=[optiondescription_18, option_17, option_28])
optiondescription_36.impl_set_information('type', "service")
optiondescription_35 = OptionDescription(name="services", doc="services", children=[optiondescription_36], properties=frozenset({"hidden"}))
optiondescription_33 = OptionDescription(name="2", doc="2", children=[optiondescription_34, optiondescription_35])
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_29, optiondescription_33])

View file

@ -2,38 +2,33 @@ from importlib.machinery import SourceFileLoader as _SourceFileLoader
from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec
class func: class func:
pass pass
_loader = _SourceFileLoader('func', 'tests/dictionaries/../eosfunc/test.py')
def _load_functions(path): _spec = _spec_from_loader(_loader.name, _loader)
global _SourceFileLoader, _spec_from_loader, _module_from_spec, func _func = _module_from_spec(_spec)
loader = _SourceFileLoader('func', path) _loader.exec_module(_func)
spec = _spec_from_loader(loader.name, loader) for function in dir(_func):
func_ = _module_from_spec(spec) if function.startswith('_'):
loader.exec_module(func_) continue
for function in dir(func_): setattr(func, function, getattr(_func, function))
if function.startswith('_'):
continue
setattr(func, function, getattr(func_, function))
_load_functions('tests/dictionaries/../eosfunc/test.py')
try: try:
from tiramisu3 import * from tiramisu3 import *
except: except:
from tiramisu import * from tiramisu import *
option_2 = StrOption(name="mode_conteneur_actif", doc="Description", default="non", properties=frozenset({"mandatory", "normal"})) option_3 = StrOption(name="mode_conteneur_actif", doc="Description", default="non", properties=frozenset({"mandatory", "normal"}))
optiondescription_1 = OptionDescription(name="general", doc="general", children=[option_2], properties=frozenset({"normal"})) option_2 = OptionDescription(name="general", doc="general", children=[option_3], properties=frozenset({"normal"}))
optiondescription_12 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_1]) option_1 = OptionDescription(name="rougail", doc="rougail", children=[option_2])
option_7 = FilenameOption(name="name", doc="name", default="/etc/file") option_8 = FilenameOption(name="name", doc="name", default="/etc/file")
option_6 = BoolOption(name="activate", doc="activate", default=True)
optiondescription_5 = OptionDescription(name="file", doc="file", children=[option_7, option_6])
optiondescription_5.impl_set_information('source', "file")
option_10 = FilenameOption(name="name", doc="name", default="/etc/file2")
option_9 = BoolOption(name="activate", doc="activate", default=True) option_9 = BoolOption(name="activate", doc="activate", default=True)
optiondescription_8 = OptionDescription(name="file2", doc="file2", children=[option_10, option_9]) option_7 = OptionDescription(name="file", doc="file", children=[option_8, option_9])
optiondescription_8.impl_set_information('engine', "jinja2") option_7.impl_set_information('source', "file")
optiondescription_8.impl_set_information('source', "file2") option_11 = FilenameOption(name="name", doc="name", default="/etc/file2")
optiondescription_4 = OptionDescription(name="files", doc="files", children=[optiondescription_5, optiondescription_8]) option_12 = BoolOption(name="activate", doc="activate", default=True)
option_3 = BoolOption(name="activate", doc="activate", default=True) option_10 = OptionDescription(name="file2", doc="file2", children=[option_11, option_12])
option_11 = BoolOption(name="manage", doc="manage", default=True) option_10.impl_set_information('engine', "jinja2")
optiondescription_14 = OptionDescription(name="test_service", doc="test.service", children=[optiondescription_4, option_3, option_11]) option_10.impl_set_information('source', "file2")
optiondescription_14.impl_set_information('type', "service") option_6 = OptionDescription(name="files", doc="files", children=[option_7, option_10])
optiondescription_13 = OptionDescription(name="services", doc="services", children=[optiondescription_14], properties=frozenset({"hidden"})) option_13 = BoolOption(name="activate", doc="activate", default=True)
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_12, optiondescription_13]) option_14 = BoolOption(name="manage", doc="manage", default=True)
option_5 = OptionDescription(name="test_service", doc="test.service", children=[option_6, option_13, option_14])
option_4 = OptionDescription(name="services", doc="services", children=[option_5], properties=frozenset({"hidden"}))
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[option_1, option_4])

View file

@ -1,59 +0,0 @@
from importlib.machinery import SourceFileLoader as _SourceFileLoader
from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec
class func:
pass
def _load_functions(path):
global _SourceFileLoader, _spec_from_loader, _module_from_spec, func
loader = _SourceFileLoader('func', path)
spec = _spec_from_loader(loader.name, loader)
func_ = _module_from_spec(spec)
loader.exec_module(func_)
for function in dir(func_):
if function.startswith('_'):
continue
setattr(func, function, getattr(func_, function))
_load_functions('tests/dictionaries/../eosfunc/test.py')
try:
from tiramisu3 import *
except:
from tiramisu import *
option_2 = StrOption(name="mode_conteneur_actif", doc="Description", default="non", properties=frozenset({"mandatory", "normal"}))
optiondescription_1 = OptionDescription(name="general", doc="general", children=[option_2], properties=frozenset({"normal"}))
optiondescription_24 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_1])
option_9 = FilenameOption(name="name", doc="name", default="/etc/file")
option_8 = BoolOption(name="activate", doc="activate", default=True)
optiondescription_7 = OptionDescription(name="file", doc="file", children=[option_9, option_8])
optiondescription_7.impl_set_information('source', "file")
option_12 = FilenameOption(name="name", doc="name", default="/etc/file2")
option_11 = BoolOption(name="activate", doc="activate", default=True)
optiondescription_10 = OptionDescription(name="file2", doc="file2", children=[option_12, option_11])
optiondescription_10.impl_set_information('engine', "jinja2")
optiondescription_10.impl_set_information('source', "file2")
optiondescription_6 = OptionDescription(name="files", doc="files", children=[optiondescription_7, optiondescription_10])
option_5 = BoolOption(name="activate", doc="activate", default=True)
option_13 = BoolOption(name="manage", doc="manage", default=True)
optiondescription_26 = OptionDescription(name="test_service", doc="test.service", children=[optiondescription_6, option_5, option_13])
optiondescription_26.impl_set_information('type', "service")
optiondescription_25 = OptionDescription(name="services", doc="services", children=[optiondescription_26], properties=frozenset({"hidden"}))
optiondescription_23 = OptionDescription(name="1", doc="1", children=[optiondescription_24, optiondescription_25])
option_4 = StrOption(name="mode_conteneur_actif", doc="Description", default="non", properties=frozenset({"mandatory", "normal"}))
optiondescription_3 = OptionDescription(name="general", doc="general", children=[option_4], properties=frozenset({"normal"}))
optiondescription_28 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_3])
option_18 = FilenameOption(name="name", doc="name", default="/etc/file")
option_17 = BoolOption(name="activate", doc="activate", default=True)
optiondescription_16 = OptionDescription(name="file", doc="file", children=[option_18, option_17])
optiondescription_16.impl_set_information('source', "file")
option_21 = FilenameOption(name="name", doc="name", default="/etc/file2")
option_20 = BoolOption(name="activate", doc="activate", default=True)
optiondescription_19 = OptionDescription(name="file2", doc="file2", children=[option_21, option_20])
optiondescription_19.impl_set_information('engine', "jinja2")
optiondescription_19.impl_set_information('source', "file2")
optiondescription_15 = OptionDescription(name="files", doc="files", children=[optiondescription_16, optiondescription_19])
option_14 = BoolOption(name="activate", doc="activate", default=True)
option_22 = BoolOption(name="manage", doc="manage", default=True)
optiondescription_30 = OptionDescription(name="test_service", doc="test.service", children=[optiondescription_15, option_14, option_22])
optiondescription_30.impl_set_information('type', "service")
optiondescription_29 = OptionDescription(name="services", doc="services", children=[optiondescription_30], properties=frozenset({"hidden"}))
optiondescription_27 = OptionDescription(name="2", doc="2", children=[optiondescription_28, optiondescription_29])
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_23, optiondescription_27])

View file

@ -2,43 +2,38 @@ from importlib.machinery import SourceFileLoader as _SourceFileLoader
from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec
class func: class func:
pass pass
_loader = _SourceFileLoader('func', 'tests/dictionaries/../eosfunc/test.py')
def _load_functions(path): _spec = _spec_from_loader(_loader.name, _loader)
global _SourceFileLoader, _spec_from_loader, _module_from_spec, func _func = _module_from_spec(_spec)
loader = _SourceFileLoader('func', path) _loader.exec_module(_func)
spec = _spec_from_loader(loader.name, loader) for function in dir(_func):
func_ = _module_from_spec(spec) if function.startswith('_'):
loader.exec_module(func_) continue
for function in dir(func_): setattr(func, function, getattr(_func, function))
if function.startswith('_'):
continue
setattr(func, function, getattr(func_, function))
_load_functions('tests/dictionaries/../eosfunc/test.py')
try: try:
from tiramisu3 import * from tiramisu3 import *
except: except:
from tiramisu import * from tiramisu import *
option_2 = StrOption(name="mode_conteneur_actif", doc="Description", default="non", properties=frozenset({"mandatory", "normal"})) option_3 = StrOption(name="mode_conteneur_actif", doc="Description", default="non", properties=frozenset({"mandatory", "normal"}))
optiondescription_1 = OptionDescription(name="general", doc="general", children=[option_2], properties=frozenset({"normal"})) option_2 = OptionDescription(name="general", doc="general", children=[option_3], properties=frozenset({"normal"}))
optiondescription_15 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_1]) option_1 = OptionDescription(name="rougail", doc="rougail", children=[option_2])
option_7 = FilenameOption(name="name", doc="name", default="/etc/file") option_8 = FilenameOption(name="name", doc="name", default="/etc/file")
option_6 = BoolOption(name="activate", doc="activate", default=True)
optiondescription_5 = OptionDescription(name="file", doc="file", children=[option_7, option_6])
optiondescription_5.impl_set_information('source', "file")
option_10 = FilenameOption(name="name", doc="name", default="/etc/file2")
option_9 = BoolOption(name="activate", doc="activate", default=True) option_9 = BoolOption(name="activate", doc="activate", default=True)
optiondescription_8 = OptionDescription(name="file2", doc="file2", children=[option_10, option_9]) option_7 = OptionDescription(name="file", doc="file", children=[option_8, option_9])
optiondescription_8.impl_set_information('engine', "jinja2") option_7.impl_set_information('source', "file")
optiondescription_8.impl_set_information('source', "file2") option_11 = FilenameOption(name="name", doc="name", default="/etc/file2")
option_13 = FilenameOption(name="name", doc="name", default="/etc/dir/incfile")
option_12 = BoolOption(name="activate", doc="activate", default=True) option_12 = BoolOption(name="activate", doc="activate", default=True)
optiondescription_11 = OptionDescription(name="incfile", doc="incfile", children=[option_13, option_12]) option_10 = OptionDescription(name="file2", doc="file2", children=[option_11, option_12])
optiondescription_11.impl_set_information('included', "content") option_10.impl_set_information('engine', "jinja2")
optiondescription_11.impl_set_information('source', "incfile") option_10.impl_set_information('source', "file2")
optiondescription_4 = OptionDescription(name="files", doc="files", children=[optiondescription_5, optiondescription_8, optiondescription_11]) option_14 = FilenameOption(name="name", doc="name", default="/etc/dir/incfile")
option_3 = BoolOption(name="activate", doc="activate", default=True) option_15 = BoolOption(name="activate", doc="activate", default=True)
option_14 = BoolOption(name="manage", doc="manage", default=True) option_13 = OptionDescription(name="incfile", doc="incfile", children=[option_14, option_15])
optiondescription_17 = OptionDescription(name="test_service", doc="test.service", children=[optiondescription_4, option_3, option_14]) option_13.impl_set_information('included', "content")
optiondescription_17.impl_set_information('type', "service") option_13.impl_set_information('source', "incfile")
optiondescription_16 = OptionDescription(name="services", doc="services", children=[optiondescription_17], properties=frozenset({"hidden"})) option_6 = OptionDescription(name="files", doc="files", children=[option_7, option_10, option_13])
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_15, optiondescription_16]) option_16 = BoolOption(name="activate", doc="activate", default=True)
option_17 = BoolOption(name="manage", doc="manage", default=True)
option_5 = OptionDescription(name="test_service", doc="test.service", children=[option_6, option_16, option_17])
option_4 = OptionDescription(name="services", doc="services", children=[option_5], properties=frozenset({"hidden"}))
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[option_1, option_4])

View file

@ -1,69 +0,0 @@
from importlib.machinery import SourceFileLoader as _SourceFileLoader
from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec
class func:
pass
def _load_functions(path):
global _SourceFileLoader, _spec_from_loader, _module_from_spec, func
loader = _SourceFileLoader('func', path)
spec = _spec_from_loader(loader.name, loader)
func_ = _module_from_spec(spec)
loader.exec_module(func_)
for function in dir(func_):
if function.startswith('_'):
continue
setattr(func, function, getattr(func_, function))
_load_functions('tests/dictionaries/../eosfunc/test.py')
try:
from tiramisu3 import *
except:
from tiramisu import *
option_2 = StrOption(name="mode_conteneur_actif", doc="Description", default="non", properties=frozenset({"mandatory", "normal"}))
optiondescription_1 = OptionDescription(name="general", doc="general", children=[option_2], properties=frozenset({"normal"}))
optiondescription_30 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_1])
option_9 = FilenameOption(name="name", doc="name", default="/etc/file")
option_8 = BoolOption(name="activate", doc="activate", default=True)
optiondescription_7 = OptionDescription(name="file", doc="file", children=[option_9, option_8])
optiondescription_7.impl_set_information('source', "file")
option_12 = FilenameOption(name="name", doc="name", default="/etc/file2")
option_11 = BoolOption(name="activate", doc="activate", default=True)
optiondescription_10 = OptionDescription(name="file2", doc="file2", children=[option_12, option_11])
optiondescription_10.impl_set_information('engine', "jinja2")
optiondescription_10.impl_set_information('source', "file2")
option_15 = FilenameOption(name="name", doc="name", default="/etc/dir/incfile")
option_14 = BoolOption(name="activate", doc="activate", default=True)
optiondescription_13 = OptionDescription(name="incfile", doc="incfile", children=[option_15, option_14])
optiondescription_13.impl_set_information('included', "content")
optiondescription_13.impl_set_information('source', "incfile")
optiondescription_6 = OptionDescription(name="files", doc="files", children=[optiondescription_7, optiondescription_10, optiondescription_13])
option_5 = BoolOption(name="activate", doc="activate", default=True)
option_16 = BoolOption(name="manage", doc="manage", default=True)
optiondescription_32 = OptionDescription(name="test_service", doc="test.service", children=[optiondescription_6, option_5, option_16])
optiondescription_32.impl_set_information('type', "service")
optiondescription_31 = OptionDescription(name="services", doc="services", children=[optiondescription_32], properties=frozenset({"hidden"}))
optiondescription_29 = OptionDescription(name="1", doc="1", children=[optiondescription_30, optiondescription_31])
option_4 = StrOption(name="mode_conteneur_actif", doc="Description", default="non", properties=frozenset({"mandatory", "normal"}))
optiondescription_3 = OptionDescription(name="general", doc="general", children=[option_4], properties=frozenset({"normal"}))
optiondescription_34 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_3])
option_21 = FilenameOption(name="name", doc="name", default="/etc/file")
option_20 = BoolOption(name="activate", doc="activate", default=True)
optiondescription_19 = OptionDescription(name="file", doc="file", children=[option_21, option_20])
optiondescription_19.impl_set_information('source', "file")
option_24 = FilenameOption(name="name", doc="name", default="/etc/file2")
option_23 = BoolOption(name="activate", doc="activate", default=True)
optiondescription_22 = OptionDescription(name="file2", doc="file2", children=[option_24, option_23])
optiondescription_22.impl_set_information('engine', "jinja2")
optiondescription_22.impl_set_information('source', "file2")
option_27 = FilenameOption(name="name", doc="name", default="/etc/dir/incfile")
option_26 = BoolOption(name="activate", doc="activate", default=True)
optiondescription_25 = OptionDescription(name="incfile", doc="incfile", children=[option_27, option_26])
optiondescription_25.impl_set_information('included', "content")
optiondescription_25.impl_set_information('source', "incfile")
optiondescription_18 = OptionDescription(name="files", doc="files", children=[optiondescription_19, optiondescription_22, optiondescription_25])
option_17 = BoolOption(name="activate", doc="activate", default=True)
option_28 = BoolOption(name="manage", doc="manage", default=True)
optiondescription_36 = OptionDescription(name="test_service", doc="test.service", children=[optiondescription_18, option_17, option_28])
optiondescription_36.impl_set_information('type', "service")
optiondescription_35 = OptionDescription(name="services", doc="services", children=[optiondescription_36], properties=frozenset({"hidden"}))
optiondescription_33 = OptionDescription(name="2", doc="2", children=[optiondescription_34, optiondescription_35])
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_29, optiondescription_33])

View file

@ -2,43 +2,38 @@ from importlib.machinery import SourceFileLoader as _SourceFileLoader
from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec
class func: class func:
pass pass
_loader = _SourceFileLoader('func', 'tests/dictionaries/../eosfunc/test.py')
def _load_functions(path): _spec = _spec_from_loader(_loader.name, _loader)
global _SourceFileLoader, _spec_from_loader, _module_from_spec, func _func = _module_from_spec(_spec)
loader = _SourceFileLoader('func', path) _loader.exec_module(_func)
spec = _spec_from_loader(loader.name, loader) for function in dir(_func):
func_ = _module_from_spec(spec) if function.startswith('_'):
loader.exec_module(func_) continue
for function in dir(func_): setattr(func, function, getattr(_func, function))
if function.startswith('_'):
continue
setattr(func, function, getattr(func_, function))
_load_functions('tests/dictionaries/../eosfunc/test.py')
try: try:
from tiramisu3 import * from tiramisu3 import *
except: except:
from tiramisu import * from tiramisu import *
option_2 = StrOption(name="mode_conteneur_actif", doc="Description", default="non", properties=frozenset({"mandatory", "normal"})) option_3 = StrOption(name="mode_conteneur_actif", doc="Description", default="non", properties=frozenset({"mandatory", "normal"}))
optiondescription_1 = OptionDescription(name="general", doc="general", children=[option_2], properties=frozenset({"normal"})) option_2 = OptionDescription(name="general", doc="general", children=[option_3], properties=frozenset({"normal"}))
optiondescription_15 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_1]) option_1 = OptionDescription(name="rougail", doc="rougail", children=[option_2])
option_7 = FilenameOption(name="name", doc="name", default="/etc/file") option_8 = FilenameOption(name="name", doc="name", default="/etc/file")
option_6 = BoolOption(name="activate", doc="activate", default=True)
optiondescription_5 = OptionDescription(name="file", doc="file", children=[option_7, option_6])
optiondescription_5.impl_set_information('source', "file")
option_10 = FilenameOption(name="name", doc="name", default="/etc/file2")
option_9 = BoolOption(name="activate", doc="activate", default=True) option_9 = BoolOption(name="activate", doc="activate", default=True)
optiondescription_8 = OptionDescription(name="file2", doc="file2", children=[option_10, option_9]) option_7 = OptionDescription(name="file", doc="file", children=[option_8, option_9])
optiondescription_8.impl_set_information('engine', "jinja2") option_7.impl_set_information('source', "file")
optiondescription_8.impl_set_information('source', "file2") option_11 = FilenameOption(name="name", doc="name", default="/etc/file2")
option_13 = FilenameOption(name="name", doc="name", default="/etc/dir/incfile")
option_12 = BoolOption(name="activate", doc="activate", default=True) option_12 = BoolOption(name="activate", doc="activate", default=True)
optiondescription_11 = OptionDescription(name="incfile", doc="incfile", children=[option_13, option_12]) option_10 = OptionDescription(name="file2", doc="file2", children=[option_11, option_12])
optiondescription_11.impl_set_information('included', "name") option_10.impl_set_information('engine', "jinja2")
optiondescription_11.impl_set_information('source', "incfile") option_10.impl_set_information('source', "file2")
optiondescription_4 = OptionDescription(name="files", doc="files", children=[optiondescription_5, optiondescription_8, optiondescription_11]) option_14 = FilenameOption(name="name", doc="name", default="/etc/dir/incfile")
option_3 = BoolOption(name="activate", doc="activate", default=True) option_15 = BoolOption(name="activate", doc="activate", default=True)
option_14 = BoolOption(name="manage", doc="manage", default=True) option_13 = OptionDescription(name="incfile", doc="incfile", children=[option_14, option_15])
optiondescription_17 = OptionDescription(name="test_service", doc="test.service", children=[optiondescription_4, option_3, option_14]) option_13.impl_set_information('included', "name")
optiondescription_17.impl_set_information('type', "service") option_13.impl_set_information('source', "incfile")
optiondescription_16 = OptionDescription(name="services", doc="services", children=[optiondescription_17], properties=frozenset({"hidden"})) option_6 = OptionDescription(name="files", doc="files", children=[option_7, option_10, option_13])
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_15, optiondescription_16]) option_16 = BoolOption(name="activate", doc="activate", default=True)
option_17 = BoolOption(name="manage", doc="manage", default=True)
option_5 = OptionDescription(name="test_service", doc="test.service", children=[option_6, option_16, option_17])
option_4 = OptionDescription(name="services", doc="services", children=[option_5], properties=frozenset({"hidden"}))
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[option_1, option_4])

View file

@ -1,69 +0,0 @@
from importlib.machinery import SourceFileLoader as _SourceFileLoader
from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec
class func:
pass
def _load_functions(path):
global _SourceFileLoader, _spec_from_loader, _module_from_spec, func
loader = _SourceFileLoader('func', path)
spec = _spec_from_loader(loader.name, loader)
func_ = _module_from_spec(spec)
loader.exec_module(func_)
for function in dir(func_):
if function.startswith('_'):
continue
setattr(func, function, getattr(func_, function))
_load_functions('tests/dictionaries/../eosfunc/test.py')
try:
from tiramisu3 import *
except:
from tiramisu import *
option_2 = StrOption(name="mode_conteneur_actif", doc="Description", default="non", properties=frozenset({"mandatory", "normal"}))
optiondescription_1 = OptionDescription(name="general", doc="general", children=[option_2], properties=frozenset({"normal"}))
optiondescription_30 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_1])
option_9 = FilenameOption(name="name", doc="name", default="/etc/file")
option_8 = BoolOption(name="activate", doc="activate", default=True)
optiondescription_7 = OptionDescription(name="file", doc="file", children=[option_9, option_8])
optiondescription_7.impl_set_information('source', "file")
option_12 = FilenameOption(name="name", doc="name", default="/etc/file2")
option_11 = BoolOption(name="activate", doc="activate", default=True)
optiondescription_10 = OptionDescription(name="file2", doc="file2", children=[option_12, option_11])
optiondescription_10.impl_set_information('engine', "jinja2")
optiondescription_10.impl_set_information('source', "file2")
option_15 = FilenameOption(name="name", doc="name", default="/etc/dir/incfile")
option_14 = BoolOption(name="activate", doc="activate", default=True)
optiondescription_13 = OptionDescription(name="incfile", doc="incfile", children=[option_15, option_14])
optiondescription_13.impl_set_information('included', "name")
optiondescription_13.impl_set_information('source', "incfile")
optiondescription_6 = OptionDescription(name="files", doc="files", children=[optiondescription_7, optiondescription_10, optiondescription_13])
option_5 = BoolOption(name="activate", doc="activate", default=True)
option_16 = BoolOption(name="manage", doc="manage", default=True)
optiondescription_32 = OptionDescription(name="test_service", doc="test.service", children=[optiondescription_6, option_5, option_16])
optiondescription_32.impl_set_information('type', "service")
optiondescription_31 = OptionDescription(name="services", doc="services", children=[optiondescription_32], properties=frozenset({"hidden"}))
optiondescription_29 = OptionDescription(name="1", doc="1", children=[optiondescription_30, optiondescription_31])
option_4 = StrOption(name="mode_conteneur_actif", doc="Description", default="non", properties=frozenset({"mandatory", "normal"}))
optiondescription_3 = OptionDescription(name="general", doc="general", children=[option_4], properties=frozenset({"normal"}))
optiondescription_34 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_3])
option_21 = FilenameOption(name="name", doc="name", default="/etc/file")
option_20 = BoolOption(name="activate", doc="activate", default=True)
optiondescription_19 = OptionDescription(name="file", doc="file", children=[option_21, option_20])
optiondescription_19.impl_set_information('source', "file")
option_24 = FilenameOption(name="name", doc="name", default="/etc/file2")
option_23 = BoolOption(name="activate", doc="activate", default=True)
optiondescription_22 = OptionDescription(name="file2", doc="file2", children=[option_24, option_23])
optiondescription_22.impl_set_information('engine', "jinja2")
optiondescription_22.impl_set_information('source', "file2")
option_27 = FilenameOption(name="name", doc="name", default="/etc/dir/incfile")
option_26 = BoolOption(name="activate", doc="activate", default=True)
optiondescription_25 = OptionDescription(name="incfile", doc="incfile", children=[option_27, option_26])
optiondescription_25.impl_set_information('included', "name")
optiondescription_25.impl_set_information('source', "incfile")
optiondescription_18 = OptionDescription(name="files", doc="files", children=[optiondescription_19, optiondescription_22, optiondescription_25])
option_17 = BoolOption(name="activate", doc="activate", default=True)
option_28 = BoolOption(name="manage", doc="manage", default=True)
optiondescription_36 = OptionDescription(name="test_service", doc="test.service", children=[optiondescription_18, option_17, option_28])
optiondescription_36.impl_set_information('type', "service")
optiondescription_35 = OptionDescription(name="services", doc="services", children=[optiondescription_36], properties=frozenset({"hidden"}))
optiondescription_33 = OptionDescription(name="2", doc="2", children=[optiondescription_34, optiondescription_35])
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_29, optiondescription_33])

View file

@ -2,42 +2,37 @@ from importlib.machinery import SourceFileLoader as _SourceFileLoader
from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec
class func: class func:
pass pass
_loader = _SourceFileLoader('func', 'tests/dictionaries/../eosfunc/test.py')
def _load_functions(path): _spec = _spec_from_loader(_loader.name, _loader)
global _SourceFileLoader, _spec_from_loader, _module_from_spec, func _func = _module_from_spec(_spec)
loader = _SourceFileLoader('func', path) _loader.exec_module(_func)
spec = _spec_from_loader(loader.name, loader) for function in dir(_func):
func_ = _module_from_spec(spec) if function.startswith('_'):
loader.exec_module(func_) continue
for function in dir(func_): setattr(func, function, getattr(_func, function))
if function.startswith('_'):
continue
setattr(func, function, getattr(func_, function))
_load_functions('tests/dictionaries/../eosfunc/test.py')
try: try:
from tiramisu3 import * from tiramisu3 import *
except: except:
from tiramisu import * from tiramisu import *
option_2 = StrOption(name="mode_conteneur_actif", doc="Description", default="non", properties=frozenset({"mandatory", "normal"})) option_3 = StrOption(name="mode_conteneur_actif", doc="Description", default="non", properties=frozenset({"mandatory", "normal"}))
optiondescription_1 = OptionDescription(name="general", doc="general", children=[option_2], properties=frozenset({"normal"})) option_2 = OptionDescription(name="general", doc="general", children=[option_3], properties=frozenset({"normal"}))
optiondescription_16 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_1]) option_1 = OptionDescription(name="rougail", doc="rougail", children=[option_2])
option_7 = UsernameOption(name="group", doc="group", default="nobody") option_8 = UsernameOption(name="group", doc="group", default="nobody")
option_8 = FilenameOption(name="name", doc="name", default="/etc/file") option_9 = FilenameOption(name="name", doc="name", default="/etc/file")
option_9 = UsernameOption(name="owner", doc="owner", default="nobody") option_10 = UsernameOption(name="owner", doc="owner", default="nobody")
option_6 = BoolOption(name="activate", doc="activate", default=True)
optiondescription_5 = OptionDescription(name="file", doc="file", children=[option_7, option_8, option_9, option_6])
optiondescription_5.impl_set_information('source', "file")
option_12 = UsernameOption(name="group", doc="group", default="nobody")
option_13 = FilenameOption(name="name", doc="name", default="/etc/file2")
option_14 = UsernameOption(name="owner", doc="owner", default="nobody")
option_11 = BoolOption(name="activate", doc="activate", default=True) option_11 = BoolOption(name="activate", doc="activate", default=True)
optiondescription_10 = OptionDescription(name="file2", doc="file2", children=[option_12, option_13, option_14, option_11]) option_7 = OptionDescription(name="file", doc="file", children=[option_8, option_9, option_10, option_11])
optiondescription_10.impl_set_information('engine', "jinja2") option_7.impl_set_information('source', "file")
optiondescription_10.impl_set_information('source', "file2") option_13 = UsernameOption(name="group", doc="group", default="nobody")
optiondescription_4 = OptionDescription(name="files", doc="files", children=[optiondescription_5, optiondescription_10]) option_14 = FilenameOption(name="name", doc="name", default="/etc/file2")
option_3 = BoolOption(name="activate", doc="activate", default=True) option_15 = UsernameOption(name="owner", doc="owner", default="nobody")
option_15 = BoolOption(name="manage", doc="manage", default=True) option_16 = BoolOption(name="activate", doc="activate", default=True)
optiondescription_18 = OptionDescription(name="test_service", doc="test.service", children=[optiondescription_4, option_3, option_15]) option_12 = OptionDescription(name="file2", doc="file2", children=[option_13, option_14, option_15, option_16])
optiondescription_18.impl_set_information('type', "service") option_12.impl_set_information('engine', "jinja2")
optiondescription_17 = OptionDescription(name="services", doc="services", children=[optiondescription_18], properties=frozenset({"hidden"})) option_12.impl_set_information('source', "file2")
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_16, optiondescription_17]) option_6 = OptionDescription(name="files", doc="files", children=[option_7, option_12])
option_17 = BoolOption(name="activate", doc="activate", default=True)
option_18 = BoolOption(name="manage", doc="manage", default=True)
option_5 = OptionDescription(name="test_service", doc="test.service", children=[option_6, option_17, option_18])
option_4 = OptionDescription(name="services", doc="services", children=[option_5], properties=frozenset({"hidden"}))
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[option_1, option_4])

View file

@ -1,67 +0,0 @@
from importlib.machinery import SourceFileLoader as _SourceFileLoader
from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec
class func:
pass
def _load_functions(path):
global _SourceFileLoader, _spec_from_loader, _module_from_spec, func
loader = _SourceFileLoader('func', path)
spec = _spec_from_loader(loader.name, loader)
func_ = _module_from_spec(spec)
loader.exec_module(func_)
for function in dir(func_):
if function.startswith('_'):
continue
setattr(func, function, getattr(func_, function))
_load_functions('tests/dictionaries/../eosfunc/test.py')
try:
from tiramisu3 import *
except:
from tiramisu import *
option_2 = StrOption(name="mode_conteneur_actif", doc="Description", default="non", properties=frozenset({"mandatory", "normal"}))
optiondescription_1 = OptionDescription(name="general", doc="general", children=[option_2], properties=frozenset({"normal"}))
optiondescription_32 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_1])
option_9 = UsernameOption(name="group", doc="group", default="nobody")
option_10 = FilenameOption(name="name", doc="name", default="/etc/file")
option_11 = UsernameOption(name="owner", doc="owner", default="nobody")
option_8 = BoolOption(name="activate", doc="activate", default=True)
optiondescription_7 = OptionDescription(name="file", doc="file", children=[option_9, option_10, option_11, option_8])
optiondescription_7.impl_set_information('source', "file")
option_14 = UsernameOption(name="group", doc="group", default="nobody")
option_15 = FilenameOption(name="name", doc="name", default="/etc/file2")
option_16 = UsernameOption(name="owner", doc="owner", default="nobody")
option_13 = BoolOption(name="activate", doc="activate", default=True)
optiondescription_12 = OptionDescription(name="file2", doc="file2", children=[option_14, option_15, option_16, option_13])
optiondescription_12.impl_set_information('engine', "jinja2")
optiondescription_12.impl_set_information('source', "file2")
optiondescription_6 = OptionDescription(name="files", doc="files", children=[optiondescription_7, optiondescription_12])
option_5 = BoolOption(name="activate", doc="activate", default=True)
option_17 = BoolOption(name="manage", doc="manage", default=True)
optiondescription_34 = OptionDescription(name="test_service", doc="test.service", children=[optiondescription_6, option_5, option_17])
optiondescription_34.impl_set_information('type', "service")
optiondescription_33 = OptionDescription(name="services", doc="services", children=[optiondescription_34], properties=frozenset({"hidden"}))
optiondescription_31 = OptionDescription(name="1", doc="1", children=[optiondescription_32, optiondescription_33])
option_4 = StrOption(name="mode_conteneur_actif", doc="Description", default="non", properties=frozenset({"mandatory", "normal"}))
optiondescription_3 = OptionDescription(name="general", doc="general", children=[option_4], properties=frozenset({"normal"}))
optiondescription_36 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_3])
option_22 = UsernameOption(name="group", doc="group", default="nobody")
option_23 = FilenameOption(name="name", doc="name", default="/etc/file")
option_24 = UsernameOption(name="owner", doc="owner", default="nobody")
option_21 = BoolOption(name="activate", doc="activate", default=True)
optiondescription_20 = OptionDescription(name="file", doc="file", children=[option_22, option_23, option_24, option_21])
optiondescription_20.impl_set_information('source', "file")
option_27 = UsernameOption(name="group", doc="group", default="nobody")
option_28 = FilenameOption(name="name", doc="name", default="/etc/file2")
option_29 = UsernameOption(name="owner", doc="owner", default="nobody")
option_26 = BoolOption(name="activate", doc="activate", default=True)
optiondescription_25 = OptionDescription(name="file2", doc="file2", children=[option_27, option_28, option_29, option_26])
optiondescription_25.impl_set_information('engine', "jinja2")
optiondescription_25.impl_set_information('source', "file2")
optiondescription_19 = OptionDescription(name="files", doc="files", children=[optiondescription_20, optiondescription_25])
option_18 = BoolOption(name="activate", doc="activate", default=True)
option_30 = BoolOption(name="manage", doc="manage", default=True)
optiondescription_38 = OptionDescription(name="test_service", doc="test.service", children=[optiondescription_19, option_18, option_30])
optiondescription_38.impl_set_information('type', "service")
optiondescription_37 = OptionDescription(name="services", doc="services", children=[optiondescription_38], properties=frozenset({"hidden"}))
optiondescription_35 = OptionDescription(name="2", doc="2", children=[optiondescription_36, optiondescription_37])
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_31, optiondescription_35])

View file

@ -2,44 +2,39 @@ from importlib.machinery import SourceFileLoader as _SourceFileLoader
from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec
class func: class func:
pass pass
_loader = _SourceFileLoader('func', 'tests/dictionaries/../eosfunc/test.py')
def _load_functions(path): _spec = _spec_from_loader(_loader.name, _loader)
global _SourceFileLoader, _spec_from_loader, _module_from_spec, func _func = _module_from_spec(_spec)
loader = _SourceFileLoader('func', path) _loader.exec_module(_func)
spec = _spec_from_loader(loader.name, loader) for function in dir(_func):
func_ = _module_from_spec(spec) if function.startswith('_'):
loader.exec_module(func_) continue
for function in dir(func_): setattr(func, function, getattr(_func, function))
if function.startswith('_'):
continue
setattr(func, function, getattr(func_, function))
_load_functions('tests/dictionaries/../eosfunc/test.py')
try: try:
from tiramisu3 import * from tiramisu3 import *
except: except:
from tiramisu import * from tiramisu import *
option_2 = StrOption(name="mode_conteneur_actif", doc="Description", default="non", properties=frozenset({"mandatory", "normal"})) option_3 = StrOption(name="mode_conteneur_actif", doc="Description", default="non", properties=frozenset({"mandatory", "normal"}))
option_3 = UsernameOption(name="owner", doc="owner", default="nobody", properties=frozenset({"mandatory", "normal"})) option_4 = UsernameOption(name="owner", doc="owner", default="nobody", properties=frozenset({"mandatory", "normal"}))
option_4 = UsernameOption(name="group", doc="group", default="nobody", properties=frozenset({"mandatory", "normal"})) option_5 = UsernameOption(name="group", doc="group", default="nobody", properties=frozenset({"mandatory", "normal"}))
optiondescription_1 = OptionDescription(name="general", doc="general", children=[option_2, option_3, option_4], properties=frozenset({"normal"})) option_2 = OptionDescription(name="general", doc="general", children=[option_3, option_4, option_5], properties=frozenset({"normal"}))
optiondescription_18 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_1]) option_1 = OptionDescription(name="rougail", doc="rougail", children=[option_2])
option_9 = SymLinkOption(name="group", opt=option_4) option_10 = SymLinkOption(name="group", opt=option_5)
option_10 = FilenameOption(name="name", doc="name", default="/etc/file") option_11 = FilenameOption(name="name", doc="name", default="/etc/file")
option_11 = SymLinkOption(name="owner", opt=option_3) option_12 = SymLinkOption(name="owner", opt=option_4)
option_8 = BoolOption(name="activate", doc="activate", default=True)
optiondescription_7 = OptionDescription(name="file", doc="file", children=[option_9, option_10, option_11, option_8])
optiondescription_7.impl_set_information('source', "file")
option_14 = SymLinkOption(name="group", opt=option_4)
option_15 = FilenameOption(name="name", doc="name", default="/etc/file2")
option_16 = SymLinkOption(name="owner", opt=option_3)
option_13 = BoolOption(name="activate", doc="activate", default=True) option_13 = BoolOption(name="activate", doc="activate", default=True)
optiondescription_12 = OptionDescription(name="file2", doc="file2", children=[option_14, option_15, option_16, option_13]) option_9 = OptionDescription(name="file", doc="file", children=[option_10, option_11, option_12, option_13])
optiondescription_12.impl_set_information('engine', "jinja2") option_9.impl_set_information('source', "file")
optiondescription_12.impl_set_information('source', "file2") option_15 = SymLinkOption(name="group", opt=option_5)
optiondescription_6 = OptionDescription(name="files", doc="files", children=[optiondescription_7, optiondescription_12]) option_16 = FilenameOption(name="name", doc="name", default="/etc/file2")
option_5 = BoolOption(name="activate", doc="activate", default=True) option_17 = SymLinkOption(name="owner", opt=option_4)
option_17 = BoolOption(name="manage", doc="manage", default=True) option_18 = BoolOption(name="activate", doc="activate", default=True)
optiondescription_20 = OptionDescription(name="test_service", doc="test.service", children=[optiondescription_6, option_5, option_17]) option_14 = OptionDescription(name="file2", doc="file2", children=[option_15, option_16, option_17, option_18])
optiondescription_20.impl_set_information('type', "service") option_14.impl_set_information('engine', "jinja2")
optiondescription_19 = OptionDescription(name="services", doc="services", children=[optiondescription_20], properties=frozenset({"hidden"})) option_14.impl_set_information('source', "file2")
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_18, optiondescription_19]) option_8 = OptionDescription(name="files", doc="files", children=[option_9, option_14])
option_19 = BoolOption(name="activate", doc="activate", default=True)
option_20 = BoolOption(name="manage", doc="manage", default=True)
option_7 = OptionDescription(name="test_service", doc="test.service", children=[option_8, option_19, option_20])
option_6 = OptionDescription(name="services", doc="services", children=[option_7], properties=frozenset({"hidden"}))
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[option_1, option_6])

View file

@ -1,71 +0,0 @@
from importlib.machinery import SourceFileLoader as _SourceFileLoader
from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec
class func:
pass
def _load_functions(path):
global _SourceFileLoader, _spec_from_loader, _module_from_spec, func
loader = _SourceFileLoader('func', path)
spec = _spec_from_loader(loader.name, loader)
func_ = _module_from_spec(spec)
loader.exec_module(func_)
for function in dir(func_):
if function.startswith('_'):
continue
setattr(func, function, getattr(func_, function))
_load_functions('tests/dictionaries/../eosfunc/test.py')
try:
from tiramisu3 import *
except:
from tiramisu import *
option_2 = StrOption(name="mode_conteneur_actif", doc="Description", default="non", properties=frozenset({"mandatory", "normal"}))
option_3 = UsernameOption(name="owner", doc="owner", default="nobody", properties=frozenset({"mandatory", "normal"}))
option_4 = UsernameOption(name="group", doc="group", default="nobody", properties=frozenset({"mandatory", "normal"}))
optiondescription_1 = OptionDescription(name="general", doc="general", children=[option_2, option_3, option_4], properties=frozenset({"normal"}))
optiondescription_36 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_1])
option_13 = SymLinkOption(name="group", opt=option_4)
option_14 = FilenameOption(name="name", doc="name", default="/etc/file")
option_15 = SymLinkOption(name="owner", opt=option_3)
option_12 = BoolOption(name="activate", doc="activate", default=True)
optiondescription_11 = OptionDescription(name="file", doc="file", children=[option_13, option_14, option_15, option_12])
optiondescription_11.impl_set_information('source', "file")
option_18 = SymLinkOption(name="group", opt=option_4)
option_19 = FilenameOption(name="name", doc="name", default="/etc/file2")
option_20 = SymLinkOption(name="owner", opt=option_3)
option_17 = BoolOption(name="activate", doc="activate", default=True)
optiondescription_16 = OptionDescription(name="file2", doc="file2", children=[option_18, option_19, option_20, option_17])
optiondescription_16.impl_set_information('engine', "jinja2")
optiondescription_16.impl_set_information('source', "file2")
optiondescription_10 = OptionDescription(name="files", doc="files", children=[optiondescription_11, optiondescription_16])
option_9 = BoolOption(name="activate", doc="activate", default=True)
option_21 = BoolOption(name="manage", doc="manage", default=True)
optiondescription_38 = OptionDescription(name="test_service", doc="test.service", children=[optiondescription_10, option_9, option_21])
optiondescription_38.impl_set_information('type', "service")
optiondescription_37 = OptionDescription(name="services", doc="services", children=[optiondescription_38], properties=frozenset({"hidden"}))
optiondescription_35 = OptionDescription(name="1", doc="1", children=[optiondescription_36, optiondescription_37])
option_6 = StrOption(name="mode_conteneur_actif", doc="Description", default="non", properties=frozenset({"mandatory", "normal"}))
option_7 = UsernameOption(name="owner", doc="owner", default="nobody", properties=frozenset({"mandatory", "normal"}))
option_8 = UsernameOption(name="group", doc="group", default="nobody", properties=frozenset({"mandatory", "normal"}))
optiondescription_5 = OptionDescription(name="general", doc="general", children=[option_6, option_7, option_8], properties=frozenset({"normal"}))
optiondescription_40 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_5])
option_26 = SymLinkOption(name="group", opt=option_8)
option_27 = FilenameOption(name="name", doc="name", default="/etc/file")
option_28 = SymLinkOption(name="owner", opt=option_7)
option_25 = BoolOption(name="activate", doc="activate", default=True)
optiondescription_24 = OptionDescription(name="file", doc="file", children=[option_26, option_27, option_28, option_25])
optiondescription_24.impl_set_information('source', "file")
option_31 = SymLinkOption(name="group", opt=option_8)
option_32 = FilenameOption(name="name", doc="name", default="/etc/file2")
option_33 = SymLinkOption(name="owner", opt=option_7)
option_30 = BoolOption(name="activate", doc="activate", default=True)
optiondescription_29 = OptionDescription(name="file2", doc="file2", children=[option_31, option_32, option_33, option_30])
optiondescription_29.impl_set_information('engine', "jinja2")
optiondescription_29.impl_set_information('source', "file2")
optiondescription_23 = OptionDescription(name="files", doc="files", children=[optiondescription_24, optiondescription_29])
option_22 = BoolOption(name="activate", doc="activate", default=True)
option_34 = BoolOption(name="manage", doc="manage", default=True)
optiondescription_42 = OptionDescription(name="test_service", doc="test.service", children=[optiondescription_23, option_22, option_34])
optiondescription_42.impl_set_information('type', "service")
optiondescription_41 = OptionDescription(name="services", doc="services", children=[optiondescription_42], properties=frozenset({"hidden"}))
optiondescription_39 = OptionDescription(name="2", doc="2", children=[optiondescription_40, optiondescription_41])
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_35, optiondescription_39])

View file

@ -2,38 +2,33 @@ from importlib.machinery import SourceFileLoader as _SourceFileLoader
from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec
class func: class func:
pass pass
_loader = _SourceFileLoader('func', 'tests/dictionaries/../eosfunc/test.py')
def _load_functions(path): _spec = _spec_from_loader(_loader.name, _loader)
global _SourceFileLoader, _spec_from_loader, _module_from_spec, func _func = _module_from_spec(_spec)
loader = _SourceFileLoader('func', path) _loader.exec_module(_func)
spec = _spec_from_loader(loader.name, loader) for function in dir(_func):
func_ = _module_from_spec(spec) if function.startswith('_'):
loader.exec_module(func_) continue
for function in dir(func_): setattr(func, function, getattr(_func, function))
if function.startswith('_'):
continue
setattr(func, function, getattr(func_, function))
_load_functions('tests/dictionaries/../eosfunc/test.py')
try: try:
from tiramisu3 import * from tiramisu3 import *
except: except:
from tiramisu import * from tiramisu import *
option_2 = StrOption(name="mode_conteneur_actif", doc="Description", default="non", properties=frozenset({"mandatory", "normal"})) option_3 = StrOption(name="mode_conteneur_actif", doc="Description", default="non", properties=frozenset({"mandatory", "normal"}))
optiondescription_1 = OptionDescription(name="general", doc="general", children=[option_2], properties=frozenset({"normal"})) option_2 = OptionDescription(name="general", doc="general", children=[option_3], properties=frozenset({"normal"}))
optiondescription_12 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_1]) option_1 = OptionDescription(name="rougail", doc="rougail", children=[option_2])
option_7 = FilenameOption(name="name", doc="name", default="/etc/file") option_8 = FilenameOption(name="name", doc="name", default="/etc/file")
option_6 = BoolOption(name="activate", doc="activate", default=True)
optiondescription_5 = OptionDescription(name="file", doc="file", children=[option_7, option_6])
optiondescription_5.impl_set_information('source', "file")
option_10 = FilenameOption(name="name", doc="name", default="/etc/file2")
option_9 = BoolOption(name="activate", doc="activate", default=True) option_9 = BoolOption(name="activate", doc="activate", default=True)
optiondescription_8 = OptionDescription(name="file2", doc="file2", children=[option_10, option_9]) option_7 = OptionDescription(name="file", doc="file", children=[option_8, option_9])
optiondescription_8.impl_set_information('engine', "jinja2") option_7.impl_set_information('source', "file")
optiondescription_8.impl_set_information('source', "file2") option_11 = FilenameOption(name="name", doc="name", default="/etc/file2")
optiondescription_4 = OptionDescription(name="files", doc="files", children=[optiondescription_5, optiondescription_8]) option_12 = BoolOption(name="activate", doc="activate", default=True)
option_3 = BoolOption(name="activate", doc="activate", default=True) option_10 = OptionDescription(name="file2", doc="file2", children=[option_11, option_12])
option_11 = BoolOption(name="manage", doc="manage", default=True) option_10.impl_set_information('engine', "jinja2")
optiondescription_14 = OptionDescription(name="test_service", doc="test.service", children=[optiondescription_4, option_3, option_11]) option_10.impl_set_information('source', "file2")
optiondescription_14.impl_set_information('type', "service") option_6 = OptionDescription(name="files", doc="files", children=[option_7, option_10])
optiondescription_13 = OptionDescription(name="services", doc="services", children=[optiondescription_14], properties=frozenset({"hidden"})) option_13 = BoolOption(name="activate", doc="activate", default=True)
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_12, optiondescription_13]) option_14 = BoolOption(name="manage", doc="manage", default=True)
option_5 = OptionDescription(name="test_service", doc="test.service", children=[option_6, option_13, option_14])
option_4 = OptionDescription(name="services", doc="services", children=[option_5], properties=frozenset({"hidden"}))
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[option_1, option_4])

View file

@ -1,59 +0,0 @@
from importlib.machinery import SourceFileLoader as _SourceFileLoader
from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec
class func:
pass
def _load_functions(path):
global _SourceFileLoader, _spec_from_loader, _module_from_spec, func
loader = _SourceFileLoader('func', path)
spec = _spec_from_loader(loader.name, loader)
func_ = _module_from_spec(spec)
loader.exec_module(func_)
for function in dir(func_):
if function.startswith('_'):
continue
setattr(func, function, getattr(func_, function))
_load_functions('tests/dictionaries/../eosfunc/test.py')
try:
from tiramisu3 import *
except:
from tiramisu import *
option_2 = StrOption(name="mode_conteneur_actif", doc="Description", default="non", properties=frozenset({"mandatory", "normal"}))
optiondescription_1 = OptionDescription(name="general", doc="general", children=[option_2], properties=frozenset({"normal"}))
optiondescription_24 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_1])
option_9 = FilenameOption(name="name", doc="name", default="/etc/file")
option_8 = BoolOption(name="activate", doc="activate", default=True)
optiondescription_7 = OptionDescription(name="file", doc="file", children=[option_9, option_8])
optiondescription_7.impl_set_information('source', "file")
option_12 = FilenameOption(name="name", doc="name", default="/etc/file2")
option_11 = BoolOption(name="activate", doc="activate", default=True)
optiondescription_10 = OptionDescription(name="file2", doc="file2", children=[option_12, option_11])
optiondescription_10.impl_set_information('engine', "jinja2")
optiondescription_10.impl_set_information('source', "file2")
optiondescription_6 = OptionDescription(name="files", doc="files", children=[optiondescription_7, optiondescription_10])
option_5 = BoolOption(name="activate", doc="activate", default=True)
option_13 = BoolOption(name="manage", doc="manage", default=True)
optiondescription_26 = OptionDescription(name="test_service", doc="test.service", children=[optiondescription_6, option_5, option_13])
optiondescription_26.impl_set_information('type', "service")
optiondescription_25 = OptionDescription(name="services", doc="services", children=[optiondescription_26], properties=frozenset({"hidden"}))
optiondescription_23 = OptionDescription(name="1", doc="1", children=[optiondescription_24, optiondescription_25])
option_4 = StrOption(name="mode_conteneur_actif", doc="Description", default="non", properties=frozenset({"mandatory", "normal"}))
optiondescription_3 = OptionDescription(name="general", doc="general", children=[option_4], properties=frozenset({"normal"}))
optiondescription_28 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_3])
option_18 = FilenameOption(name="name", doc="name", default="/etc/file")
option_17 = BoolOption(name="activate", doc="activate", default=True)
optiondescription_16 = OptionDescription(name="file", doc="file", children=[option_18, option_17])
optiondescription_16.impl_set_information('source', "file")
option_21 = FilenameOption(name="name", doc="name", default="/etc/file2")
option_20 = BoolOption(name="activate", doc="activate", default=True)
optiondescription_19 = OptionDescription(name="file2", doc="file2", children=[option_21, option_20])
optiondescription_19.impl_set_information('engine', "jinja2")
optiondescription_19.impl_set_information('source', "file2")
optiondescription_15 = OptionDescription(name="files", doc="files", children=[optiondescription_16, optiondescription_19])
option_14 = BoolOption(name="activate", doc="activate", default=True)
option_22 = BoolOption(name="manage", doc="manage", default=True)
optiondescription_30 = OptionDescription(name="test_service", doc="test.service", children=[optiondescription_15, option_14, option_22])
optiondescription_30.impl_set_information('type', "service")
optiondescription_29 = OptionDescription(name="services", doc="services", children=[optiondescription_30], properties=frozenset({"hidden"}))
optiondescription_27 = OptionDescription(name="2", doc="2", children=[optiondescription_28, optiondescription_29])
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_23, optiondescription_27])

View file

@ -2,38 +2,33 @@ from importlib.machinery import SourceFileLoader as _SourceFileLoader
from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec
class func: class func:
pass pass
_loader = _SourceFileLoader('func', 'tests/dictionaries/../eosfunc/test.py')
def _load_functions(path): _spec = _spec_from_loader(_loader.name, _loader)
global _SourceFileLoader, _spec_from_loader, _module_from_spec, func _func = _module_from_spec(_spec)
loader = _SourceFileLoader('func', path) _loader.exec_module(_func)
spec = _spec_from_loader(loader.name, loader) for function in dir(_func):
func_ = _module_from_spec(spec) if function.startswith('_'):
loader.exec_module(func_) continue
for function in dir(func_): setattr(func, function, getattr(_func, function))
if function.startswith('_'):
continue
setattr(func, function, getattr(func_, function))
_load_functions('tests/dictionaries/../eosfunc/test.py')
try: try:
from tiramisu3 import * from tiramisu3 import *
except: except:
from tiramisu import * from tiramisu import *
option_2 = StrOption(name="mode_conteneur_actif", doc="Description", default="non", properties=frozenset({"mandatory", "normal"})) option_3 = StrOption(name="mode_conteneur_actif", doc="Description", default="non", properties=frozenset({"mandatory", "normal"}))
optiondescription_1 = OptionDescription(name="general", doc="general", children=[option_2], properties=frozenset({"normal"})) option_2 = OptionDescription(name="general", doc="general", children=[option_3], properties=frozenset({"normal"}))
optiondescription_12 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_1]) option_1 = OptionDescription(name="rougail", doc="rougail", children=[option_2])
option_7 = FilenameOption(name="name", doc="name", default="/etc/file") option_8 = FilenameOption(name="name", doc="name", default="/etc/file")
option_6 = BoolOption(name="activate", doc="activate", default=True)
optiondescription_5 = OptionDescription(name="file", doc="file", children=[option_7, option_6])
optiondescription_5.impl_set_information('source', "file")
option_10 = FilenameOption(name="name", doc="name", default="/etc/file2")
option_9 = BoolOption(name="activate", doc="activate", default=True) option_9 = BoolOption(name="activate", doc="activate", default=True)
optiondescription_8 = OptionDescription(name="file2", doc="file2", children=[option_10, option_9]) option_7 = OptionDescription(name="file", doc="file", children=[option_8, option_9])
optiondescription_8.impl_set_information('engine', "jinja2") option_7.impl_set_information('source', "file")
optiondescription_8.impl_set_information('source', "file2") option_11 = FilenameOption(name="name", doc="name", default="/etc/file2")
optiondescription_4 = OptionDescription(name="files", doc="files", children=[optiondescription_5, optiondescription_8]) option_12 = BoolOption(name="activate", doc="activate", default=True)
option_3 = BoolOption(name="activate", doc="activate", default=True) option_10 = OptionDescription(name="file2", doc="file2", children=[option_11, option_12])
option_11 = BoolOption(name="manage", doc="manage", default=True) option_10.impl_set_information('engine', "jinja2")
optiondescription_14 = OptionDescription(name="test_service", doc="test.service", children=[optiondescription_4, option_3, option_11]) option_10.impl_set_information('source', "file2")
optiondescription_14.impl_set_information('type', "service") option_6 = OptionDescription(name="files", doc="files", children=[option_7, option_10])
optiondescription_13 = OptionDescription(name="services", doc="services", children=[optiondescription_14], properties=frozenset({"hidden"})) option_13 = BoolOption(name="activate", doc="activate", default=True)
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_12, optiondescription_13]) option_14 = BoolOption(name="manage", doc="manage", default=True)
option_5 = OptionDescription(name="test_service", doc="test.service", children=[option_6, option_13, option_14])
option_4 = OptionDescription(name="services", doc="services", children=[option_5], properties=frozenset({"hidden"}))
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[option_1, option_4])

View file

@ -1,59 +0,0 @@
from importlib.machinery import SourceFileLoader as _SourceFileLoader
from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec
class func:
pass
def _load_functions(path):
global _SourceFileLoader, _spec_from_loader, _module_from_spec, func
loader = _SourceFileLoader('func', path)
spec = _spec_from_loader(loader.name, loader)
func_ = _module_from_spec(spec)
loader.exec_module(func_)
for function in dir(func_):
if function.startswith('_'):
continue
setattr(func, function, getattr(func_, function))
_load_functions('tests/dictionaries/../eosfunc/test.py')
try:
from tiramisu3 import *
except:
from tiramisu import *
option_2 = StrOption(name="mode_conteneur_actif", doc="Description", default="non", properties=frozenset({"mandatory", "normal"}))
optiondescription_1 = OptionDescription(name="general", doc="general", children=[option_2], properties=frozenset({"normal"}))
optiondescription_24 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_1])
option_9 = FilenameOption(name="name", doc="name", default="/etc/file")
option_8 = BoolOption(name="activate", doc="activate", default=True)
optiondescription_7 = OptionDescription(name="file", doc="file", children=[option_9, option_8])
optiondescription_7.impl_set_information('source', "file")
option_12 = FilenameOption(name="name", doc="name", default="/etc/file2")
option_11 = BoolOption(name="activate", doc="activate", default=True)
optiondescription_10 = OptionDescription(name="file2", doc="file2", children=[option_12, option_11])
optiondescription_10.impl_set_information('engine', "jinja2")
optiondescription_10.impl_set_information('source', "file2")
optiondescription_6 = OptionDescription(name="files", doc="files", children=[optiondescription_7, optiondescription_10])
option_5 = BoolOption(name="activate", doc="activate", default=True)
option_13 = BoolOption(name="manage", doc="manage", default=True)
optiondescription_26 = OptionDescription(name="test_service", doc="test.service", children=[optiondescription_6, option_5, option_13])
optiondescription_26.impl_set_information('type', "service")
optiondescription_25 = OptionDescription(name="services", doc="services", children=[optiondescription_26], properties=frozenset({"hidden"}))
optiondescription_23 = OptionDescription(name="1", doc="1", children=[optiondescription_24, optiondescription_25])
option_4 = StrOption(name="mode_conteneur_actif", doc="Description", default="non", properties=frozenset({"mandatory", "normal"}))
optiondescription_3 = OptionDescription(name="general", doc="general", children=[option_4], properties=frozenset({"normal"}))
optiondescription_28 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_3])
option_18 = FilenameOption(name="name", doc="name", default="/etc/file")
option_17 = BoolOption(name="activate", doc="activate", default=True)
optiondescription_16 = OptionDescription(name="file", doc="file", children=[option_18, option_17])
optiondescription_16.impl_set_information('source', "file")
option_21 = FilenameOption(name="name", doc="name", default="/etc/file2")
option_20 = BoolOption(name="activate", doc="activate", default=True)
optiondescription_19 = OptionDescription(name="file2", doc="file2", children=[option_21, option_20])
optiondescription_19.impl_set_information('engine', "jinja2")
optiondescription_19.impl_set_information('source', "file2")
optiondescription_15 = OptionDescription(name="files", doc="files", children=[optiondescription_16, optiondescription_19])
option_14 = BoolOption(name="activate", doc="activate", default=True)
option_22 = BoolOption(name="manage", doc="manage", default=True)
optiondescription_30 = OptionDescription(name="test_service", doc="test.service", children=[optiondescription_15, option_14, option_22])
optiondescription_30.impl_set_information('type', "service")
optiondescription_29 = OptionDescription(name="services", doc="services", children=[optiondescription_30], properties=frozenset({"hidden"}))
optiondescription_27 = OptionDescription(name="2", doc="2", children=[optiondescription_28, optiondescription_29])
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_23, optiondescription_27])

View file

@ -2,38 +2,33 @@ from importlib.machinery import SourceFileLoader as _SourceFileLoader
from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec
class func: class func:
pass pass
_loader = _SourceFileLoader('func', 'tests/dictionaries/../eosfunc/test.py')
def _load_functions(path): _spec = _spec_from_loader(_loader.name, _loader)
global _SourceFileLoader, _spec_from_loader, _module_from_spec, func _func = _module_from_spec(_spec)
loader = _SourceFileLoader('func', path) _loader.exec_module(_func)
spec = _spec_from_loader(loader.name, loader) for function in dir(_func):
func_ = _module_from_spec(spec) if function.startswith('_'):
loader.exec_module(func_) continue
for function in dir(func_): setattr(func, function, getattr(_func, function))
if function.startswith('_'):
continue
setattr(func, function, getattr(func_, function))
_load_functions('tests/dictionaries/../eosfunc/test.py')
try: try:
from tiramisu3 import * from tiramisu3 import *
except: except:
from tiramisu import * from tiramisu import *
option_2 = StrOption(name="mode_conteneur_actif", doc="Description", default="non", properties=frozenset({"mandatory", "normal"})) option_3 = StrOption(name="mode_conteneur_actif", doc="Description", default="non", properties=frozenset({"mandatory", "normal"}))
optiondescription_1 = OptionDescription(name="general", doc="general", children=[option_2], properties=frozenset({"normal"})) option_2 = OptionDescription(name="general", doc="general", children=[option_3], properties=frozenset({"normal"}))
optiondescription_12 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_1]) option_1 = OptionDescription(name="rougail", doc="rougail", children=[option_2])
option_7 = FilenameOption(name="name", doc="name", default="/etc/systemd-makefs@dev-disk-by\\x2dpartlabel") option_8 = FilenameOption(name="name", doc="name", default="/etc/systemd-makefs@dev-disk-by\\x2dpartlabel")
option_6 = BoolOption(name="activate", doc="activate", default=True)
optiondescription_5 = OptionDescription(name="systemd_makefs@dev_disk_by\\x2dpartlabel", doc="systemd-makefs@dev-disk-by\\x2dpartlabel", children=[option_7, option_6])
optiondescription_5.impl_set_information('source', "systemd-makefs@dev-disk-by\\x2dpartlabel")
option_10 = FilenameOption(name="name", doc="name", default="/etc/systemd-makefs@dev-disk-by\\x2dpartlabel2")
option_9 = BoolOption(name="activate", doc="activate", default=True) option_9 = BoolOption(name="activate", doc="activate", default=True)
optiondescription_8 = OptionDescription(name="systemd_makefs@dev_disk_by\\x2dpartlabel2", doc="systemd-makefs@dev-disk-by\\x2dpartlabel2", children=[option_10, option_9]) option_7 = OptionDescription(name="systemd_makefs@dev_disk_by\\x2dpartlabel", doc="systemd-makefs@dev-disk-by\\x2dpartlabel", children=[option_8, option_9])
optiondescription_8.impl_set_information('engine', "jinja2") option_7.impl_set_information('source', "systemd-makefs@dev-disk-by\\x2dpartlabel")
optiondescription_8.impl_set_information('source', "systemd-makefs@dev-disk-by\\x2dpartlabel2") option_11 = FilenameOption(name="name", doc="name", default="/etc/systemd-makefs@dev-disk-by\\x2dpartlabel2")
optiondescription_4 = OptionDescription(name="files", doc="files", children=[optiondescription_5, optiondescription_8]) option_12 = BoolOption(name="activate", doc="activate", default=True)
option_3 = BoolOption(name="activate", doc="activate", default=True) option_10 = OptionDescription(name="systemd_makefs@dev_disk_by\\x2dpartlabel2", doc="systemd-makefs@dev-disk-by\\x2dpartlabel2", children=[option_11, option_12])
option_11 = BoolOption(name="manage", doc="manage", default=True) option_10.impl_set_information('engine', "jinja2")
optiondescription_14 = OptionDescription(name="test_service", doc="test.service", children=[optiondescription_4, option_3, option_11]) option_10.impl_set_information('source', "systemd-makefs@dev-disk-by\\x2dpartlabel2")
optiondescription_14.impl_set_information('type', "service") option_6 = OptionDescription(name="files", doc="files", children=[option_7, option_10])
optiondescription_13 = OptionDescription(name="services", doc="services", children=[optiondescription_14], properties=frozenset({"hidden"})) option_13 = BoolOption(name="activate", doc="activate", default=True)
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_12, optiondescription_13]) option_14 = BoolOption(name="manage", doc="manage", default=True)
option_5 = OptionDescription(name="test_service", doc="test.service", children=[option_6, option_13, option_14])
option_4 = OptionDescription(name="services", doc="services", children=[option_5], properties=frozenset({"hidden"}))
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[option_1, option_4])

View file

@ -1,59 +0,0 @@
from importlib.machinery import SourceFileLoader as _SourceFileLoader
from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec
class func:
pass
def _load_functions(path):
global _SourceFileLoader, _spec_from_loader, _module_from_spec, func
loader = _SourceFileLoader('func', path)
spec = _spec_from_loader(loader.name, loader)
func_ = _module_from_spec(spec)
loader.exec_module(func_)
for function in dir(func_):
if function.startswith('_'):
continue
setattr(func, function, getattr(func_, function))
_load_functions('tests/dictionaries/../eosfunc/test.py')
try:
from tiramisu3 import *
except:
from tiramisu import *
option_2 = StrOption(name="mode_conteneur_actif", doc="Description", default="non", properties=frozenset({"mandatory", "normal"}))
optiondescription_1 = OptionDescription(name="general", doc="general", children=[option_2], properties=frozenset({"normal"}))
optiondescription_24 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_1])
option_9 = FilenameOption(name="name", doc="name", default="/etc/systemd-makefs@dev-disk-by\\x2dpartlabel")
option_8 = BoolOption(name="activate", doc="activate", default=True)
optiondescription_7 = OptionDescription(name="systemd_makefs@dev_disk_by\\x2dpartlabel", doc="systemd-makefs@dev-disk-by\\x2dpartlabel", children=[option_9, option_8])
optiondescription_7.impl_set_information('source', "systemd-makefs@dev-disk-by\\x2dpartlabel")
option_12 = FilenameOption(name="name", doc="name", default="/etc/systemd-makefs@dev-disk-by\\x2dpartlabel2")
option_11 = BoolOption(name="activate", doc="activate", default=True)
optiondescription_10 = OptionDescription(name="systemd_makefs@dev_disk_by\\x2dpartlabel2", doc="systemd-makefs@dev-disk-by\\x2dpartlabel2", children=[option_12, option_11])
optiondescription_10.impl_set_information('engine', "jinja2")
optiondescription_10.impl_set_information('source', "systemd-makefs@dev-disk-by\\x2dpartlabel2")
optiondescription_6 = OptionDescription(name="files", doc="files", children=[optiondescription_7, optiondescription_10])
option_5 = BoolOption(name="activate", doc="activate", default=True)
option_13 = BoolOption(name="manage", doc="manage", default=True)
optiondescription_26 = OptionDescription(name="test_service", doc="test.service", children=[optiondescription_6, option_5, option_13])
optiondescription_26.impl_set_information('type', "service")
optiondescription_25 = OptionDescription(name="services", doc="services", children=[optiondescription_26], properties=frozenset({"hidden"}))
optiondescription_23 = OptionDescription(name="1", doc="1", children=[optiondescription_24, optiondescription_25])
option_4 = StrOption(name="mode_conteneur_actif", doc="Description", default="non", properties=frozenset({"mandatory", "normal"}))
optiondescription_3 = OptionDescription(name="general", doc="general", children=[option_4], properties=frozenset({"normal"}))
optiondescription_28 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_3])
option_18 = FilenameOption(name="name", doc="name", default="/etc/systemd-makefs@dev-disk-by\\x2dpartlabel")
option_17 = BoolOption(name="activate", doc="activate", default=True)
optiondescription_16 = OptionDescription(name="systemd_makefs@dev_disk_by\\x2dpartlabel", doc="systemd-makefs@dev-disk-by\\x2dpartlabel", children=[option_18, option_17])
optiondescription_16.impl_set_information('source', "systemd-makefs@dev-disk-by\\x2dpartlabel")
option_21 = FilenameOption(name="name", doc="name", default="/etc/systemd-makefs@dev-disk-by\\x2dpartlabel2")
option_20 = BoolOption(name="activate", doc="activate", default=True)
optiondescription_19 = OptionDescription(name="systemd_makefs@dev_disk_by\\x2dpartlabel2", doc="systemd-makefs@dev-disk-by\\x2dpartlabel2", children=[option_21, option_20])
optiondescription_19.impl_set_information('engine', "jinja2")
optiondescription_19.impl_set_information('source', "systemd-makefs@dev-disk-by\\x2dpartlabel2")
optiondescription_15 = OptionDescription(name="files", doc="files", children=[optiondescription_16, optiondescription_19])
option_14 = BoolOption(name="activate", doc="activate", default=True)
option_22 = BoolOption(name="manage", doc="manage", default=True)
optiondescription_30 = OptionDescription(name="test_service", doc="test.service", children=[optiondescription_15, option_14, option_22])
optiondescription_30.impl_set_information('type', "service")
optiondescription_29 = OptionDescription(name="services", doc="services", children=[optiondescription_30], properties=frozenset({"hidden"}))
optiondescription_27 = OptionDescription(name="2", doc="2", children=[optiondescription_28, optiondescription_29])
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_23, optiondescription_27])

View file

@ -2,24 +2,20 @@ from importlib.machinery import SourceFileLoader as _SourceFileLoader
from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec
class func: class func:
pass pass
_loader = _SourceFileLoader('func', 'tests/dictionaries/../eosfunc/test.py')
def _load_functions(path): _spec = _spec_from_loader(_loader.name, _loader)
global _SourceFileLoader, _spec_from_loader, _module_from_spec, func _func = _module_from_spec(_spec)
loader = _SourceFileLoader('func', path) _loader.exec_module(_func)
spec = _spec_from_loader(loader.name, loader) for function in dir(_func):
func_ = _module_from_spec(spec) if function.startswith('_'):
loader.exec_module(func_) continue
for function in dir(func_): setattr(func, function, getattr(_func, function))
if function.startswith('_'):
continue
setattr(func, function, getattr(func_, function))
_load_functions('tests/dictionaries/../eosfunc/test.py')
try: try:
from tiramisu3 import * from tiramisu3 import *
except: except:
from tiramisu import * from tiramisu import *
option_2 = FloatOption(name="float", doc="Description", default=0.527, properties=frozenset({"mandatory", "normal"})) option_3 = FloatOption(name="float", doc="Description", default=0.527, properties=frozenset({"mandatory", "normal"}))
option_3 = FloatOption(name="float_multi", doc="Description", multi=True, default=[0.527], default_multi=0.527, properties=frozenset({"mandatory", "normal"})) option_4 = FloatOption(name="float_multi", doc="Description", multi=True, default=[0.527], default_multi=0.527, properties=frozenset({"mandatory", "normal"}))
optiondescription_1 = OptionDescription(name="general", doc="general", children=[option_2, option_3], properties=frozenset({"normal"})) option_2 = OptionDescription(name="general", doc="general", children=[option_3, option_4], properties=frozenset({"normal"}))
optiondescription_4 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_1]) option_1 = OptionDescription(name="rougail", doc="rougail", children=[option_2])
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_4]) option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[option_1])

View file

@ -1,31 +0,0 @@
from importlib.machinery import SourceFileLoader as _SourceFileLoader
from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec
class func:
pass
def _load_functions(path):
global _SourceFileLoader, _spec_from_loader, _module_from_spec, func
loader = _SourceFileLoader('func', path)
spec = _spec_from_loader(loader.name, loader)
func_ = _module_from_spec(spec)
loader.exec_module(func_)
for function in dir(func_):
if function.startswith('_'):
continue
setattr(func, function, getattr(func_, function))
_load_functions('tests/dictionaries/../eosfunc/test.py')
try:
from tiramisu3 import *
except:
from tiramisu import *
option_2 = FloatOption(name="float", doc="Description", default=0.527, properties=frozenset({"mandatory", "normal"}))
option_3 = FloatOption(name="float_multi", doc="Description", multi=True, default=[0.527], default_multi=0.527, properties=frozenset({"mandatory", "normal"}))
optiondescription_1 = OptionDescription(name="general", doc="general", children=[option_2, option_3], properties=frozenset({"normal"}))
optiondescription_8 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_1])
optiondescription_7 = OptionDescription(name="1", doc="1", children=[optiondescription_8])
option_5 = FloatOption(name="float", doc="Description", default=0.527, properties=frozenset({"mandatory", "normal"}))
option_6 = FloatOption(name="float_multi", doc="Description", multi=True, default=[0.527], default_multi=0.527, properties=frozenset({"mandatory", "normal"}))
optiondescription_4 = OptionDescription(name="general", doc="general", children=[option_5, option_6], properties=frozenset({"normal"}))
optiondescription_10 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_4])
optiondescription_9 = OptionDescription(name="2", doc="2", children=[optiondescription_10])
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_7, optiondescription_9])

View file

@ -2,26 +2,22 @@ from importlib.machinery import SourceFileLoader as _SourceFileLoader
from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec
class func: class func:
pass pass
_loader = _SourceFileLoader('func', 'tests/dictionaries/../eosfunc/test.py')
def _load_functions(path): _spec = _spec_from_loader(_loader.name, _loader)
global _SourceFileLoader, _spec_from_loader, _module_from_spec, func _func = _module_from_spec(_spec)
loader = _SourceFileLoader('func', path) _loader.exec_module(_func)
spec = _spec_from_loader(loader.name, loader) for function in dir(_func):
func_ = _module_from_spec(spec) if function.startswith('_'):
loader.exec_module(func_) continue
for function in dir(func_): setattr(func, function, getattr(_func, function))
if function.startswith('_'):
continue
setattr(func, function, getattr(func_, function))
_load_functions('tests/dictionaries/../eosfunc/test.py')
try: try:
from tiramisu3 import * from tiramisu3 import *
except: except:
from tiramisu import * from tiramisu import *
option_2 = StrOption(name="mode_conteneur_actif", doc="Redefine description", properties=frozenset({"normal"})) option_3 = StrOption(name="mode_conteneur_actif", doc="Redefine description", properties=frozenset({"normal"}))
option_2.impl_set_information('help', "message with '") option_3.impl_set_information('help', "message with '")
option_3 = StrOption(name="mode_conteneur_actif1", doc="Redefine description", properties=frozenset({"normal"})) option_4 = StrOption(name="mode_conteneur_actif1", doc="Redefine description", properties=frozenset({"normal"}))
option_3.impl_set_information('help', "message with \"") option_4.impl_set_information('help', "message with \"")
optiondescription_1 = OptionDescription(name="general", doc="general", children=[option_2, option_3], properties=frozenset({"normal"})) option_2 = OptionDescription(name="general", doc="general", children=[option_3, option_4], properties=frozenset({"normal"}))
optiondescription_4 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_1]) option_1 = OptionDescription(name="rougail", doc="rougail", children=[option_2])
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_4]) option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[option_1])

View file

@ -1,35 +0,0 @@
from importlib.machinery import SourceFileLoader as _SourceFileLoader
from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec
class func:
pass
def _load_functions(path):
global _SourceFileLoader, _spec_from_loader, _module_from_spec, func
loader = _SourceFileLoader('func', path)
spec = _spec_from_loader(loader.name, loader)
func_ = _module_from_spec(spec)
loader.exec_module(func_)
for function in dir(func_):
if function.startswith('_'):
continue
setattr(func, function, getattr(func_, function))
_load_functions('tests/dictionaries/../eosfunc/test.py')
try:
from tiramisu3 import *
except:
from tiramisu import *
option_2 = StrOption(name="mode_conteneur_actif", doc="Redefine description", properties=frozenset({"normal"}))
option_2.impl_set_information('help', "message with '")
option_3 = StrOption(name="mode_conteneur_actif1", doc="Redefine description", properties=frozenset({"normal"}))
option_3.impl_set_information('help', "message with \"")
optiondescription_1 = OptionDescription(name="general", doc="general", children=[option_2, option_3], properties=frozenset({"normal"}))
optiondescription_8 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_1])
optiondescription_7 = OptionDescription(name="1", doc="1", children=[optiondescription_8])
option_5 = StrOption(name="mode_conteneur_actif", doc="Redefine description", properties=frozenset({"normal"}))
option_5.impl_set_information('help', "message with '")
option_6 = StrOption(name="mode_conteneur_actif1", doc="Redefine description", properties=frozenset({"normal"}))
option_6.impl_set_information('help', "message with \"")
optiondescription_4 = OptionDescription(name="general", doc="general", children=[option_5, option_6], properties=frozenset({"normal"}))
optiondescription_10 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_4])
optiondescription_9 = OptionDescription(name="2", doc="2", children=[optiondescription_10])
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_7, optiondescription_9])

View file

@ -2,23 +2,19 @@ from importlib.machinery import SourceFileLoader as _SourceFileLoader
from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec
class func: class func:
pass pass
_loader = _SourceFileLoader('func', 'tests/dictionaries/../eosfunc/test.py')
def _load_functions(path): _spec = _spec_from_loader(_loader.name, _loader)
global _SourceFileLoader, _spec_from_loader, _module_from_spec, func _func = _module_from_spec(_spec)
loader = _SourceFileLoader('func', path) _loader.exec_module(_func)
spec = _spec_from_loader(loader.name, loader) for function in dir(_func):
func_ = _module_from_spec(spec) if function.startswith('_'):
loader.exec_module(func_) continue
for function in dir(func_): setattr(func, function, getattr(_func, function))
if function.startswith('_'):
continue
setattr(func, function, getattr(func_, function))
_load_functions('tests/dictionaries/../eosfunc/test.py')
try: try:
from tiramisu3 import * from tiramisu3 import *
except: except:
from tiramisu import * from tiramisu import *
option_2 = StrOption(name="mode_conteneur_actif", doc="Redefine description", multi=True, default=['non'], default_multi="non", properties=frozenset({"force_default_on_freeze", "frozen", "hidden", "mandatory", "normal"})) option_3 = StrOption(name="mode_conteneur_actif", doc="Redefine description", multi=True, default=['non'], default_multi="non", properties=frozenset({"force_default_on_freeze", "frozen", "hidden", "mandatory", "normal"}))
optiondescription_1 = OptionDescription(name="general", doc="general", children=[option_2], properties=frozenset({"normal"})) option_2 = OptionDescription(name="general", doc="general", children=[option_3], properties=frozenset({"normal"}))
optiondescription_3 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_1]) option_1 = OptionDescription(name="rougail", doc="rougail", children=[option_2])
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_3]) option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[option_1])

View file

@ -1,29 +0,0 @@
from importlib.machinery import SourceFileLoader as _SourceFileLoader
from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec
class func:
pass
def _load_functions(path):
global _SourceFileLoader, _spec_from_loader, _module_from_spec, func
loader = _SourceFileLoader('func', path)
spec = _spec_from_loader(loader.name, loader)
func_ = _module_from_spec(spec)
loader.exec_module(func_)
for function in dir(func_):
if function.startswith('_'):
continue
setattr(func, function, getattr(func_, function))
_load_functions('tests/dictionaries/../eosfunc/test.py')
try:
from tiramisu3 import *
except:
from tiramisu import *
option_2 = StrOption(name="mode_conteneur_actif", doc="Redefine description", multi=True, default=['non'], default_multi="non", properties=frozenset({"force_default_on_freeze", "frozen", "hidden", "mandatory", "normal"}))
optiondescription_1 = OptionDescription(name="general", doc="general", children=[option_2], properties=frozenset({"normal"}))
optiondescription_6 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_1])
optiondescription_5 = OptionDescription(name="1", doc="1", children=[optiondescription_6])
option_4 = StrOption(name="mode_conteneur_actif", doc="Redefine description", multi=True, default=['non'], default_multi="non", properties=frozenset({"force_default_on_freeze", "frozen", "hidden", "mandatory", "normal"}))
optiondescription_3 = OptionDescription(name="general", doc="general", children=[option_4], properties=frozenset({"normal"}))
optiondescription_8 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_3])
optiondescription_7 = OptionDescription(name="2", doc="2", children=[optiondescription_8])
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_5, optiondescription_7])

View file

@ -1,10 +0,0 @@
<?xml version='1.0' encoding='UTF-8'?>
<rougail version="0.10">
<variables>
<family name="general">
<variable name="mode_conteneur_actif" type="string" description="Redefine description" hidden="True" multi="True" unique="False">
<value>non</value>
</variable>
</family>
</variables>
</rougail>

View file

@ -1,8 +0,0 @@
{
"rougail.general.mode_conteneur_actif": {
"owner": "default",
"value": [
"non"
]
}
}

View file

@ -1,5 +0,0 @@
{
"rougail.general.mode_conteneur_actif": [
"non"
]
}

View file

@ -1,8 +0,0 @@
{
"rougail.general.mode_conteneur_actif": {
"owner": "default",
"value": [
"non"
]
}
}

View file

@ -1,24 +0,0 @@
from importlib.machinery import SourceFileLoader as _SourceFileLoader
from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec
class func:
pass
def _load_functions(path):
global _SourceFileLoader, _spec_from_loader, _module_from_spec, func
loader = _SourceFileLoader('func', path)
spec = _spec_from_loader(loader.name, loader)
func_ = _module_from_spec(spec)
loader.exec_module(func_)
for function in dir(func_):
if function.startswith('_'):
continue
setattr(func, function, getattr(func_, function))
_load_functions('tests/dictionaries/../eosfunc/test.py')
try:
from tiramisu3 import *
except:
from tiramisu import *
option_2 = StrOption(name="mode_conteneur_actif", doc="Redefine description", multi=True, default=['non'], default_multi="non", properties=frozenset({"force_default_on_freeze", "frozen", "hidden", "mandatory", "normal", "notunique"}))
optiondescription_1 = OptionDescription(name="general", doc="general", children=[option_2], properties=frozenset({"normal"}))
optiondescription_3 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_1])
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_3])

View file

@ -1,29 +0,0 @@
from importlib.machinery import SourceFileLoader as _SourceFileLoader
from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec
class func:
pass
def _load_functions(path):
global _SourceFileLoader, _spec_from_loader, _module_from_spec, func
loader = _SourceFileLoader('func', path)
spec = _spec_from_loader(loader.name, loader)
func_ = _module_from_spec(spec)
loader.exec_module(func_)
for function in dir(func_):
if function.startswith('_'):
continue
setattr(func, function, getattr(func_, function))
_load_functions('tests/dictionaries/../eosfunc/test.py')
try:
from tiramisu3 import *
except:
from tiramisu import *
option_2 = StrOption(name="mode_conteneur_actif", doc="Redefine description", multi=True, default=['non'], default_multi="non", properties=frozenset({"force_default_on_freeze", "frozen", "hidden", "mandatory", "normal", "notunique"}))
optiondescription_1 = OptionDescription(name="general", doc="general", children=[option_2], properties=frozenset({"normal"}))
optiondescription_6 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_1])
optiondescription_5 = OptionDescription(name="1", doc="1", children=[optiondescription_6])
option_4 = StrOption(name="mode_conteneur_actif", doc="Redefine description", multi=True, default=['non'], default_multi="non", properties=frozenset({"force_default_on_freeze", "frozen", "hidden", "mandatory", "normal", "notunique"}))
optiondescription_3 = OptionDescription(name="general", doc="general", children=[option_4], properties=frozenset({"normal"}))
optiondescription_8 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_3])
optiondescription_7 = OptionDescription(name="2", doc="2", children=[optiondescription_8])
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_5, optiondescription_7])

View file

@ -1,10 +0,0 @@
<?xml version='1.0' encoding='UTF-8'?>
<rougail version="0.10">
<variables>
<family name="general">
<variable name="mode_conteneur_actif" type="string" description="Redefine description" hidden="True" multi="True" unique="True">
<value>non</value>
</variable>
</family>
</variables>
</rougail>

View file

@ -1,8 +0,0 @@
{
"rougail.general.mode_conteneur_actif": {
"owner": "default",
"value": [
"non"
]
}
}

View file

@ -1,5 +0,0 @@
{
"rougail.general.mode_conteneur_actif": [
"non"
]
}

View file

@ -1,8 +0,0 @@
{
"rougail.general.mode_conteneur_actif": {
"owner": "default",
"value": [
"non"
]
}
}

View file

@ -1,24 +0,0 @@
from importlib.machinery import SourceFileLoader as _SourceFileLoader
from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec
class func:
pass
def _load_functions(path):
global _SourceFileLoader, _spec_from_loader, _module_from_spec, func
loader = _SourceFileLoader('func', path)
spec = _spec_from_loader(loader.name, loader)
func_ = _module_from_spec(spec)
loader.exec_module(func_)
for function in dir(func_):
if function.startswith('_'):
continue
setattr(func, function, getattr(func_, function))
_load_functions('tests/dictionaries/../eosfunc/test.py')
try:
from tiramisu3 import *
except:
from tiramisu import *
option_2 = StrOption(name="mode_conteneur_actif", doc="Redefine description", multi=True, default=['non'], default_multi="non", properties=frozenset({"force_default_on_freeze", "frozen", "hidden", "mandatory", "normal", "unique"}))
optiondescription_1 = OptionDescription(name="general", doc="general", children=[option_2], properties=frozenset({"normal"}))
optiondescription_3 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_1])
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_3])

View file

@ -1,29 +0,0 @@
from importlib.machinery import SourceFileLoader as _SourceFileLoader
from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec
class func:
pass
def _load_functions(path):
global _SourceFileLoader, _spec_from_loader, _module_from_spec, func
loader = _SourceFileLoader('func', path)
spec = _spec_from_loader(loader.name, loader)
func_ = _module_from_spec(spec)
loader.exec_module(func_)
for function in dir(func_):
if function.startswith('_'):
continue
setattr(func, function, getattr(func_, function))
_load_functions('tests/dictionaries/../eosfunc/test.py')
try:
from tiramisu3 import *
except:
from tiramisu import *
option_2 = StrOption(name="mode_conteneur_actif", doc="Redefine description", multi=True, default=['non'], default_multi="non", properties=frozenset({"force_default_on_freeze", "frozen", "hidden", "mandatory", "normal", "unique"}))
optiondescription_1 = OptionDescription(name="general", doc="general", children=[option_2], properties=frozenset({"normal"}))
optiondescription_6 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_1])
optiondescription_5 = OptionDescription(name="1", doc="1", children=[optiondescription_6])
option_4 = StrOption(name="mode_conteneur_actif", doc="Redefine description", multi=True, default=['non'], default_multi="non", properties=frozenset({"force_default_on_freeze", "frozen", "hidden", "mandatory", "normal", "unique"}))
optiondescription_3 = OptionDescription(name="general", doc="general", children=[option_4], properties=frozenset({"normal"}))
optiondescription_8 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_3])
optiondescription_7 = OptionDescription(name="2", doc="2", children=[optiondescription_8])
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_5, optiondescription_7])

View file

@ -2,25 +2,21 @@ from importlib.machinery import SourceFileLoader as _SourceFileLoader
from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec
class func: class func:
pass pass
_loader = _SourceFileLoader('func', 'tests/dictionaries/../eosfunc/test.py')
def _load_functions(path): _spec = _spec_from_loader(_loader.name, _loader)
global _SourceFileLoader, _spec_from_loader, _module_from_spec, func _func = _module_from_spec(_spec)
loader = _SourceFileLoader('func', path) _loader.exec_module(_func)
spec = _spec_from_loader(loader.name, loader) for function in dir(_func):
func_ = _module_from_spec(spec) if function.startswith('_'):
loader.exec_module(func_) continue
for function in dir(func_): setattr(func, function, getattr(_func, function))
if function.startswith('_'):
continue
setattr(func, function, getattr(func_, function))
_load_functions('tests/dictionaries/../eosfunc/test.py')
try: try:
from tiramisu3 import * from tiramisu3 import *
except: except:
from tiramisu import * from tiramisu import *
option_2 = FloatOption(name="float", doc="Description", default=0.527, properties=frozenset({"mandatory", "normal"})) option_3 = FloatOption(name="float", doc="Description", default=0.527, properties=frozenset({"mandatory", "normal"}))
option_3 = FloatOption(name="float_multi", doc="Description", multi=True, default=[0.527], default_multi=0.527, properties=frozenset({"mandatory", "normal"})) option_4 = FloatOption(name="float_multi", doc="Description", multi=True, default=[0.527], default_multi=0.527, properties=frozenset({"mandatory", "normal"}))
optiondescription_1 = OptionDescription(name="general", doc="general", children=[option_2, option_3], properties=frozenset({"normal"})) option_2 = OptionDescription(name="general", doc="general", children=[option_3, option_4], properties=frozenset({"normal"}))
optiondescription_4 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_1]) option_1 = OptionDescription(name="rougail", doc="rougail", children=[option_2])
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_4]) option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[option_1])
option_0.impl_set_information('provider:float', "rougail.general.float") option_0.impl_set_information('provider:float', "rougail.general.float")

View file

@ -1,33 +0,0 @@
from importlib.machinery import SourceFileLoader as _SourceFileLoader
from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec
class func:
pass
def _load_functions(path):
global _SourceFileLoader, _spec_from_loader, _module_from_spec, func
loader = _SourceFileLoader('func', path)
spec = _spec_from_loader(loader.name, loader)
func_ = _module_from_spec(spec)
loader.exec_module(func_)
for function in dir(func_):
if function.startswith('_'):
continue
setattr(func, function, getattr(func_, function))
_load_functions('tests/dictionaries/../eosfunc/test.py')
try:
from tiramisu3 import *
except:
from tiramisu import *
option_2 = FloatOption(name="float", doc="Description", default=0.527, properties=frozenset({"mandatory", "normal"}))
option_3 = FloatOption(name="float_multi", doc="Description", multi=True, default=[0.527], default_multi=0.527, properties=frozenset({"mandatory", "normal"}))
optiondescription_1 = OptionDescription(name="general", doc="general", children=[option_2, option_3], properties=frozenset({"normal"}))
optiondescription_8 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_1])
optiondescription_7 = OptionDescription(name="1", doc="1", children=[optiondescription_8])
optiondescription_7.impl_set_information('provider:float', "rougail.general.float")
option_5 = FloatOption(name="float", doc="Description", default=0.527, properties=frozenset({"mandatory", "normal"}))
option_6 = FloatOption(name="float_multi", doc="Description", multi=True, default=[0.527], default_multi=0.527, properties=frozenset({"mandatory", "normal"}))
optiondescription_4 = OptionDescription(name="general", doc="general", children=[option_5, option_6], properties=frozenset({"normal"}))
optiondescription_10 = OptionDescription(name="rougail", doc="Rougail", children=[optiondescription_4])
optiondescription_9 = OptionDescription(name="2", doc="2", children=[optiondescription_10])
optiondescription_9.impl_set_information('provider:float', "rougail.general.float")
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_7, optiondescription_9])

View file

@ -1,6 +0,0 @@
<?xml version='1.0' encoding='UTF-8'?>
<rougail version="0.10">
<variables>
<variable name="float" type="float" description="Description"/>
</variables>
</rougail>

View file

@ -1,8 +0,0 @@
<?xml version='1.0' encoding='UTF-8'?>
<rougail version="0.10">
<variables>
<family name="example">
<variable name="description" type="string" provider="example"/>
</family>
</variables>
</rougail>

View file

@ -1,10 +0,0 @@
{
"rougail.float": {
"owner": "default",
"value": null
},
"extra.example.description": {
"owner": "default",
"value": null
}
}

View file

@ -1,4 +0,0 @@
{
"rougail.float": null,
"extra.example.description": null
}

View file

@ -1,10 +0,0 @@
{
"rougail.float": {
"owner": "default",
"value": null
},
"extra.example.description": {
"owner": "default",
"value": null
}
}

View file

@ -1,27 +0,0 @@
from importlib.machinery import SourceFileLoader as _SourceFileLoader
from importlib.util import spec_from_loader as _spec_from_loader, module_from_spec as _module_from_spec
class func:
pass
def _load_functions(path):
global _SourceFileLoader, _spec_from_loader, _module_from_spec, func
loader = _SourceFileLoader('func', path)
spec = _spec_from_loader(loader.name, loader)
func_ = _module_from_spec(spec)
loader.exec_module(func_)
for function in dir(func_):
if function.startswith('_'):
continue
setattr(func, function, getattr(func_, function))
_load_functions('tests/dictionaries/../eosfunc/test.py')
try:
from tiramisu3 import *
except:
from tiramisu import *
option_1 = FloatOption(name="float", doc="Description", properties=frozenset({"normal"}))
optiondescription_4 = OptionDescription(name="rougail", doc="Rougail", children=[option_1])
option_3 = StrOption(name="description", doc="description", properties=frozenset({"normal"}))
optiondescription_2 = OptionDescription(name="example", doc="example", children=[option_3], properties=frozenset({"normal"}))
optiondescription_5 = OptionDescription(name="extra", doc="extra", children=[optiondescription_2])
option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_4, optiondescription_5])
option_0.impl_set_information('provider:example', "extra.example.description")

Some files were not shown because too many files have changed in this diff Show more