Skip to content

Commit

Permalink
add program name and version
Browse files Browse the repository at this point in the history
  • Loading branch information
rettigl committed Feb 12, 2025
1 parent f716b77 commit 488209c
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions src/specsscan/helpers.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@
from __future__ import annotations

import datetime as dt
import importlib
import logging
from pathlib import Path
from typing import Any
Expand Down Expand Up @@ -410,6 +411,11 @@ def handle_meta(
complete_dictionary(scan_info, lut_meta),
) # merging dictionaries

# store program version
metadata["scan_info"]["program_name"] = "specsanalyzer"
metadata["scan_info"]["program_version"] = importlib.metadata.version("specsanalyzer")

# timing
logger.info("Collecting time stamps...")
if "time" in metadata["scan_info"]:
time_list = [metadata["scan_info"]["time"][0], metadata["scan_info"]["time"][-1]]
Expand Down

0 comments on commit 488209c

Please sign in to comment.