p3lib 1.1.104__py3-none-any.whl → 1.1.105__py3-none-any.whl

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.
@@ -3,7 +3,6 @@
3
3
  import os
4
4
  import sys
5
5
  import platform
6
- import site
7
6
 
8
7
  class GnomeDesktopApp(object):
9
8
  """@brief Responsible for adding and removing gnome desktop files for launching applications on a Linux system."""
@@ -73,11 +72,16 @@ class GnomeDesktopApp(object):
73
72
  path2 = os.path.join(startup_parent_path, 'assets')
74
73
  self._abs_icon_file = os.path.join(path2, icon_file)
75
74
  if not os.path.isfile(self._abs_icon_file):
76
- site_packages_folder = site.getusersitepackages()
77
- path3 = os.path.join(site_packages_folder, 'assets')
78
- self._abs_icon_file = os.path.join(path3, icon_file)
79
- if not os.path.isfile(self._abs_icon_file):
80
- raise Exception(f"{self._app_name} icon file ({icon_file}) not found.")
75
+ # Try all the site packages folders we know about.
76
+ for path in sys.path:
77
+ if 'site-packages' in path:
78
+ site_packages_path = path
79
+ path3 = os.path.join(site_packages_path, 'assets')
80
+ self._abs_icon_file = os.path.join(path3, icon_file)
81
+ if os.path.isfile(self._abs_icon_file):
82
+ return self._abs_icon_file
83
+
84
+ raise Exception(f"{self._app_name} icon file ({icon_file}) not found.")
81
85
 
82
86
  def _get_gnome_desktop_file(self):
83
87
  """@brief Determine and return the name of the gnome desktop file.
@@ -105,7 +109,7 @@ class GnomeDesktopApp(object):
105
109
  lines.append(f'Name={self._app_name}')
106
110
  lines.append(f'Comment={self._comment}')
107
111
  lines.append(f'Icon={self._abs_icon_file}')
108
- lines.append(f'Exec=python3 {self._startup_file}')
112
+ lines.append(f'Exec={self._startup_file}')
109
113
  lines.append('Terminal=false')
110
114
  lines.append(f'Categories={self._categories}')
111
115
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.2
2
2
  Name: p3lib
3
- Version: 1.1.104
3
+ Version: 1.1.105
4
4
  Summary: A group of python modules for networking, plotting data, config storage, automating boot scripts, ssh access and user input output.
5
5
  Home-page: https://github.com/pjaos/p3lib
6
6
  Author: Paul Austen
@@ -6,7 +6,7 @@ p3lib/boot_manager.py,sha256=l7WlaoIRt4cu2jAdCs3FnDeNO2v2jzqideNZ3qg2r_4,19652
6
6
  p3lib/conduit.py,sha256=jPkjdtyCx2I6SFqcEo8y2g7rgnZ-jNY7oCuYIETzT5Q,6046
7
7
  p3lib/database_if.py,sha256=XKu1w3zftGbj4Rh54wrWJnoCtqHkhCzJUPN2S70XIKg,11915
8
8
  p3lib/file_io.py,sha256=A7_GKYPlmjRjq6U1YuWhmB0OhLhNm6cWQfQX8qfgYTk,5041
9
- p3lib/gnome_desktop_app.py,sha256=otNm4DF0q5o4HMgsHlASAqG5GfZK_94y5jYSUAFq5Q4,6491
9
+ p3lib/gnome_desktop_app.py,sha256=zl9SKRBV8ipVg2faCs_gbAr8c42J1N_pntbFGG2BMiE,6694
10
10
  p3lib/helper.py,sha256=xTKPgpziwr4zyaoc0sjZRFr0M91fo7Tok_nSAvtiTZE,12020
11
11
  p3lib/json_networking.py,sha256=6u4s1SmypjTYPnSxHP712OgQ3ZJaxOqIkgHQ1J7Qews,9738
12
12
  p3lib/mqtt_rpc.py,sha256=6LmFA1kR4HSJs9eWbOJORRHNY01L_lHWjvtE2fmY8P8,10511
@@ -17,8 +17,8 @@ p3lib/pconfig.py,sha256=2yZUK5nkqpAm4Y_xcJq5H9Lxmc8dfYei1Pi0Ek2Crh0,35376
17
17
  p3lib/ssh.py,sha256=OyoAQ_h1L2RfkjTAChDrvLFfl4Fe_gBNdX5rvK-wKiw,42125
18
18
  p3lib/table_plot.py,sha256=RPncwVlGUkkx5Fw0dHQedXo0TSPlTi__VrJBDzaMsuI,32116
19
19
  p3lib/uio.py,sha256=Aaxc99XiE3d2f9vLjaN-bZsckoNxay5t0ujdK6PXGrw,23265
20
- p3lib-1.1.104.dist-info/LICENSE,sha256=igqTy5u0kVWM1n-NUZMvAlinY6lVjAXKoag0okkS8V8,1067
21
- p3lib-1.1.104.dist-info/METADATA,sha256=6uoDW17_NFjczYntS5wBSPflShu_r2QYIZPMHOR6SJY,919
22
- p3lib-1.1.104.dist-info/WHEEL,sha256=In9FTNxeP60KnTkGw7wk6mJPYd_dQSjEZmXdBdMCI-8,91
23
- p3lib-1.1.104.dist-info/top_level.txt,sha256=SDCpXYh-19yCFp4Z8ZK4B-3J4NvTCJElZ42NPgcR6-U,6
24
- p3lib-1.1.104.dist-info/RECORD,,
20
+ p3lib-1.1.105.dist-info/LICENSE,sha256=igqTy5u0kVWM1n-NUZMvAlinY6lVjAXKoag0okkS8V8,1067
21
+ p3lib-1.1.105.dist-info/METADATA,sha256=Uc29N8eWR5fxCJ3MDRMnytOWcXHl7ds3Uuucw32-oMs,919
22
+ p3lib-1.1.105.dist-info/WHEEL,sha256=In9FTNxeP60KnTkGw7wk6mJPYd_dQSjEZmXdBdMCI-8,91
23
+ p3lib-1.1.105.dist-info/top_level.txt,sha256=SDCpXYh-19yCFp4Z8ZK4B-3J4NvTCJElZ42NPgcR6-U,6
24
+ p3lib-1.1.105.dist-info/RECORD,,