Skip to content

Commit 1fc0ce6

Browse files
committed
refactor: lint fixes
1 parent 660bcdc commit 1fc0ce6

File tree

3 files changed

+5
-3
lines changed

3 files changed

+5
-3
lines changed

_appmap/event.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -94,7 +94,8 @@ def _describe_schema(name, val, depth, max_depth):
9494
if islist:
9595
elts = [(None, v) for v in val]
9696
schema_key = "items"
97-
elif isdict:
97+
else:
98+
assert isdict
9899
elts = val.items()
99100
schema_key = "properties"
100101

_appmap/recorder.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -114,7 +114,8 @@ def stop_recording(cls):
114114
def check_time(cls, event_time):
115115
if _MAX_TIME is None:
116116
return
117-
if event_time - cls.get_current()._start_time > _MAX_TIME:
117+
delta = event_time - cls.get_current()._start_time # pylint: disable=protected-access
118+
if delta > _MAX_TIME:
118119
raise AppMapSessionTooLong(f"Session exceeded {_MAX_TIME} seconds")
119120

120121
@classmethod

pylintrc

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[MAIN]
22
# Specify a score threshold under which the program will exit with error.
3-
fail-under=9.86
3+
fail-under=9.87
44

55

66
# Analyse import fallback blocks. This can be used to support both Python 2 and

0 commit comments

Comments
 (0)