utilitz 0.3.0__tar.gz → 0.3.2__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,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: utilitz
3
- Version: 0.3.0
3
+ Version: 0.3.2
4
4
  Summary: Simple Python utility functions to save and load data
5
5
  Project-URL: Homepage, https://github.com/artitzco/utilitz
6
6
  Project-URL: Issues, https://github.com/artitzco/utilitz/issues
@@ -4,7 +4,7 @@ build-backend = "hatchling.build"
4
4
 
5
5
  [project]
6
6
  name = "utilitz"
7
- version = "0.3.0"
7
+ version = "0.3.2"
8
8
  authors = [
9
9
  { name = "Artitzco", email = "artitzco@proton.me" },
10
10
  ]
@@ -1,5 +1,7 @@
1
1
  from . import excel
2
2
  from . import path
3
+ from . import sys
4
+ from . import io
3
5
  import pickle
4
6
  import json
5
7
 
@@ -109,9 +109,11 @@ def monitor_keep_alive(seconds, key='ctrl', verbose=1):
109
109
 
110
110
  monitor = MonitorActivity()
111
111
  monitor.start()
112
- status = 'Initial'
112
+ status = '==START=='
113
113
  sleep_start_time = time.time()
114
114
  time.sleep(seconds)
115
+ if verbose:
116
+ print(datetime.fromtimestamp(sleep_end_time).strftime("%Y-%m-%d %H:%M:%S"), status)
115
117
  while True:
116
118
  sleep_end_time = time.time()
117
119
  ####
@@ -121,11 +123,11 @@ def monitor_keep_alive(seconds, key='ctrl', verbose=1):
121
123
  inactive_time = sleep_end_time-last_activity_time
122
124
  if is_active:
123
125
  last_status = status
124
- status = 'Active'
126
+ status = '==ACTIVE=='
125
127
  sleep_time = seconds - inactive_time
126
128
  else:
127
129
  last_status = status
128
- status = 'Inactive'
130
+ status = '==INACTIVE=='
129
131
  sleep_time = seconds
130
132
  pyautogui.press(key)
131
133
  if verbose == 1 and status != last_status:
@@ -133,7 +135,7 @@ def monitor_keep_alive(seconds, key='ctrl', verbose=1):
133
135
  "%Y-%m-%d %H:%M:%S"), status)
134
136
  elif verbose == 2:
135
137
  print(datetime.fromtimestamp(sleep_end_time).strftime("%Y-%m-%d %H:%M:%S"), status,
136
- '\n\tInactive Time', f'{inactive_time:.03f}', 'Sleep Time', f'{sleep_time:.03f}')
138
+ '\n\tInactive Time:', f'{inactive_time:.03f}', 'Sleep Time:', f'{sleep_time:.03f}')
137
139
 
138
140
  sleep_start_time = time.time()
139
141
  time.sleep(sleep_time)
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes