fix: modified value without layer
This commit is contained in:
parent
80eadf773d
commit
f3d215aa42
7 changed files with 14 additions and 8 deletions
|
|
@ -278,7 +278,12 @@ class Node:
|
||||||
is_default = option.owner.isdefault()
|
is_default = option.owner.isdefault()
|
||||||
option_path = option.path()
|
option_path = option.path()
|
||||||
default_owner = owners.default
|
default_owner = owners.default
|
||||||
|
if self.root_config == meta_config:
|
||||||
|
added = True
|
||||||
|
true_default = is_default
|
||||||
|
else:
|
||||||
true_default = is_default and meta_option.owner.get() == default_owner
|
true_default = is_default and meta_option.owner.get() == default_owner
|
||||||
|
added = not is_default or true_default
|
||||||
while True:
|
while True:
|
||||||
if values and true_default and value in [None, []]:
|
if values and true_default and value in [None, []]:
|
||||||
break
|
break
|
||||||
|
|
@ -290,7 +295,7 @@ class Node:
|
||||||
loaded_from = None
|
loaded_from = None
|
||||||
else:
|
else:
|
||||||
loaded_from = meta_option.information.get(loaded_from_key, None)
|
loaded_from = meta_option.information.get(loaded_from_key, None)
|
||||||
if true_default or loaded_from or force_store_value:
|
if added or force_store_value:
|
||||||
values.append(
|
values.append(
|
||||||
{
|
{
|
||||||
"value": value,
|
"value": value,
|
||||||
|
|
@ -325,6 +330,7 @@ class Node:
|
||||||
except Exception as err:
|
except Exception as err:
|
||||||
break
|
break
|
||||||
true_default = is_default and meta_option.owner.get() == default_owner
|
true_default = is_default and meta_option.owner.get() == default_owner
|
||||||
|
added = True
|
||||||
meta_config = new_meta_config
|
meta_config = new_meta_config
|
||||||
if leader_index is not None:
|
if leader_index is not None:
|
||||||
if len(value) > leader_index:
|
if len(value) > leader_index:
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
> [!CAUTION]
|
> [!CAUTION]
|
||||||
>
|
>
|
||||||
> - family1
|
> - family1
|
||||||
> - this variable is in fact a family: :stop_sign: [- is a family so we cannot set the value "value", it has been loading from fake user data -]
|
> - this variable is in fact a family: :stop_sign: [- it's a family so we cannot set the value "value", it has been loading from fake user data -]
|
||||||
|
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
||||||
> [!CAUTION]
|
> [!CAUTION]
|
||||||
>
|
>
|
||||||
> - family1
|
> - family1
|
||||||
> - this variable is in fact a family: :stop_sign: <span style="color: #C23636">is a family so we cannot set the value "value", it has been loading from fake user data</span>
|
> - this variable is in fact a family: :stop_sign: <span style="color: #C23636">it's a family so we cannot set the value "value", it has been loading from fake user data</span>
|
||||||
|
|
|
||||||
|
|
@ -1,3 +1,3 @@
|
||||||
[1;91m🛑 Caution[0m
|
[1;91m🛑 Caution[0m
|
||||||
[91m┗━━ [0mfamily1
|
[91m┗━━ [0mfamily1
|
||||||
[91m [0m[91m┗━━ [0mthis variable is in fact a family: [91m🛑 is a family so we cannot set the value "value", it has been loading from fake user data[0m
|
[91m [0m[91m┗━━ [0mthis variable is in fact a family: [91m🛑 it's a family so we cannot set the value "value", it has been loading from fake user data[0m
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,6 @@
|
||||||
> [!CAUTION]
|
> [!CAUTION]
|
||||||
>
|
>
|
||||||
> - family1
|
> - family1
|
||||||
> - this variable is in fact a family: :bell: [- is a family so we cannot set the value "value", it will be ignored when loading from fake user data -]
|
> - this variable is in fact a family: :bell: [- it's a family so we cannot set the value "value", it will be ignored when loading from fake user data -]
|
||||||
> - this variable is in fact a family
|
> - this variable is in fact a family
|
||||||
> - a true variable: :stop_sign: [- mandatory variable but has no value -]
|
> - a true variable: :stop_sign: [- mandatory variable but has no value -]
|
||||||
|
|
|
||||||
|
|
@ -1,6 +1,6 @@
|
||||||
> [!CAUTION]
|
> [!CAUTION]
|
||||||
>
|
>
|
||||||
> - family1
|
> - family1
|
||||||
> - this variable is in fact a family: :bell: <span style="color: #EFBF04">is a family so we cannot set the value "value", it will be ignored when loading from fake user data</span>
|
> - this variable is in fact a family: :bell: <span style="color: #EFBF04">it's a family so we cannot set the value "value", it will be ignored when loading from fake user data</span>
|
||||||
> - this variable is in fact a family
|
> - this variable is in fact a family
|
||||||
> - a true variable: :stop_sign: <span style="color: #C23636">mandatory variable but has no value</span>
|
> - a true variable: :stop_sign: <span style="color: #C23636">mandatory variable but has no value</span>
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,5 @@
|
||||||
[1;91m🛑 Caution[0m
|
[1;91m🛑 Caution[0m
|
||||||
[91m┗━━ [0mfamily1
|
[91m┗━━ [0mfamily1
|
||||||
[91m [0m[91m┣━━ [0mthis variable is in fact a family: [93m🔔 is a family so we cannot set the value "value", it will be ignored when loading from fake user data[0m
|
[91m [0m[91m┣━━ [0mthis variable is in fact a family: [93m🔔 it's a family so we cannot set the value "value", it will be ignored when loading from fake user data[0m
|
||||||
[91m [0m[91m┗━━ [0mthis variable is in fact a family
|
[91m [0m[91m┗━━ [0mthis variable is in fact a family
|
||||||
[91m [0m[91m [0m[91m┗━━ [0ma true variable: [91m🛑 mandatory variable but has no value[0m
|
[91m [0m[91m [0m[91m┗━━ [0ma true variable: [91m🛑 mandatory variable but has no value[0m
|
||||||
|
|
|
||||||
Loading…
Reference in a new issue