MCPcopy Create free account
hub / github.com/anthropics/anthropic-sdk-python / __init__

Method __init__

tests/test_tracing.py:33–38  ·  view source on GitHub ↗
(self, attributes: Any, *, sampled: bool)

Source from the content-addressed store, hash-verified

31 """A span with a valid context, which records unless a sampler dropped it."""
32
33 def __init__(self, attributes: Any, *, sampled: bool) -> None:
34 flags = TraceFlags(TraceFlags.SAMPLED if sampled else TraceFlags.DEFAULT)
35 super().__init__(SpanContext(trace_id=1, span_id=1, is_remote=False, trace_flags=flags))
36 self.attributes: dict[str, Any] = dict(attributes or {})
37 self.sampled = sampled
38 self.ended = False
39
40 @override
41 def is_recording(self) -> bool:

Callers

nothing calls this directly

Calls 1

__init__Method · 0.45

Tested by

no test coverage detected