Skip to content

Commit

Permalink
fix: remove verbose logging messages
Browse files Browse the repository at this point in the history
  • Loading branch information
Rebits committed Feb 14, 2024
1 parent 2af4b36 commit e53a340
Showing 1 changed file with 0 additions and 14 deletions.
14 changes: 0 additions & 14 deletions deps/wazuh_testing/wazuh_testing/end_to_end/monitoring.py
Original file line number Diff line number Diff line change
Expand Up @@ -117,33 +117,19 @@ def filter_events_by_timestamp(match_events: List) -> List:
regex_match = False

while current_timeout < timeout:
logging.critical(f"Monitoring {regex} on {host} for {timeout} seconds")
logging.critical(f"Current timeout: {current_timeout}")
logging.critical(f"Timeout: {timeout}")


file_content = host_manager.get_file_content(host, monitoring_file)
match_regex = re.findall(regex, file_content)

logging.critical(f"Matched events: {match_regex}")

if greater_than_timestamp:
match_that_fit_timestamp = filter_events_by_timestamp(match_regex)
else:
match_that_fit_timestamp = list(match_regex)

logging.critical(f"Matched events that fit the timestamp: {match_that_fit_timestamp}")

if match_that_fit_timestamp and len(list(match_that_fit_timestamp)) >= n_iterations:
elements_found = list(match_that_fit_timestamp)
regex_match = True
logging.critical(f"Element found: {element}")
break

logging.critical(f"Element not found: {element}")

logging.critical(f"Sleeping for {scan_interval} seconds")

sleep(scan_interval)

current_timeout = current_timeout + scan_interval
Expand Down

0 comments on commit e53a340

Please sign in to comment.