Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

make metric_data_file_prefix global in functions #81

Merged
merged 1 commit into from
Aug 7, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions python/toolbox/metrics.py
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ def log_sample(this_file_id: str, desc: object, names: object, sample: object):
None
"""

global file_id, total_logged_samples, total_cons_samples, stored_sample
global file_id, total_logged_samples, total_cons_samples, stored_sample, metric_data_file_prefix
file_id = this_file_id
metric_data_file_prefix = "metric-data-" + file_id
metric_data_file = metric_data_file_prefix + ".csv.xz"
Expand Down Expand Up @@ -167,7 +167,7 @@ def finish_samples():
str: The prefix of the metric data file that was written.
"""

global file_id, stored_sample, interval, metric_idx, metric_types
global file_id, stored_sample, interval, metric_idx, metric_types, metric_data_file_prefix
if file_id is not None:
new_metric_types = []
num_deletes = 0
Expand Down
Loading