dapr / python-sdk

Dapr SDK for Python
Apache License 2.0
230 stars 128 forks source link

Updated endpoint parsing #618

Closed elena-kolevska closed 1 year ago

elena-kolevska commented 1 year ago

Description

This PR updates the python-sdk so it satisfies the requirements for gRPC endpoint parsing added in https://github.com/dapr/proposals/pull/40.

It also adds support for all URIs that the gRPC name resolution document defines, including dns links with authority, unix paths with absolute and relative sockets, unix-abstract and virtual sockets.

Backwards compatibility has been maintained for endpoints where tls was inferred based on the scheme https.

Issue reference

https://github.com/dapr/python-sdk/issues/619

Checklist

codecov[bot] commented 1 year ago

Codecov Report

Attention: 41 lines in your changes are missing coverage. Please review.

Comparison is base (6171b67) 86.40% compared to head (59b4e42) 86.13%.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## master #618 +/- ## ========================================== - Coverage 86.40% 86.13% -0.28% ========================================== Files 74 74 Lines 3605 3700 +95 ========================================== + Hits 3115 3187 +72 - Misses 490 513 +23 ``` | [Files](https://app.codecov.io/gh/dapr/python-sdk/pull/618?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr) | Coverage Δ | | |---|---|---| | [dapr/aio/clients/grpc/client.py](https://app.codecov.io/gh/dapr/python-sdk/pull/618?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr#diff-ZGFwci9haW8vY2xpZW50cy9ncnBjL2NsaWVudC5weQ==) | `70.36% <80.00%> (-0.32%)` | :arrow_down: | | [dapr/clients/grpc/client.py](https://app.codecov.io/gh/dapr/python-sdk/pull/618?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr#diff-ZGFwci9jbGllbnRzL2dycGMvY2xpZW50LnB5) | `84.83% <76.92%> (-0.46%)` | :arrow_down: | | [dapr/conf/helpers.py](https://app.codecov.io/gh/dapr/python-sdk/pull/618?src=pr&el=tree&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=dapr#diff-ZGFwci9jb25mL2hlbHBlcnMucHk=) | `71.65% <71.65%> (+16.39%)` | :arrow_up: |

:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.

elena-kolevska commented 1 year ago

Thanks @berndverst. Good catch, I was using those prints to generate the matrix in this proposal. Fixed in https://github.com/dapr/python-sdk/pull/633