From 8349b3719caa85c6e9817ee4526e3828d2fb53cf Mon Sep 17 00:00:00 2001 From: Joel Collins Date: Fri, 6 Nov 2020 17:26:00 +0000 Subject: [PATCH] Added platform info to output --- openflexure_microscope/rescue/auto.py | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/openflexure_microscope/rescue/auto.py b/openflexure_microscope/rescue/auto.py index cca0134e..12107d43 100644 --- a/openflexure_microscope/rescue/auto.py +++ b/openflexure_microscope/rescue/auto.py @@ -1,6 +1,8 @@ import logging import os import sys +import platform +import pkg_resources from .error_sources import bcolors @@ -68,6 +70,14 @@ if __name__ == "__main__": error_sources.extend(check_capture_reload.main()) error_sources.extend(check_sangaboard.main()) + dist = pkg_resources.get_distribution("openflexure-microscope-server") + + print() + print(f"Server Version: {dist.version}") + print(f"Server Location: {dist.location}") + print(f"Platform: {platform.platform()}") + print(f"Python: {sys.version}") + if not error_sources: print() print(bcolors.OKGREEN + "No issues found!" + bcolors.ENDC)