Emmett.butler/consolidate utils#18587
Conversation
Circular import analysis🚨 New circular imports detected 🚨The following circular imports among modules have been detected on this PR, when compared to the base branch: Please consider refactoring your changes in accordance to the Separation of Concerns principle. |
|
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 02e5a7b2d3
ℹ️ About Codex in GitHub
Codex has been enabled to automatically review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
When you sign up for Codex through ChatGPT, Codex can also answer questions or update the PR, like "@codex address that feedback".
| @@ -5,7 +5,7 @@ | |||
| from typing import Optional | |||
|
|
|||
| from ddtrace.internal.settings._agent import config as agent_config # noqa:F401 | |||
| from ddtrace.internal.threads import RLock | |||
| from ddtrace.internal.utils.threads import RLock | |||
There was a problem hiding this comment.
Restore the remaining encoding imports
This module still imports .compat and .logger a few lines below, but this commit removes ddtrace/internal/compat.py and ddtrace/internal/logger.py by moving them under ddtrace.internal.utils. As soon as ddtrace.internal.encoding is imported (the trace writers use these encoders), Python will raise ModuleNotFoundError before traces can be encoded; those relative imports need to be updated or compatibility shims kept.
Useful? React with 👍 / 👎.
Description
Testing
Risks
Additional Notes