`spans`, with its provider registered with the OpenTelemetry API for this test, which a client that is given none uses. A client that is given a `tracer_provider` is given an option, so it reads no environment variable. The API registers a provider once for each process, so this sets what i
(spans: Spans, monkeypatch: pytest.MonkeyPatch)
| 167 | |
| 168 | @pytest.fixture |
| 169 | def registered(spans: Spans, monkeypatch: pytest.MonkeyPatch) -> Spans: |
| 170 | """`spans`, with its provider registered with the OpenTelemetry API for this test, which a client that is given none uses. |
| 171 | |
| 172 | A client that is given a `tracer_provider` is given an option, so it reads no environment variable. The API |
| 173 | registers a provider once for each process, so this sets what it would have registered and puts it back afterwards. |
| 174 | """ |
| 175 | monkeypatch.setattr(trace, "_TRACER_PROVIDER", spans.provider) |
| 176 | return spans |
| 177 | |
| 178 | |
| 179 | def make_client(spans: Spans, **options: Any) -> Anthropic: |
nothing calls this directly
no outgoing calls
no test coverage detected