tconnectsync 2.0.2__tar.gz → 2.0.5__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.
- {tconnectsync-2.0.2/tconnectsync.egg-info → tconnectsync-2.0.5}/PKG-INFO +1 -1
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/setup.cfg +1 -1
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync/__init__.py +7 -2
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync/eventparser/raw_event.py +8 -2
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync/sync/tandemsource/autoupdate.py +9 -4
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync/sync/tandemsource/process.py +6 -2
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync/sync/tandemsource/process_alarm.py +2 -2
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync/sync/tandemsource/process_basal.py +6 -2
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync/sync/tandemsource/process_basal_resume.py +2 -2
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync/sync/tandemsource/process_basal_suspension.py +2 -2
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync/sync/tandemsource/process_bolus.py +1 -1
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync/sync/tandemsource/process_cartridge.py +2 -2
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync/sync/tandemsource/process_cgm_alert.py +2 -2
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync/sync/tandemsource/process_cgm_reading.py +2 -2
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync/sync/tandemsource/process_cgm_start_join_stop.py +2 -2
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync/sync/tandemsource/process_user_mode.py +2 -2
- {tconnectsync-2.0.2 → tconnectsync-2.0.5/tconnectsync.egg-info}/PKG-INFO +1 -1
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/LICENSE.md +0 -0
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/README.md +0 -0
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/pyproject.toml +0 -0
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/setup.py +0 -0
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync/api/__init__.py +0 -0
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync/api/android.py +0 -0
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync/api/common.py +0 -0
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync/api/controliq.py +0 -0
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync/api/tandemsource.py +0 -0
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync/api/webui.py +0 -0
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync/api/ws2.py +0 -0
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync/autoupdate.py +0 -0
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync/check.py +0 -0
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync/domain/__init__.py +0 -0
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync/domain/bolus.py +0 -0
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync/domain/device_settings.py +0 -0
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync/domain/tandemsource/__init__.py +0 -0
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync/domain/tandemsource/event_class.py +0 -0
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync/domain/tandemsource/pump_settings.py +0 -0
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync/domain/therapy_event.py +0 -0
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync/domain/utility.py +0 -0
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync/eventparser/__init__.py +0 -0
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync/eventparser/build_events.py +0 -0
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync/eventparser/events.py +0 -0
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync/eventparser/generic.py +0 -0
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync/eventparser/static_dicts.py +0 -0
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync/eventparser/transforms.py +0 -0
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync/eventparser/utils.py +0 -0
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync/features.py +0 -0
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync/nightscout.py +0 -0
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync/parser/__init__.py +0 -0
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync/parser/ciq_therapy_events.py +0 -0
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync/parser/nightscout.py +0 -0
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync/parser/tconnect.py +0 -0
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync/process.py +0 -0
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync/secret.py +0 -0
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync/sync/__init__.py +0 -0
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync/sync/basal.py +0 -0
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync/sync/bolus.py +0 -0
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync/sync/cgm.py +0 -0
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync/sync/iob.py +0 -0
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync/sync/profile.py +0 -0
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync/sync/pump_events.py +0 -0
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync/sync/tandemsource/__init__.py +0 -0
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync/sync/tandemsource/choose_device.py +0 -0
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync/sync/tandemsource/helpers.py +0 -0
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync/sync/tandemsource/update_profiles.py +0 -0
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync/util/__init__.py +0 -0
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync/util/cli.py +0 -0
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync/util/constants.py +0 -0
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync.egg-info/SOURCES.txt +0 -0
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync.egg-info/dependency_links.txt +0 -0
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync.egg-info/entry_points.txt +0 -0
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync.egg-info/requires.txt +0 -0
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync.egg-info/top_level.txt +0 -0
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/tests/test_autoupdate.py +0 -0
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/tests/test_process.py +0 -0
- {tconnectsync-2.0.2 → tconnectsync-2.0.5}/tests/test_secret.py +0 -0
|
@@ -111,9 +111,14 @@ def main(*args, **kwargs):
|
|
|
111
111
|
|
|
112
112
|
if args.auto_update:
|
|
113
113
|
u = TandemSourceAutoupdate(secret)
|
|
114
|
-
|
|
114
|
+
changed, last_event_id = u.process(tconnect, nightscout, time_start, time_end, args.pretend, features=args.features)
|
|
115
|
+
|
|
116
|
+
# return exit code 0 if processed events
|
|
117
|
+
sys.exit(0 if changed>0 else 1)
|
|
115
118
|
else:
|
|
116
119
|
tconnectDevice = TandemSourceChooseDevice(secret, tconnect).choose()
|
|
117
120
|
added = TandemSourceProcessTimeRange(tconnect, nightscout, tconnectDevice, pretend=args.pretend, features=args.features).process(time_start, time_end)
|
|
118
|
-
|
|
121
|
+
|
|
122
|
+
# return exit code 0 if processed events
|
|
123
|
+
sys.exit(0 if added>0 else 1)
|
|
119
124
|
|
|
@@ -1,6 +1,8 @@
|
|
|
1
1
|
import struct
|
|
2
2
|
import arrow
|
|
3
3
|
|
|
4
|
+
from ..secret import TIMEZONE_NAME
|
|
5
|
+
|
|
4
6
|
from dataclasses import dataclass
|
|
5
7
|
|
|
6
8
|
EVENT_LEN = 26
|
|
@@ -29,7 +31,11 @@ class RawEvent:
|
|
|
29
31
|
seqNum = seqNum,
|
|
30
32
|
raw = raw
|
|
31
33
|
)
|
|
32
|
-
|
|
34
|
+
|
|
33
35
|
@property
|
|
34
36
|
def timestamp(self):
|
|
35
|
-
|
|
37
|
+
# Event timestamps do not have TZ data attached to them when parsed,
|
|
38
|
+
# but represent the user's time zone setting. So we keep the time
|
|
39
|
+
# referenced on them, but force the timezone to what the user
|
|
40
|
+
# requests via the TZ secret.
|
|
41
|
+
return arrow.get(TANDEM_EPOCH + self.timestampRaw, tzinfo=TIMEZONE_NAME)
|
|
@@ -18,6 +18,7 @@ class TandemSourceAutoupdate:
|
|
|
18
18
|
self.last_max_date_with_events = None
|
|
19
19
|
self.last_event_time = 0
|
|
20
20
|
self.last_attempt_time = 0
|
|
21
|
+
self.last_event_index = None
|
|
21
22
|
self.time_diffs_between_attempts = []
|
|
22
23
|
self.time_diffs_between_updates = []
|
|
23
24
|
|
|
@@ -41,15 +42,17 @@ class TandemSourceAutoupdate:
|
|
|
41
42
|
|
|
42
43
|
tconnectDevice = ChooseDevice(self.secret, tconnect).choose()
|
|
43
44
|
|
|
44
|
-
|
|
45
|
-
|
|
45
|
+
event_id = None
|
|
46
|
+
cur_max_date_with_events = arrow.get(tconnectDevice['maxDateWithEvents']).float_timestamp
|
|
47
|
+
if not self.last_max_date_with_events or cur_max_date_with_events > self.last_max_date_with_events:
|
|
46
48
|
logger.info('New reported tandemsource data. (cur_max_date: %s last_max_date: %s)' % (cur_max_date_with_events, self.last_max_date_with_events))
|
|
47
49
|
|
|
48
50
|
if pretend:
|
|
49
51
|
logger.info('Would update now if not in pretend mode')
|
|
50
52
|
else:
|
|
51
|
-
added = ProcessTimeRange(tconnect, nightscout, tconnectDevice, pretend, features=features).process(time_start, time_end)
|
|
53
|
+
added, event_id = ProcessTimeRange(tconnect, nightscout, tconnectDevice, pretend, features=features).process(time_start, time_end)
|
|
52
54
|
logger.info('Added %d items from ProcessTimeRange' % added)
|
|
55
|
+
self.last_successful_process_time_range = now
|
|
53
56
|
|
|
54
57
|
# Track the time it took to find a new event between runs,
|
|
55
58
|
# but skip this calculation the first process cycle (since
|
|
@@ -59,8 +62,10 @@ class TandemSourceAutoupdate:
|
|
|
59
62
|
logger.debug('Updating tracking of time since last update: %s' % self.time_diffs_between_updates)
|
|
60
63
|
|
|
61
64
|
# Mark the last event index uploaded from the pump and timestamp
|
|
65
|
+
if event_id:
|
|
66
|
+
self.last_event_index = event_id
|
|
67
|
+
self.last_event_time = now
|
|
62
68
|
self.last_max_date_with_events = cur_max_date_with_events
|
|
63
|
-
self.last_event_time = now
|
|
64
69
|
self.last_attempt_time = now
|
|
65
70
|
self.time_diffs_between_attempts = []
|
|
66
71
|
else:
|
|
@@ -55,14 +55,18 @@ class ProcessTimeRange:
|
|
|
55
55
|
|
|
56
56
|
events_first_time = None
|
|
57
57
|
events_last_time = None
|
|
58
|
+
last_event_id = None # aka seqnum
|
|
58
59
|
for_eventclass = collections.defaultdict(list)
|
|
59
60
|
for event in events:
|
|
60
61
|
if not events_first_time:
|
|
61
62
|
events_first_time = event.eventTimestamp
|
|
62
63
|
if not events_last_time:
|
|
63
64
|
events_last_time = event.eventTimestamp
|
|
65
|
+
if not last_event_id:
|
|
66
|
+
last_event_id = event.eventId
|
|
64
67
|
events_first_time = min(events_first_time, event.eventTimestamp)
|
|
65
68
|
events_last_time = max(events_last_time, event.eventTimestamp)
|
|
69
|
+
last_event_id = max(event.eventId, last_event_id)
|
|
66
70
|
|
|
67
71
|
clazz = EventClass.for_event(event)
|
|
68
72
|
if clazz:
|
|
@@ -91,6 +95,6 @@ class ProcessTimeRange:
|
|
|
91
95
|
else:
|
|
92
96
|
logger.info("Skipping %s, is not enabled from features %s" % (updater_class.__name__, self.features))
|
|
93
97
|
|
|
94
|
-
logger.info("Processed %d events" % processed_count)
|
|
95
|
-
return processed_count
|
|
98
|
+
logger.info("Processed %d events. Last event ID seen: %d" % (processed_count, last_event_id))
|
|
99
|
+
return processed_count, last_event_id
|
|
96
100
|
|
|
@@ -35,9 +35,9 @@ class ProcessAlarm:
|
|
|
35
35
|
|
|
36
36
|
ns_entries = []
|
|
37
37
|
for event in sorted(events, key=lambda x: x.eventTimestamp):
|
|
38
|
-
if last_upload_time and arrow.get(event.eventTimestamp)
|
|
38
|
+
if last_upload_time and arrow.get(event.eventTimestamp) <= last_upload_time:
|
|
39
39
|
if self.pretend:
|
|
40
|
-
logger.info("Skipping Alarm event
|
|
40
|
+
logger.info("Skipping Alarm event not after last upload time: %s (time range: %s - %s)" % (event, time_start, time_end))
|
|
41
41
|
continue
|
|
42
42
|
|
|
43
43
|
ns_entries.append(self.alarm_to_nsentry(event))
|
|
@@ -36,13 +36,17 @@ class ProcessBasal:
|
|
|
36
36
|
|
|
37
37
|
with_duration = []
|
|
38
38
|
for event in sorted(events, key=lambda x: x.eventTimestamp):
|
|
39
|
-
if last_upload_time and arrow.get(event.eventTimestamp)
|
|
39
|
+
if last_upload_time and arrow.get(event.eventTimestamp) <= last_upload_time:
|
|
40
40
|
if self.pretend:
|
|
41
|
-
logger.info("Skipping basal event
|
|
41
|
+
logger.info("Skipping basal event not after last upload time: %s (time range: %s - %s)" % (event, time_start, time_end))
|
|
42
42
|
continue
|
|
43
43
|
|
|
44
44
|
with_duration.append([event.eventTimestamp, None, event])
|
|
45
45
|
|
|
46
|
+
if not with_duration:
|
|
47
|
+
logger.info("No basal events found to process")
|
|
48
|
+
return []
|
|
49
|
+
|
|
46
50
|
for i in range(len(with_duration)-1):
|
|
47
51
|
with_duration[i][1] = with_duration[i+1][0] - with_duration[i][0]
|
|
48
52
|
|
{tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync/sync/tandemsource/process_basal_resume.py
RENAMED
|
@@ -35,9 +35,9 @@ class ProcessBasalResume:
|
|
|
35
35
|
|
|
36
36
|
ns_entries = []
|
|
37
37
|
for event in sorted(events, key=lambda x: x.eventTimestamp):
|
|
38
|
-
if last_upload_time and arrow.get(event.eventTimestamp)
|
|
38
|
+
if last_upload_time and arrow.get(event.eventTimestamp) <= last_upload_time:
|
|
39
39
|
if self.pretend:
|
|
40
|
-
logger.info("Skipping BasalResume event
|
|
40
|
+
logger.info("Skipping BasalResume event not after last upload time: %s (time range: %s - %s)" % (event, time_start, time_end))
|
|
41
41
|
continue
|
|
42
42
|
|
|
43
43
|
ns_entries.append(self.resume_to_nsentry(event))
|
{tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync/sync/tandemsource/process_basal_suspension.py
RENAMED
|
@@ -35,9 +35,9 @@ class ProcessBasalSuspension:
|
|
|
35
35
|
|
|
36
36
|
ns_entries = []
|
|
37
37
|
for event in sorted(events, key=lambda x: x.eventTimestamp):
|
|
38
|
-
if last_upload_time and arrow.get(event.eventTimestamp)
|
|
38
|
+
if last_upload_time and arrow.get(event.eventTimestamp) <= last_upload_time:
|
|
39
39
|
if self.pretend:
|
|
40
|
-
logger.info("Skipping basalsuspension event
|
|
40
|
+
logger.info("Skipping basalsuspension event not after last upload time: %s (time range: %s - %s)" % (event, time_start, time_end))
|
|
41
41
|
continue
|
|
42
42
|
|
|
43
43
|
ns_entries.append(self.suspension_to_nsentry(event))
|
|
@@ -44,7 +44,7 @@ class ProcessBolus:
|
|
|
44
44
|
bolusEventsForId[event.bolusid][type(event)] = event
|
|
45
45
|
|
|
46
46
|
if type(event) == eventtypes.LidBolusCompleted:
|
|
47
|
-
if last_upload_time and arrow.get(event.eventTimestamp)
|
|
47
|
+
if last_upload_time and arrow.get(event.eventTimestamp) <= last_upload_time:
|
|
48
48
|
if self.pretend:
|
|
49
49
|
logger.info("Skipping bolusCompletedEvent before last upload time: %s (time range: %s - %s)" % (event, time_start, time_end))
|
|
50
50
|
continue
|
{tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync/sync/tandemsource/process_cartridge.py
RENAMED
|
@@ -37,9 +37,9 @@ class ProcessCartridge:
|
|
|
37
37
|
cannulaFilledEvents = []
|
|
38
38
|
tubingFilledEvents = []
|
|
39
39
|
for event in sorted(events, key=lambda x: x.eventTimestamp):
|
|
40
|
-
if last_upload_time and arrow.get(event.eventTimestamp)
|
|
40
|
+
if last_upload_time and arrow.get(event.eventTimestamp) <= last_upload_time:
|
|
41
41
|
if self.pretend:
|
|
42
|
-
logger.info("Skipping %s
|
|
42
|
+
logger.info("Skipping %s not after last upload time: %s (time range: %s - %s)" % (type(event), event, time_start, time_end))
|
|
43
43
|
continue
|
|
44
44
|
|
|
45
45
|
if type(event) == eventtypes.LidCartridgeFilled:
|
{tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync/sync/tandemsource/process_cgm_alert.py
RENAMED
|
@@ -35,9 +35,9 @@ class ProcessCGMAlert:
|
|
|
35
35
|
|
|
36
36
|
alertEvents = []
|
|
37
37
|
for event in sorted(events, key=lambda x: x.eventTimestamp):
|
|
38
|
-
if last_upload_time and arrow.get(event.eventTimestamp)
|
|
38
|
+
if last_upload_time and arrow.get(event.eventTimestamp) <= last_upload_time:
|
|
39
39
|
if self.pretend:
|
|
40
|
-
logger.info("Skipping %s
|
|
40
|
+
logger.info("Skipping %s not after last upload time: %s (time range: %s - %s)" % (type(event), event, time_start, time_end))
|
|
41
41
|
continue
|
|
42
42
|
|
|
43
43
|
alertEvents.append(event)
|
{tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync/sync/tandemsource/process_cgm_reading.py
RENAMED
|
@@ -38,9 +38,9 @@ class ProcessCGMReading:
|
|
|
38
38
|
|
|
39
39
|
readings = []
|
|
40
40
|
for event in sorted(events, key=lambda x: self.timestamp_for(x)):
|
|
41
|
-
if last_upload_time and self.timestamp_for(event)
|
|
41
|
+
if last_upload_time and self.timestamp_for(event) <= last_upload_time:
|
|
42
42
|
if self.pretend:
|
|
43
|
-
logger.info("ProcessCGMReading: Skipping %s
|
|
43
|
+
logger.info("ProcessCGMReading: Skipping %s not after last upload time: %s (time range: %s - %s)" % (type(event), event, time_start, time_end))
|
|
44
44
|
continue
|
|
45
45
|
|
|
46
46
|
readings.append(event)
|
|
@@ -48,9 +48,9 @@ class ProcessCGMStartJoinStop:
|
|
|
48
48
|
|
|
49
49
|
allEvents = []
|
|
50
50
|
for event in sorted(events, key=lambda x: x.eventTimestamp):
|
|
51
|
-
if last_upload_time and arrow.get(event.eventTimestamp)
|
|
51
|
+
if last_upload_time and arrow.get(event.eventTimestamp) <= last_upload_time:
|
|
52
52
|
if self.pretend:
|
|
53
|
-
logger.info("ProcessCGMStartJoinStop: Skipping %s
|
|
53
|
+
logger.info("ProcessCGMStartJoinStop: Skipping %s not after last upload time: %s (time range: %s - %s)" % (type(event), event, time_start, time_end))
|
|
54
54
|
continue
|
|
55
55
|
|
|
56
56
|
allEvents.append(event)
|
{tconnectsync-2.0.2 → tconnectsync-2.0.5}/tconnectsync/sync/tandemsource/process_user_mode.py
RENAMED
|
@@ -72,9 +72,9 @@ class ProcessUserMode:
|
|
|
72
72
|
start_sleep = None
|
|
73
73
|
start_exercise = None
|
|
74
74
|
for event in sorted(events, key=lambda x: x.eventTimestamp):
|
|
75
|
-
if last_upload_time and arrow.get(event.eventTimestamp)
|
|
75
|
+
if last_upload_time and arrow.get(event.eventTimestamp) <= last_upload_time:
|
|
76
76
|
if self.pretend:
|
|
77
|
-
logger.info("ProcessUserMode: Skipping usermode event
|
|
77
|
+
logger.info("ProcessUserMode: Skipping usermode event not after last upload time: %s (time range: %s - %s)" % (event, time_start, time_end))
|
|
78
78
|
continue
|
|
79
79
|
|
|
80
80
|
if self.is_start_sleep(event):
|
|
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
|
|
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
|
|
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
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|