From 9c25df1faf91f589dcf4092d994e87aa47afa001 Mon Sep 17 00:00:00 2001 From: "Antonio J. Delgado" Date: Mon, 26 Dec 2022 19:09:55 +0200 Subject: [PATCH] fix timestamp format --- restic_exporter/restic_exporter.py | 2 +- setup.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/restic_exporter/restic_exporter.py b/restic_exporter/restic_exporter.py index aa09ec4..bfcfd55 100644 --- a/restic_exporter/restic_exporter.py +++ b/restic_exporter/restic_exporter.py @@ -77,7 +77,7 @@ class restic_exporter: if 'snapshot_id' in line_data: self.labels["snapshot_id"] = line_data['snapshot_id'] file_stats = os.stat(json_file) - self.summary['timestamp'] = round(file_stats.st_mtime) + self.summary['timestamp'] = file_stats.st_mtime * 1000 self._log.debug(f"Summary: {json.dumps(self.summary, indent=2)}") self._log.debug(f"Labels: {self.labels}") diff --git a/setup.py b/setup.py index fd8f089..e495361 100644 --- a/setup.py +++ b/setup.py @@ -2,7 +2,7 @@ import setuptools setuptools.setup( scripts=['restic_exporter/restic_exporter.py'], author="Antonio J. Delgado", - version='0.0.3', + version='0.0.4', name='restic_exporter', author_email="", url="",