Skip to content

Commit 74db79f

Browse files
committed
fix: fixed typechecking
1 parent b2e7985 commit 74db79f

File tree

4 files changed

+8
-8
lines changed

4 files changed

+8
-8
lines changed

Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@ test:
88
pytest -s -vv tests/test_requestqueue.py
99

1010
typecheck:
11-
MYPYPATH="${MYPYPATH}:../aw-core" mypy aw_client
11+
MYPYPATH="${MYPYPATH}:../aw-core" mypy
1212

1313
clean:
1414
rm -rf build dist

examples/redact_sensitive.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -126,8 +126,8 @@ def _redact_event(e: Event, pattern: Union[str, Pattern]) -> Event:
126126
return e
127127

128128

129-
def _find_sensitive(el: List[Event], pattern: Union[str, Pattern]) -> Set[int]:
130-
sensitive_ids: Set[int] = set()
129+
def _find_sensitive(el: List[Event], pattern: Union[str, Pattern]) -> Set:
130+
sensitive_ids = set()
131131
for e in el:
132132
if _check_event(e, pattern):
133133
sensitive_ids.add(e.id)

mypy.ini

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
11
[mypy]
2-
files = aw-client/**.py, test/**.py, examples/**.py
2+
files = aw_client, tests, examples
33
ignore_missing_imports = true
44
check_untyped_defs = true

tests/test_requestqueue.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -36,10 +36,10 @@ def _post(self, *args, **kwargs):
3636

3737
def test_basic():
3838
client = MockClient()
39-
rq = RequestQueue(client)
39+
rq = RequestQueue(client) # type: ignore
4040

4141
# Mockeypatching
42-
rq._try_connect = lambda: True
42+
rq._try_connect = lambda: True # type: ignore
4343
rq.connected = True
4444

4545
rq.start()
@@ -51,10 +51,10 @@ def test_basic():
5151

5252
def test_complex():
5353
client = MockClient()
54-
rq = RequestQueue(client)
54+
rq = RequestQueue(client) # type: ignore
5555

5656
# Mockeypatching
57-
rq._try_connect = lambda: False
57+
rq._try_connect = lambda: False # type: ignore
5858

5959
rq.start()
6060
sleep(1)

0 commit comments

Comments
 (0)