Skip to content

Commit 1bef9c6

Browse files
committed
push
1 parent 74c5693 commit 1bef9c6

2 files changed

Lines changed: 5 additions & 4 deletions

File tree

langfuse/otel/_span_processor/__init__.py

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -24,13 +24,14 @@ def __init__(
2424
):
2525
self.public_key = public_key
2626

27+
basic_auth_header = "Basic " + base64.b64encode(
28+
f"{public_key}:{secret_key}".encode("utf-8")
29+
).decode("ascii")
30+
2731
langfuse_span_exporter = OTLPSpanExporter(
2832
endpoint=f"{host}/api/public/otel/v1/traces",
2933
headers={
30-
"Authorization": "Basic "
31-
+ base64.b64encode(f"{public_key}:{secret_key}".encode("utf-8")).decode(
32-
"ascii"
33-
),
34+
"Authorization": basic_auth_header,
3435
"x_langfuse_sdk_name": "python",
3536
"x_langfuse_sdk_version": langfuse_version,
3637
"x_langfuse_public_key": public_key,

0 commit comments

Comments
 (0)