fix: black
This commit is contained in:
parent
f0b5cf3367
commit
6824ce4190
2 changed files with 9 additions and 5 deletions
|
|
@ -15,6 +15,7 @@ details.
|
|||
You should have received a copy of the GNU Lesser General Public License
|
||||
along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
"""
|
||||
|
||||
from ruamel.yaml import YAML
|
||||
|
||||
from rougail.error import ExtentionError
|
||||
|
|
@ -33,6 +34,7 @@ class RougailUserDataYaml:
|
|||
) -> None:
|
||||
if rougailconfig is None:
|
||||
from rougail import RougailConfig
|
||||
|
||||
rougailconfig = RougailConfig
|
||||
user_data = rougailconfig["step.user_data"]
|
||||
if "yaml" not in user_data:
|
||||
|
|
@ -71,11 +73,11 @@ class RougailUserDataYaml:
|
|||
file_values,
|
||||
filename,
|
||||
)
|
||||
if self.file_with_secrets == 'none':
|
||||
if self.file_with_secrets == "none":
|
||||
allow_secrets_variables = False
|
||||
elif self.file_with_secrets == 'first':
|
||||
elif self.file_with_secrets == "first":
|
||||
allow_secrets_variables = idx == 0
|
||||
elif self.file_with_secrets == 'last':
|
||||
elif self.file_with_secrets == "last":
|
||||
if not idx:
|
||||
last_filenames = len(self.filenames) - 1
|
||||
allow_secrets_variables = idx == last_filenames
|
||||
|
|
@ -87,8 +89,9 @@ class RougailUserDataYaml:
|
|||
"errors": self.errors,
|
||||
"warnings": self.warnings,
|
||||
"values": values,
|
||||
'options': {'allow_secrets_variables': allow_secrets_variables,
|
||||
},
|
||||
"options": {
|
||||
"allow_secrets_variables": allow_secrets_variables,
|
||||
},
|
||||
}
|
||||
)
|
||||
return user_datas
|
||||
|
|
|
|||
|
|
@ -17,6 +17,7 @@ details.
|
|||
You should have received a copy of the GNU Lesser General Public License
|
||||
along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
"""
|
||||
|
||||
from .i18n import _
|
||||
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue