added more conflicting chars

This commit is contained in:
Mi³osz Stocki 2022-03-17 11:01:36 +01:00
parent e670a79d6d
commit 66107940a2
Signed by: osiu97
GPG Key ID: E3D1D83FA04F51D6
1 changed files with 1 additions and 3 deletions

View File

@ -87,7 +87,7 @@ class Agent(object):
def delete_conflict_characters(value_dict): def delete_conflict_characters(value_dict):
new_dict = {} new_dict = {}
for key, value in value_dict.items(): for key, value in value_dict.items():
new_value = str(value).replace('[', '').replace(']', '') new_value = str(value).replace('[', '').replace(']', '').replace('\\', '')
new_dict[key] = new_value new_dict[key] = new_value
return new_dict return new_dict
@ -117,5 +117,3 @@ telegraf_client = TelegrafClient(host=config['telegraf']['host'], port=config['t
for agent in agent_list: for agent in agent_list:
a = Agent(agent, api) a = Agent(agent, api)
a.send_agent_metrics(telegraf_client) a.send_agent_metrics(telegraf_client)
for k, v in a.get_agent_metrics().items():
print(k, v)