Skip to content

Commit 47b9f8e

Browse files
authored
chore: add traceback info to the failed to send message [backport 3.10] (#14353)
## Checklist - [X] PR author has checked that all the criteria below are met - The PR description includes an overview of the change - The PR description articulates the motivation for the change - The change includes tests OR the PR description describes a testing strategy - The PR description notes risks associated with the change, if any - Newly-added code is easy to change - The change follows the [library release note guidelines](https://ddtrace.readthedocs.io/en/stable/releasenotes.html) - The change includes or references documentation updates if necessary - Backport labels are set (if [applicable](https://ddtrace.readthedocs.io/en/latest/contributing.html#backporting)) ## Reviewer Checklist - [x] Reviewer has checked that all the criteria below are met - Title is accurate - All changes are related to the pull request's stated goal - Avoids breaking [API](https://ddtrace.readthedocs.io/en/stable/versioning.html#interfaces) changes - Testing strategy adequately addresses listed risks - Newly-added code is easy to change - Release note makes sense to a user of the library - If necessary, author has acknowledged and discussed the performance implications of this PR as reported in the benchmarks PR comment - 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) Signed-off-by: Juanjo Alvarez <[email protected]>
1 parent e5b0b64 commit 47b9f8e

File tree

2 files changed

+3
-0
lines changed

2 files changed

+3
-0
lines changed

ddtrace/internal/writer/writer.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -406,6 +406,7 @@ def _flush_queue_with_client(self, client: WriterClientBase, raise_exc: bool = F
406406
n_traces,
407407
self._intake_endpoint(client),
408408
self.RETRY_ATTEMPTS,
409+
exc_info=True,
409410
)
410411
finally:
411412
self._metrics_dist("http.sent.bytes", len(encoded))

tests/integration/test_integration.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -109,6 +109,7 @@ def test_uds_wrong_socket_path():
109109
1,
110110
"unix:///tmp/ddagent/nosockethere/{}/traces".format(encoding if encoding else "v0.5"),
111111
3,
112+
exc_info=True,
112113
)
113114
]
114115
log.error.assert_has_calls(calls)
@@ -356,6 +357,7 @@ def test_trace_generates_error_logs_when_trace_agent_url_invalid():
356357
1,
357358
"http://localhost:8125/{}/traces".format(encoding if encoding else "v0.5"),
358359
3,
360+
exc_info=True,
359361
)
360362
]
361363
log.error.assert_has_calls(calls)

0 commit comments

Comments
 (0)