Skip to content

Commit

Permalink
fix: pin importlib to 6.5.0 [backport 2.4] (#8195)
Browse files Browse the repository at this point in the history
Backport c8d5e9f from #8075 to 2.4.

## Description

- Pin importlib to 6.5.0 to avoid issue
python/importlib_metadata#455
- Fix a potential unbound local error.

Fixes #8068 

## Checklist

- [X] Change(s) are motivated and described in the PR description.
- [X] Testing strategy is described if automated tests are not included
in the PR.
- [X] Risk is outlined (performance impact, potential for breakage,
maintainability, etc).
- [X] Change is maintainable (easy to change, telemetry, documentation).
- [X] [Library release note
guidelines](https://ddtrace.readthedocs.io/en/stable/releasenotes.html)
are followed. If no release note is required, add label
`changelog/no-changelog`.
- [X] Documentation is included (in-code, generated user docs, [public
corp docs](https://github.com/DataDog/documentation/)).
- [X] Backport labels are set (if
[applicable](https://ddtrace.readthedocs.io/en/latest/contributing.html#backporting))

## Reviewer Checklist

- [x] Title is accurate.
- [x] No unnecessary changes are introduced.
- [x] Description motivates each change.
- [x] Avoids breaking
[API](https://ddtrace.readthedocs.io/en/stable/versioning.html#interfaces)
changes unless absolutely necessary.
- [x] Testing strategy adequately addresses listed risk(s).
- [x] Change is maintainable (easy to change, telemetry, documentation).
- [x] Release note makes sense to a user of the library.
- [x] Reviewer has explicitly acknowledged and discussed the performance
implications of this PR as reported in the benchmarks PR comment.
- [x] Backport labels are set in a manner that is consistent with the
[release branch maintenance
policy](https://ddtrace.readthedocs.io/en/latest/contributing.html#backporting)
- [x] If this PR touches code that signs or publishes builds or
packages, or handles credentials of any kind, I've requested a review
from `@DataDog/security-design-and-guidance`.
- [x] This PR doesn't touch any of that.

Co-authored-by: Juanjo Alvarez Martinez <juanjo.alvarezmartinez@datadoghq.com>
Co-authored-by: Emmett Butler <723615+emmettbutler@users.noreply.github.com>
  • Loading branch information
3 people authored Feb 1, 2024
1 parent a818cce commit ffb31c6
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 2 deletions.
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ dependencies = [
"cattrs",
"ddsketch>=2.0.1",
"envier",
"importlib_metadata; python_version<'3.8'",
"importlib_metadata<=6.5.0; python_version<'3.8'",
"opentelemetry-api>=1",
"protobuf>=3",
"setuptools; python_version>='3.12'",
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
fixes:
- |
Pin importlib_metadata to 6.5.0 to avoid its issue 455 (https://github.com/python/importlib_metadata/issues/455).
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
Expand Up @@ -577,7 +577,7 @@ def get_ddup_ext():
"cattrs",
"six>=1.12.0",
"typing_extensions",
"importlib_metadata; python_version<'3.8'",
"importlib_metadata<=6.5.0; python_version<'3.8'",
"xmltodict>=0.12",
"envier",
"opentelemetry-api>=1",
Expand Down

0 comments on commit ffb31c6

Please sign in to comment.