diff --git a/CHANGELOG.md b/CHANGELOG.md index e37d94086..a41e40a0c 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,9 @@ +## 1.2.0a13 (2025-03-27) + +### Fix + +- allow no user_datas installation (for example to generate doc) + ## 1.2.0a12 (2025-03-19) ### Feat diff --git a/pyproject.toml b/pyproject.toml index b4a23b8e4..5e508300e 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -4,7 +4,7 @@ requires = ["flit_core >=3.8.0,<4"] [project] name = "rougail" -version = "1.2.0a12" +version = "1.2.0a13" authors = [{name = "Emmanuel Garette", email = "gnunux@gnunux.info"}] readme = "README.md" description = "A consistency handling system that was initially designed in the configuration management" diff --git a/tests/dictionaries/00_6secret_param/makedict/after.json b/tests/dictionaries/00_6secret_param/makedict/after.json new file mode 100644 index 000000000..ecb67a4b6 --- /dev/null +++ b/tests/dictionaries/00_6secret_param/makedict/after.json @@ -0,0 +1,10 @@ +{ + "rougail.secret1": { + "owner": "default", + "value": null + }, + "rougail.secret2": { + "owner": "default", + "value": "value" + } +} diff --git a/tests/dictionaries/00_6secret_param/makedict/base.json b/tests/dictionaries/00_6secret_param/makedict/base.json new file mode 100644 index 000000000..1ae37c88a --- /dev/null +++ b/tests/dictionaries/00_6secret_param/makedict/base.json @@ -0,0 +1,4 @@ +{ + "rougail.secret1": null, + "rougail.secret2": "value" +} diff --git a/tests/dictionaries/00_6secret_param/makedict/before.json b/tests/dictionaries/00_6secret_param/makedict/before.json new file mode 100644 index 000000000..ecb67a4b6 --- /dev/null +++ b/tests/dictionaries/00_6secret_param/makedict/before.json @@ -0,0 +1,10 @@ +{ + "rougail.secret1": { + "owner": "default", + "value": null + }, + "rougail.secret2": { + "owner": "default", + "value": "value" + } +} diff --git a/tests/dictionaries/00_6secret_param/makedict/mandatory.json b/tests/dictionaries/00_6secret_param/makedict/mandatory.json new file mode 100644 index 000000000..23ac0af58 --- /dev/null +++ b/tests/dictionaries/00_6secret_param/makedict/mandatory.json @@ -0,0 +1 @@ +["rougail.secret1"] \ No newline at end of file diff --git a/tests/dictionaries/00_6secret_param/tiramisu/base.py b/tests/dictionaries/00_6secret_param/tiramisu/base.py new file mode 100644 index 000000000..b816ff617 --- /dev/null +++ b/tests/dictionaries/00_6secret_param/tiramisu/base.py @@ -0,0 +1,16 @@ +from tiramisu import * +from tiramisu.setting import ALLOWED_LEADER_PROPERTIES +from re import compile as re_compile +from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription +load_functions('../rougail-tests/funcs/test.py') +try: + groups.namespace +except: + groups.addgroup('namespace') +ALLOWED_LEADER_PROPERTIES.add("basic") +ALLOWED_LEADER_PROPERTIES.add("standard") +ALLOWED_LEADER_PROPERTIES.add("advanced") +option_2 = PasswordOption(name="secret1", doc="the first variable", min_len=10, properties=frozenset({"basic", "mandatory"}), informations={'type': 'secret'}) +option_3 = PasswordOption(name="secret2", doc="the second variable", default="value", max_len=10, forbidden_char=['$', '^'], properties=frozenset({"mandatory", "standard"}), informations={'type': 'secret'}) +optiondescription_1 = OptionDescription(name="rougail", doc="Rougail", group_type=groups.namespace, children=[option_2, option_3], properties=frozenset({"basic"})) +option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_1]) diff --git a/tests/dictionaries/00_6secret_param/tiramisu/no_namespace.py b/tests/dictionaries/00_6secret_param/tiramisu/no_namespace.py new file mode 100644 index 000000000..09a1d2956 --- /dev/null +++ b/tests/dictionaries/00_6secret_param/tiramisu/no_namespace.py @@ -0,0 +1,11 @@ +from tiramisu import * +from tiramisu.setting import ALLOWED_LEADER_PROPERTIES +from re import compile as re_compile +from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription +load_functions('../rougail-tests/funcs/test.py') +ALLOWED_LEADER_PROPERTIES.add("basic") +ALLOWED_LEADER_PROPERTIES.add("standard") +ALLOWED_LEADER_PROPERTIES.add("advanced") +option_1 = PasswordOption(name="secret1", doc="the first variable", min_len=10, properties=frozenset({"basic", "mandatory"}), informations={'type': 'secret'}) +option_2 = PasswordOption(name="secret2", doc="the second variable", default="value", max_len=10, forbidden_char=['$', '^'], properties=frozenset({"mandatory", "standard"}), informations={'type': 'secret'}) +option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[option_1, option_2]) diff --git a/tests/dictionaries/00_7help/makedict/after.json b/tests/dictionaries/00_7help/makedict/after.json new file mode 100644 index 000000000..7ea9435a0 --- /dev/null +++ b/tests/dictionaries/00_7help/makedict/after.json @@ -0,0 +1,10 @@ +{ + "rougail.var1": { + "owner": "default", + "value": null + }, + "rougail.var2": { + "owner": "default", + "value": null + } +} diff --git a/tests/dictionaries/00_7help/makedict/base.json b/tests/dictionaries/00_7help/makedict/base.json new file mode 100644 index 000000000..559aec2a4 --- /dev/null +++ b/tests/dictionaries/00_7help/makedict/base.json @@ -0,0 +1,4 @@ +{ + "rougail.var1": null, + "rougail.var2": null +} diff --git a/tests/dictionaries/00_7help/makedict/before.json b/tests/dictionaries/00_7help/makedict/before.json new file mode 100644 index 000000000..7ea9435a0 --- /dev/null +++ b/tests/dictionaries/00_7help/makedict/before.json @@ -0,0 +1,10 @@ +{ + "rougail.var1": { + "owner": "default", + "value": null + }, + "rougail.var2": { + "owner": "default", + "value": null + } +} diff --git a/tests/dictionaries/00_7help/makedict/mandatory.json b/tests/dictionaries/00_7help/makedict/mandatory.json new file mode 100644 index 000000000..8c67ac5f8 --- /dev/null +++ b/tests/dictionaries/00_7help/makedict/mandatory.json @@ -0,0 +1 @@ +["rougail.var1", "rougail.var2"] \ No newline at end of file diff --git a/tests/dictionaries/00_7help/tiramisu/base.py b/tests/dictionaries/00_7help/tiramisu/base.py new file mode 100644 index 000000000..1a4e38b4f --- /dev/null +++ b/tests/dictionaries/00_7help/tiramisu/base.py @@ -0,0 +1,16 @@ +from tiramisu import * +from tiramisu.setting import ALLOWED_LEADER_PROPERTIES +from re import compile as re_compile +from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription +load_functions('../rougail-tests/funcs/test.py') +try: + groups.namespace +except: + groups.addgroup('namespace') +ALLOWED_LEADER_PROPERTIES.add("basic") +ALLOWED_LEADER_PROPERTIES.add("standard") +ALLOWED_LEADER_PROPERTIES.add("advanced") +option_2 = StrOption(name="var1", doc="the first variable", properties=frozenset({"basic", "mandatory"}), informations={'type': 'string', 'help': 'Multi line\n\nHelp\n\nWith useful information'}) +option_3 = StrOption(name="var2", doc="the second variable", properties=frozenset({"basic", "mandatory"}), informations={'type': 'string', 'help': 'Multi line\nHelp\nWith useful information'}) +optiondescription_1 = OptionDescription(name="rougail", doc="Rougail", group_type=groups.namespace, children=[option_2, option_3], properties=frozenset({"basic"})) +option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_1]) diff --git a/tests/dictionaries/00_7help/tiramisu/no_namespace.py b/tests/dictionaries/00_7help/tiramisu/no_namespace.py new file mode 100644 index 000000000..85dbfe886 --- /dev/null +++ b/tests/dictionaries/00_7help/tiramisu/no_namespace.py @@ -0,0 +1,11 @@ +from tiramisu import * +from tiramisu.setting import ALLOWED_LEADER_PROPERTIES +from re import compile as re_compile +from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription +load_functions('../rougail-tests/funcs/test.py') +ALLOWED_LEADER_PROPERTIES.add("basic") +ALLOWED_LEADER_PROPERTIES.add("standard") +ALLOWED_LEADER_PROPERTIES.add("advanced") +option_1 = StrOption(name="var1", doc="the first variable", properties=frozenset({"basic", "mandatory"}), informations={'type': 'string', 'help': 'Multi line\n\nHelp\n\nWith useful information'}) +option_2 = StrOption(name="var2", doc="the second variable", properties=frozenset({"basic", "mandatory"}), informations={'type': 'string', 'help': 'Multi line\nHelp\nWith useful information'}) +option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[option_1, option_2]) diff --git a/tests/dictionaries/00_7help_sup/makedict/after.json b/tests/dictionaries/00_7help_sup/makedict/after.json new file mode 100644 index 000000000..7ea9435a0 --- /dev/null +++ b/tests/dictionaries/00_7help_sup/makedict/after.json @@ -0,0 +1,10 @@ +{ + "rougail.var1": { + "owner": "default", + "value": null + }, + "rougail.var2": { + "owner": "default", + "value": null + } +} diff --git a/tests/dictionaries/00_7help_sup/makedict/base.json b/tests/dictionaries/00_7help_sup/makedict/base.json new file mode 100644 index 000000000..559aec2a4 --- /dev/null +++ b/tests/dictionaries/00_7help_sup/makedict/base.json @@ -0,0 +1,4 @@ +{ + "rougail.var1": null, + "rougail.var2": null +} diff --git a/tests/dictionaries/00_7help_sup/makedict/before.json b/tests/dictionaries/00_7help_sup/makedict/before.json new file mode 100644 index 000000000..7ea9435a0 --- /dev/null +++ b/tests/dictionaries/00_7help_sup/makedict/before.json @@ -0,0 +1,10 @@ +{ + "rougail.var1": { + "owner": "default", + "value": null + }, + "rougail.var2": { + "owner": "default", + "value": null + } +} diff --git a/tests/dictionaries/00_7help_sup/makedict/mandatory.json b/tests/dictionaries/00_7help_sup/makedict/mandatory.json new file mode 100644 index 000000000..8c67ac5f8 --- /dev/null +++ b/tests/dictionaries/00_7help_sup/makedict/mandatory.json @@ -0,0 +1 @@ +["rougail.var1", "rougail.var2"] \ No newline at end of file diff --git a/tests/dictionaries/00_7help_sup/tiramisu/base.py b/tests/dictionaries/00_7help_sup/tiramisu/base.py new file mode 100644 index 000000000..640fbc002 --- /dev/null +++ b/tests/dictionaries/00_7help_sup/tiramisu/base.py @@ -0,0 +1,16 @@ +from tiramisu import * +from tiramisu.setting import ALLOWED_LEADER_PROPERTIES +from re import compile as re_compile +from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription +load_functions('../rougail-tests/funcs/test.py') +try: + groups.namespace +except: + groups.addgroup('namespace') +ALLOWED_LEADER_PROPERTIES.add("basic") +ALLOWED_LEADER_PROPERTIES.add("standard") +ALLOWED_LEADER_PROPERTIES.add("advanced") +option_2 = StrOption(name="var1", doc="the first ", properties=frozenset({"basic", "mandatory"}), informations={'type': 'string', 'help': 'Multi line\n\n\n\nWith useful information'}) +option_3 = StrOption(name="var2", doc="the second ", properties=frozenset({"basic", "mandatory"}), informations={'type': 'string', 'help': 'Multi line\n\nWith useful information'}) +optiondescription_1 = OptionDescription(name="rougail", doc="Rougail", group_type=groups.namespace, children=[option_2, option_3], properties=frozenset({"basic"})) +option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[optiondescription_1]) diff --git a/tests/dictionaries/00_7help_sup/tiramisu/no_namespace.py b/tests/dictionaries/00_7help_sup/tiramisu/no_namespace.py new file mode 100644 index 000000000..60a7bdda9 --- /dev/null +++ b/tests/dictionaries/00_7help_sup/tiramisu/no_namespace.py @@ -0,0 +1,11 @@ +from tiramisu import * +from tiramisu.setting import ALLOWED_LEADER_PROPERTIES +from re import compile as re_compile +from rougail.tiramisu import func, dict_env, load_functions, ConvertDynOptionDescription +load_functions('../rougail-tests/funcs/test.py') +ALLOWED_LEADER_PROPERTIES.add("basic") +ALLOWED_LEADER_PROPERTIES.add("standard") +ALLOWED_LEADER_PROPERTIES.add("advanced") +option_1 = StrOption(name="var1", doc="the first ", properties=frozenset({"basic", "mandatory"}), informations={'type': 'string', 'help': 'Multi line\n\n\n\nWith useful information'}) +option_2 = StrOption(name="var2", doc="the second ", properties=frozenset({"basic", "mandatory"}), informations={'type': 'string', 'help': 'Multi line\n\nWith useful information'}) +option_0 = OptionDescription(name="baseoption", doc="baseoption", children=[option_1, option_2])