Azure / azure-functions-python-library

Azure Functions Python SDK
MIT License
147 stars 61 forks source link

Allow http scheme for AsgiRequest #198

Closed hallvictoria closed 2 months ago

hallvictoria commented 7 months ago

Fixes #1185

AsgiRequest scheme is currently hard-coded to https. The scheme should allow both http or https, depending on the incoming request. This change uses urllib.parse.urlparse to handle both types.

codecov[bot] commented 7 months ago

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Comparison is base (0ca53b3) 92.97% compared to head (357a4ba) 92.91%.

Additional details and impacted files ```diff @@ Coverage Diff @@ ## dev #198 +/- ## ========================================== - Coverage 92.97% 92.91% -0.06% ========================================== Files 56 56 Lines 3187 3190 +3 Branches 649 649 ========================================== + Hits 2963 2964 +1 - Misses 137 138 +1 - Partials 87 88 +1 ``` | [Flag](https://app.codecov.io/gh/Azure/azure-functions-python-library/pull/198/flags?src=pr&el=flags&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Azure) | Coverage Δ | | |---|---|---| | [unittests](https://app.codecov.io/gh/Azure/azure-functions-python-library/pull/198/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Azure) | `92.88% <100.00%> (-0.06%)` | :arrow_down: | Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Azure#carryforward-flags-in-the-pull-request-comment) to find out more.

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

codecov-commenter commented 3 months ago

Codecov Report

All modified and coverable lines are covered by tests :white_check_mark:

Project coverage is 92.91%. Comparing base (b85eb7a) to head (357a4ba). Report is 1 commits behind head on dev.

:exclamation: Current head 357a4ba differs from pull request most recent head 2073418. Consider uploading reports for the commit 2073418 to get more accurate results

Additional details and impacted files ```diff @@ Coverage Diff @@ ## dev #198 +/- ## ========================================== - Coverage 93.10% 92.91% -0.19% ========================================== Files 56 56 Lines 3247 3190 -57 Branches 666 649 -17 ========================================== - Hits 3023 2964 -59 - Misses 137 138 +1 - Partials 87 88 +1 ``` | [Flag](https://app.codecov.io/gh/Azure/azure-functions-python-library/pull/198/flags?src=pr&el=flags&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Azure) | Coverage Δ | | |---|---|---| | [unittests](https://app.codecov.io/gh/Azure/azure-functions-python-library/pull/198/flags?src=pr&el=flag&utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Azure) | `92.88% <100.00%> (-0.19%)` | :arrow_down: | Flags with carried forward coverage won't be shown. [Click here](https://docs.codecov.io/docs/carryforward-flags?utm_medium=referral&utm_source=github&utm_content=comment&utm_campaign=pr+comments&utm_term=Azure#carryforward-flags-in-the-pull-request-comment) to find out more.

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