p3lib 1.1.113__tar.gz → 1.1.115__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,8 +1,8 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: p3lib
3
- Version: 1.1.113
3
+ Version: 1.1.115
4
4
  Summary: A group of python modules for networking, plotting data, config storage, automating boot scripts, ssh access and user input output.
5
- Home-page: https://github.com/pjaos/test_equipment
5
+ Home-page: https://github.com/pjaos/p3lib
6
6
  License: MIT
7
7
  Author: Paul Austen
8
8
  Author-email: pjaos@gmail.com
@@ -19,7 +19,7 @@ Classifier: Programming Language :: Python :: 3.9
19
19
  Classifier: Programming Language :: Python :: 3.10
20
20
  Classifier: Programming Language :: Python :: 3.11
21
21
  Classifier: Programming Language :: Python :: 3.12
22
- Project-URL: Repository, https://github.com/pjaos/test_equipment
22
+ Project-URL: Repository, https://github.com/pjaos/p3lib
23
23
  Description-Content-Type: text/markdown
24
24
 
25
25
  # A Python3 library
@@ -1,12 +1,12 @@
1
1
  [tool.poetry]
2
2
  name = "p3lib"
3
- version = "1.1.113"
3
+ version = "1.1.115"
4
4
  description = "A group of python modules for networking, plotting data, config storage, automating boot scripts, ssh access and user input output."
5
5
  authors = ["Paul Austen <pjaos@gmail.com>"]
6
6
  license = "MIT License"
7
7
  readme = "README.md"
8
- homepage = "https://github.com/pjaos/test_equipment"
9
- repository = "https://github.com/pjaos/test_equipment"
8
+ homepage = "https://github.com/pjaos/p3lib"
9
+ repository = "https://github.com/pjaos/p3lib"
10
10
 
11
11
  [build-system]
12
12
  requires = [
@@ -13,6 +13,8 @@ from time import sleep
13
13
  from queue import Queue
14
14
  from time import time, strftime, localtime
15
15
 
16
+ from p3lib.helper import getProgramVersion
17
+
16
18
  from nicegui import ui
17
19
 
18
20
  class TabbedNiceGui(object):
@@ -78,29 +80,7 @@ class TabbedNiceGui(object):
78
80
  def GetProgramVersion():
79
81
  """@brief Get the program version from the poetry pyproject.toml file.
80
82
  @return The version of the installed program (string value)."""
81
- poetryConfigFile = os.path.join(TabbedNiceGui.LOCAL_PATH, TabbedNiceGui.POETRY_CONFIG_FILE)
82
- if not os.path.isfile(poetryConfigFile):
83
- poetryConfigFile = os.path.join(TabbedNiceGui.LOCAL_PATH, ".." + os.sep + TabbedNiceGui.POETRY_CONFIG_FILE)
84
- poetryConfigFile2 = poetryConfigFile
85
- if not os.path.isfile(poetryConfigFile):
86
- cwd = os.getcwd()
87
- poetryConfigFile = os.path.join(cwd, TabbedNiceGui.POETRY_CONFIG_FILE)
88
- if not os.path.isfile(poetryConfigFile):
89
- raise Exception(f"{poetryConfigFile}, {poetryConfigFile2} and {poetryConfigFile} not found.")
90
-
91
- programVersion = None
92
- with open(poetryConfigFile, 'r') as fd:
93
- lines = fd.readlines()
94
- for line in lines:
95
- line=line.strip("\r\n")
96
- if line.startswith('version'):
97
- elems = line.split("=")
98
- if len(elems) == 2:
99
- programVersion = elems[1].strip('" ')
100
- break
101
- if programVersion is None:
102
- raise Exception(f"Failed to extract program version from '{line}' line of {poetryConfigFile} file.")
103
- return programVersion
83
+ return getProgramVersion()
104
84
 
105
85
  def __init__(self, debugEnabled, logPath=None):
106
86
  """@brief Constructor
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes