1
0
Fork 0
mirror of https://github.com/ansible-collections/community.general.git synced 2026-03-22 05:09:12 +00:00

modules [no]*: use f-strings (#10973)

* modules [no]*: use f-strings

* add changelog frag
This commit is contained in:
Alexei Znamensky 2025-10-26 19:48:10 +13:00 committed by GitHub
parent 50846b7560
commit 749c06cd01
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
44 changed files with 399 additions and 412 deletions

View file

@ -521,8 +521,7 @@ def main():
if not module.params.get('auth_token'):
module.fail_json(
msg='The "auth_token" parameter or ' +
'ONEANDONE_AUTH_TOKEN environment variable is required.')
msg='The "auth_token" parameter or ONEANDONE_AUTH_TOKEN environment variable is required.')
if not module.params.get('api_url'):
oneandone_conn = oneandone.client.OneAndOneService(
@ -555,7 +554,7 @@ def main():
for param in ('name', 'rules'):
if not module.params.get(param):
module.fail_json(
msg="%s parameter is required for new firewall policies." % param)
msg=f"{param} parameter is required for new firewall policies.")
try:
(changed, firewall_policy) = create_firewall_policy(module, oneandone_conn)
except Exception as e: