Skip to content

Commit

Permalink
fix(#): Fixes after linter
Browse files Browse the repository at this point in the history
  • Loading branch information
pro-akim committed Nov 16, 2023
1 parent 0fb1c88 commit 890964d
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions src/wazuh_qa_framework/system/wazuh_handler.py
Original file line number Diff line number Diff line change
Expand Up @@ -653,7 +653,8 @@ def get_agents_id(self, manager, agents_list):
"""
endpoint = f"/agents"
request = WazuhAPIRequest(endpoint=endpoint, method='GET')
agents_information = request.send(WazuhAPI(address=self.get_host_ansible_ip(manager))).data['affected_items']
agents_information = request.send(WazuhAPI(
address=self.get_host_ansible_ip(manager))).data['affected_items']
result_id = []
agent_ip_list = []
for agent in agents_list:
Expand Down Expand Up @@ -1048,7 +1049,8 @@ def get_group_list(self, manager, method='api'):
for group in request.send(WazuhAPI(address=self.get_host_ansible_ip(manager))).data['affected_items']:
group_list.append(group['name'])
else:
group_list = self.run_command(manager, f"{get_bin_directory_path(os_host=self.get_host_os_type(manager))}/agent_groups")
group_list = self.run_command(manager, f"{get_bin_directory_path(
os_host=self.get_host_os_type(manager))}/agent_groups")
pattern = r' ([^\s()]+) \(\d+\)'
group_list = re.findall(pattern, str(group_list))

Expand Down Expand Up @@ -1180,7 +1182,7 @@ def assign_agents_group(self, manager, list_agent_names, group_name, method='api
"""
self.logger.info(f"Assigning agents {list_agent_names} from group {group_name} from {manager}")
if parallel:
self.pool.starmap(self.assign_agent_group, ((manager, agent_name, group_name, method, check_group)
self.pool.starmap(self.assign_agent_group, ((manager, agent_name, group_name, method, check_group)
for agent_name in list_agent_names))

else:
Expand Down

0 comments on commit 890964d

Please sign in to comment.