Skip to content

Comments

fix(httpx): manually construct removed URL.raw property#4595

Merged
mergify[bot] merged 3 commits intoDataDog:1.xfrom
Yun-Kim:yunkim/fix-httpx
Nov 21, 2022
Merged

fix(httpx): manually construct removed URL.raw property#4595
mergify[bot] merged 3 commits intoDataDog:1.xfrom
Yun-Kim:yunkim/fix-httpx

Conversation

@Yun-Kim
Copy link
Contributor

@Yun-Kim Yun-Kim commented Nov 18, 2022

Description

As of httpx==0.23.1, the URL.raw property was removed, which broke our _url_to_str() helper that uses that property to construct the raw URL.

However, the removed property was simply a combination of already existing (and still existing) properties in the URL object, which we can use to manually consturct the raw URL. I've version gated it such that nothing's changed for previous versions of httpx, but moving forward we'll manually construct the raw URL.

Checklist

Motivation

Design

Testing strategy

Relevant issue(s)

Testing strategy

Reviewer Checklist

  • Title is accurate.
  • Description motivates each change.
  • No unnecessary changes were introduced in this PR.
  • Avoid breaking API changes unless absolutely necessary.
  • Tests provided or description of manual testing performed is included in the code or PR.
  • Release note has been added for fixes and features, or else changelog/no-changelog label added.
  • All relevant GitHub issues are correctly linked.
  • Backports are identified and tagged with Mergifyio.

@Yun-Kim Yun-Kim added the changelog/no-changelog A changelog entry is not required for this PR. label Nov 18, 2022
@Yun-Kim Yun-Kim requested a review from a team as a code owner November 18, 2022 19:03
brettlangdon
brettlangdon previously approved these changes Nov 18, 2022
Copy link
Member

@brettlangdon brettlangdon left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

one thought, but other lgtm

@codecov-commenter
Copy link

codecov-commenter commented Nov 18, 2022

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 77.96%. Comparing base (0ea7b6a) to head (8c55117).
⚠️ Report is 1298 commits behind head on 1.x.

Additional details and impacted files
@@           Coverage Diff           @@
##              1.x    #4595   +/-   ##
=======================================
  Coverage   77.95%   77.96%           
=======================================
  Files         759      759           
  Lines       60125    60131    +6     
=======================================
+ Hits        46872    46879    +7     
+ Misses      13253    13252    -1     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@Yun-Kim Yun-Kim mentioned this pull request Nov 18, 2022
10 tasks
@brettlangdon
Copy link
Member

@Mergifyio backport 1.6

@brettlangdon
Copy link
Member

@Mergifyio refresh

@mergify
Copy link
Contributor

mergify bot commented Nov 21, 2022

backport 1.6

✅ Backports have been created

Details

@mergify
Copy link
Contributor

mergify bot commented Nov 21, 2022

refresh

✅ Pull request refreshed

@mergify mergify bot merged commit 6a1948d into DataDog:1.x Nov 21, 2022
mergify bot pushed a commit that referenced this pull request Nov 21, 2022
## Description
[As of `httpx==0.23.1`](encode/httpx#2241), the `URL.raw` property was removed, which broke our `_url_to_str()` helper that uses that property to construct the raw URL.

However, the removed property was simply a combination of already existing (and still existing) properties in the `URL` object, which we can use to manually consturct the raw URL. I've version gated it such that nothing's changed for previous versions of `httpx`, but moving forward we'll manually construct the raw URL.

## Checklist
- [x] Add additional sections for `feat` and `fix` pull requests.
- [x] [Library documentation](https://github.com/DataDog/dd-trace-py/tree/1.x/docs) and/or [Datadog's documentation site](https://github.com/DataDog/documentation/) is updated. Link to doc PR in description.

## Motivation

## Design

## Testing strategy

## Relevant issue(s)

## Testing strategy

## Reviewer Checklist
- [ ] Title is accurate.
- [ ] Description motivates each change.
- [ ] No unnecessary changes were introduced in this PR.
- [ ] Avoid breaking [API](https://ddtrace.readthedocs.io/en/stable/versioning.html#interfaces) changes unless absolutely necessary.
- [ ] Tests provided or description of manual testing performed is included in the code or PR.
- [ ] Release note has been added for fixes and features, or else `changelog/no-changelog` label added.
- [ ] All relevant GitHub issues are correctly linked.
- [ ] Backports are identified and tagged with Mergifyio.

(cherry picked from commit 6a1948d)
@brettlangdon
Copy link
Member

Fixes #4593

@brettlangdon brettlangdon linked an issue Nov 21, 2022 that may be closed by this pull request
@Yun-Kim Yun-Kim deleted the yunkim/fix-httpx branch November 21, 2022 15:27
mergify bot pushed a commit that referenced this pull request Nov 21, 2022
## Description

#4595 should have included a release note, this is the note for that PR.

## Reviewer Checklist
- [x] Title is accurate.
- [x] Description motivates each change.
- [x] No unnecessary changes were introduced in this PR.
- [x] Avoid breaking [API](https://ddtrace.readthedocs.io/en/stable/versioning.html#interfaces) changes unless absolutely necessary.
- [x] Tests provided or description of manual testing performed is included in the code or PR.
- [x] Release note has been added for fixes and features, or else `changelog/no-changelog` label added.
- [x] All relevant GitHub issues are correctly linked.
- [x] Backports are identified and tagged with Mergifyio.
mergify bot pushed a commit that referenced this pull request Nov 21, 2022
## Description

#4595 should have included a release note, this is the note for that PR.

## Reviewer Checklist
- [x] Title is accurate.
- [x] Description motivates each change.
- [x] No unnecessary changes were introduced in this PR.
- [x] Avoid breaking [API](https://ddtrace.readthedocs.io/en/stable/versioning.html#interfaces) changes unless absolutely necessary.
- [x] Tests provided or description of manual testing performed is included in the code or PR.
- [x] Release note has been added for fixes and features, or else `changelog/no-changelog` label added.
- [x] All relevant GitHub issues are correctly linked.
- [x] Backports are identified and tagged with Mergifyio.

(cherry picked from commit 7dd5f6a)
brettlangdon pushed a commit that referenced this pull request Nov 21, 2022
)

## Description
[As of `httpx==0.23.1`](encode/httpx#2241), the `URL.raw` property was removed, which broke our `_url_to_str()` helper that uses that property to construct the raw URL.

However, the removed property was simply a combination of already existing (and still existing) properties in the `URL` object, which we can use to manually consturct the raw URL. I've version gated it such that nothing's changed for previous versions of `httpx`, but moving forward we'll manually construct the raw URL.

## Checklist
- [x] Add additional sections for `feat` and `fix` pull requests.
- [x] [Library documentation](https://github.com/DataDog/dd-trace-py/tree/1.x/docs) and/or [Datadog's documentation site](https://github.com/DataDog/documentation/) is updated. Link to doc PR in description.

## Motivation

## Design

## Testing strategy

## Relevant issue(s)

## Testing strategy

## Reviewer Checklist
- [ ] Title is accurate.
- [ ] Description motivates each change.
- [ ] No unnecessary changes were introduced in this PR.
- [ ] Avoid breaking [API](https://ddtrace.readthedocs.io/en/stable/versioning.html#interfaces) changes unless absolutely necessary.
- [ ] Tests provided or description of manual testing performed is included in the code or PR.
- [ ] Release note has been added for fixes and features, or else `changelog/no-changelog` label added.
- [ ] All relevant GitHub issues are correctly linked.
- [ ] Backports are identified and tagged with Mergifyio.

(cherry picked from commit 6a1948d)

Co-authored-by: Yun Kim <[email protected]>
Kyle-Verhoog pushed a commit that referenced this pull request Nov 21, 2022
## Description

#4595 should have included a release note, this is the note for that PR.

## Reviewer Checklist
- [x] Title is accurate.
- [x] Description motivates each change.
- [x] No unnecessary changes were introduced in this PR.
- [x] Avoid breaking [API](https://ddtrace.readthedocs.io/en/stable/versioning.html#interfaces) changes unless absolutely necessary.
- [x] Tests provided or description of manual testing performed is included in the code or PR.
- [x] Release note has been added for fixes and features, or else `changelog/no-changelog` label added.
- [x] All relevant GitHub issues are correctly linked.
- [x] Backports are identified and tagged with Mergifyio.

(cherry picked from commit 7dd5f6a)

Co-authored-by: Brett Langdon <[email protected]>
Co-authored-by: Yun Kim <[email protected]>
mabdinur pushed a commit that referenced this pull request Dec 9, 2022
## Description
[As of `httpx==0.23.1`](encode/httpx#2241), the `URL.raw` property was removed, which broke our `_url_to_str()` helper that uses that property to construct the raw URL.

However, the removed property was simply a combination of already existing (and still existing) properties in the `URL` object, which we can use to manually consturct the raw URL. I've version gated it such that nothing's changed for previous versions of `httpx`, but moving forward we'll manually construct the raw URL.



## Checklist
- [x] Add additional sections for `feat` and `fix` pull requests.
- [x] [Library documentation](https://github.com/DataDog/dd-trace-py/tree/1.x/docs) and/or [Datadog's documentation site](https://github.com/DataDog/documentation/) is updated. Link to doc PR in description.





## Motivation


## Design 


## Testing strategy




## Relevant issue(s)


## Testing strategy




## Reviewer Checklist
- [ ] Title is accurate.
- [ ] Description motivates each change.
- [ ] No unnecessary changes were introduced in this PR.
- [ ] Avoid breaking [API](https://ddtrace.readthedocs.io/en/stable/versioning.html#interfaces) changes unless absolutely necessary.
- [ ] Tests provided or description of manual testing performed is included in the code or PR.
- [ ] Release note has been added for fixes and features, or else `changelog/no-changelog` label added.
- [ ] All relevant GitHub issues are correctly linked.
- [ ] Backports are identified and tagged with Mergifyio.
mabdinur pushed a commit that referenced this pull request Dec 9, 2022
## Description
[As of `httpx==0.23.1`](encode/httpx#2241), the `URL.raw` property was removed, which broke our `_url_to_str()` helper that uses that property to construct the raw URL.

However, the removed property was simply a combination of already existing (and still existing) properties in the `URL` object, which we can use to manually consturct the raw URL. I've version gated it such that nothing's changed for previous versions of `httpx`, but moving forward we'll manually construct the raw URL.



## Checklist
- [x] Add additional sections for `feat` and `fix` pull requests.
- [x] [Library documentation](https://github.com/DataDog/dd-trace-py/tree/1.x/docs) and/or [Datadog's documentation site](https://github.com/DataDog/documentation/) is updated. Link to doc PR in description.





## Motivation


## Design 


## Testing strategy




## Relevant issue(s)


## Testing strategy




## Reviewer Checklist
- [ ] Title is accurate.
- [ ] Description motivates each change.
- [ ] No unnecessary changes were introduced in this PR.
- [ ] Avoid breaking [API](https://ddtrace.readthedocs.io/en/stable/versioning.html#interfaces) changes unless absolutely necessary.
- [ ] Tests provided or description of manual testing performed is included in the code or PR.
- [ ] Release note has been added for fixes and features, or else `changelog/no-changelog` label added.
- [ ] All relevant GitHub issues are correctly linked.
- [ ] Backports are identified and tagged with Mergifyio.
brettlangdon pushed a commit that referenced this pull request Dec 22, 2022
## Description

CI mitigation for issue addressed in this PR
#4595

## Reviewer Checklist
- [ ] Title is accurate.
- [ ] Description motivates each change.
- [ ] No unnecessary changes were introduced in this PR.
- [ ] Avoid breaking
[API](https://ddtrace.readthedocs.io/en/stable/versioning.html#interfaces)
changes unless absolutely necessary.
- [ ] Tests provided or description of manual testing performed is
included in the code or PR.
- [ ] Release note has been added and follows the [library release note
guidelines](https://ddtrace.readthedocs.io/en/stable/contributing.html#Release-Note-Guidelines),
or else `changelog/no-changelog` label added.
- [ ] All relevant GitHub issues are correctly linked.
- [ ] Backports are identified and tagged with Mergifyio.

Co-authored-by: Yun Kim <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

changelog/no-changelog A changelog entry is not required for this PR.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Incompatibility introduced in HTTPX 0.23.1

5 participants