Closed bernhardkaindl closed 1 year ago
Merging #89 (9aebce5) into dev (064c5c6) will increase coverage by
0.05%
. The diff coverage is97.63%
.
@@ Coverage Diff @@
## dev #89 +/- ##
==========================================
+ Coverage 79.49% 79.55% +0.05%
==========================================
Files 41 41
Lines 2717 2719 +2
==========================================
+ Hits 2160 2163 +3
+ Misses 557 556 -1
Flag | Coverage Δ | |
---|---|---|
unittests | 79.55% <97.63%> (+0.05%) |
:arrow_up: |
Flags with carried forward coverage won't be shown. Click here to find out more.
Impacted Files | Coverage Δ | |
---|---|---|
pjrpc/client/backend/aio_pika.py | 0.00% <0.00%> (ø) |
|
pjrpc/client/backend/kombu.py | 0.00% <0.00%> (ø) |
|
pjrpc/__about__.py | 100.00% <100.00%> (ø) |
|
pjrpc/client/client.py | 97.55% <100.00%> (ø) |
|
pjrpc/client/integrations/pytest.py | 91.85% <100.00%> (ø) |
|
pjrpc/common/__init__.py | 91.66% <100.00%> (ø) |
|
pjrpc/common/common.py | 89.28% <100.00%> (+0.82%) |
:arrow_up: |
pjrpc/common/exceptions.py | 98.64% <100.00%> (ø) |
|
pjrpc/common/v20.py | 91.22% <100.00%> (ø) |
|
pjrpc/server/dispatcher.py | 87.73% <100.00%> (+0.04%) |
:arrow_up: |
... and 5 more |
Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here.
Looks good, @dapper91 - may I merge?
Thanks, Bernhard
Hello @dapper91!
Note: To be merged before #90, but #90 includes this commit.
This is a trivial improvement to fix
mypy
warnings (except foradd_user()
, see #90 for it) inexamples/aio_pika_server.py
:Details:
If
asyncio.get_event_loop()
is called when there is no running event loop, Python 3.10+ warns:https://docs.python.org/3/library/asyncio-eventloop.html#asyncio.get_event_loop
Because
examples/aio_pika_server.py
uses it to start the event loop, it must change in this way:Reference: https://stackoverflow.com/questions/71546992/asyncio-alternatives-to-deprecated-run-forever
While at it, also fix a few mypy errors in this example by adding type annotations and use yarl.URL as needed.