Skip to content

Commit f016b44

Browse files
chore: review comments
Signed-off-by: Shivanshu Raj Shrivastava <[email protected]>
1 parent 9d05c39 commit f016b44

File tree

2 files changed

+3
-4
lines changed

2 files changed

+3
-4
lines changed

CHANGELOG.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,9 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
1313

1414
### Added
1515

16+
- `opentelemetry-instrumentation-celery` Populate both origin and hostname correctly to span attributes
17+
([#3097](https://github.com/open-telemetry/opentelemetry-python-contrib/pull/3097))
18+
1619
- `opentelemetry-instrumentation-botocore` Add support for GenAI user events and lazy initialize tracer
1720
([#3258](https://github.com/open-telemetry/opentelemetry-python-contrib/pull/3258))
1821
- `opentelemetry-instrumentation-botocore` Add support for GenAI system events

instrumentation/opentelemetry-instrumentation-celery/tests/test_utils.py

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -285,20 +285,16 @@ def test_task_id_from_protocol_v2(self):
285285

286286
def test_origin_and_hostname_attributes(self):
287287
"""Test that 'origin' and 'hostname' are distinct attributes"""
288-
# Create a mock span
289288
span = mock.Mock()
290289
span.is_recording.return_value = True
291290

292-
# Create a context with both 'origin' and 'hostname' keys
293291
context = {
294292
"origin": "gen8@b98c7aca4628",
295293
"hostname": "celery@7c2c2cd6a5b5",
296294
}
297295

298-
# Call the function
299296
utils.set_attributes_from_context(span, context)
300297

301-
# Verify that both attributes were set with their original keys
302298
span.set_attribute.assert_has_calls(
303299
[
304300
mock.call("celery.origin", "gen8@b98c7aca4628"),

0 commit comments

Comments
 (0)